exceptionfactory commented on PR #6718:
URL: https://github.com/apache/nifi/pull/6718#issuecomment-1329640686
> Hi @exceptionfactory, are you suggesting something like
>
> ```
> String querySrting = attributes.get(QuerySolr.ATTRIBUTE_SOLR_QUERY)
> //"q=*:*&qt=/select&start=0&rows=10&stats=true&facet=true"
> assertTrue(queryString.contains("q=*:*") &&
queryString.contains("qt=/select") && querystring.contains("start=0") &&
queryString.contains("rows=10") && queryString.contains("stats=true") &&
queryString.contains("facet=true"));
> ```
Thanks for the reply @tt0suzy. Yes, that is the basic idea. Instead of
multiple `queryString.contains()` calls with in one `assertTrue`. Having one
assert per check would be helpful to keep the code clear:
```
assertTrue(queryString.contains("q=*:*"));
assertTrue(queryString.contains("qt=/select"));
...
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]