dweiss commented on code in PR #14518: URL: https://github.com/apache/lucene/pull/14518#discussion_r2050545494
########## lucene/core/src/test/org/apache/lucene/document/TestDocument.java: ########## @@ -233,7 +245,7 @@ public void testPositionIncrementMultiFields() throws Exception { PhraseQuery query = new PhraseQuery("indexed_not_tokenized", "test1", "test2"); ScoreDoc[] hits = searcher.search(query, 1000).scoreDocs; - assertEquals(1, hits.length); + assertThat(hits, arrayWithSize(1)); Review Comment: I think error messages are better... I haven't been using hamcrest much so I can't tell for sure - assertj definitely provides more informative error messages. I don't mind either way, even though hamcrest's style is confusing to me too. -- 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: issues-unsubscr...@lucene.apache.org For queries about this service, please contact Infrastructure at: us...@infra.apache.org --------------------------------------------------------------------- To unsubscribe, e-mail: issues-unsubscr...@lucene.apache.org For additional commands, e-mail: issues-h...@lucene.apache.org