Skip to content

Commit f10acaf

Browse files
committed
Remove wrong assert in LocalCheckpointTrackerTests
It's possible for the set "seqNos" to contain only the "unFinishedSeq" in the testConcurrentReplica test. If this is the case, the call `randomValueOtherThan` won't make any progress because the predicate will never be false. This commit removes this expectation because it's incorrect and it's no longer needed as we have a dedicated test to verify the contains method. Relates #33871
1 parent b253f36 commit f10acaf

File tree

1 file changed

+0
-1
lines changed

1 file changed

+0
-1
lines changed

server/src/test/java/org/elasticsearch/index/seqno/LocalCheckpointTrackerTests.java

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -218,7 +218,6 @@ protected void doRun() throws Exception {
218218
}
219219
assertThat(tracker.getMaxSeqNo(), equalTo(maxOps - 1L));
220220
assertThat(tracker.getCheckpoint(), equalTo(unFinishedSeq - 1L));
221-
assertThat(tracker.contains(randomValueOtherThan(unFinishedSeq, () -> (long) randomFrom(seqNos))), equalTo(true));
222221
assertThat(tracker.contains(unFinishedSeq), equalTo(false));
223222
tracker.markSeqNoAsCompleted(unFinishedSeq);
224223
assertThat(tracker.getCheckpoint(), equalTo(maxOps - 1L));

0 commit comments

Comments
 (0)