Skip to content

Commit

Permalink
Add another assertion and fix formatting
Browse files Browse the repository at this point in the history
Signed-off-by: Daniel Widdis <widdis@gmail.com>
  • Loading branch information
dbwiddis committed Aug 19, 2022
1 parent 0ec0651 commit c497919
Showing 1 changed file with 3 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -343,9 +343,10 @@ public void testSortMissing(boolean first, boolean reverse) throws IOException {
);
// As of Lucene 9.0.0, totalHits may be a lower bound
if (topDocs.totalHits.relation == TotalHits.Relation.EQUAL_TO) {
assertEquals(numDocs, topDocs.totalHits.value);
assertEquals(numDocs, topDocs.totalHits.value);
} else {
assertTrue(numDocs >= topDocs.totalHits.value);
assertTrue(1000 <= topDocs.totalHits.value);
assertTrue(numDocs >= topDocs.totalHits.value);
}
BytesRef previousValue = first ? null : reverse ? UnicodeUtil.BIG_TERM : new BytesRef();
for (int i = 0; i < topDocs.scoreDocs.length; ++i) {
Expand Down

0 comments on commit c497919

Please sign in to comment.