Skip to content

Commit

Permalink
Merge pull request #30785 from cescoffier/redis-search-aggregation-te…
Browse files Browse the repository at this point in the history
…st-fix

Improve robustness of the Redis Search - Aggregation test
  • Loading branch information
gsmet authored Feb 1, 2023
2 parents 0adb546 + 9cc50e1 commit 9caa731
Showing 1 changed file with 2 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -487,7 +487,7 @@ void testAggregation() {
"num_visits"))
.sortBy(new AggregateArgs.SortBy().ascending("@day").descending("@country"))
.withCursor().cursorCount(2));
assertThat(result.count()).isBetween(1, 2);
assertThat(result.count()).isBetween(0, 2);
assertThat(result.documents()).allSatisfy(d -> {
assertThat(d.property("day").asInteger()).isPositive();
assertThat(d.property("country").asString()).isNotNull();
Expand All @@ -501,7 +501,7 @@ void testAggregation() {
fail("Too many cursor read commands before reaching the end of the stream: " + read);
}
result = search.ftCursorRead("myIndex", result.cursor());
assertThat(result.count()).isBetween(1, 2);
assertThat(result.count()).isBetween(0, 2);
assertThat(result.documents()).allSatisfy(d -> {
assertThat(d.property("day").asInteger()).isPositive();
assertThat(d.property("country").asString()).isNotNull();
Expand Down

0 comments on commit 9caa731

Please sign in to comment.