Skip to content

Commit

Permalink
Remove wrong assert in LocalCheckpointTrackerTests
Browse files Browse the repository at this point in the history
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
  • Loading branch information
dnhatn authored and kcm committed Oct 30, 2018
1 parent 74cbe0c commit cce7dda
Showing 1 changed file with 0 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -218,7 +218,6 @@ protected void doRun() throws Exception {
}
assertThat(tracker.getMaxSeqNo(), equalTo(maxOps - 1L));
assertThat(tracker.getCheckpoint(), equalTo(unFinishedSeq - 1L));
assertThat(tracker.contains(randomValueOtherThan(unFinishedSeq, () -> (long) randomFrom(seqNos))), equalTo(true));
assertThat(tracker.contains(unFinishedSeq), equalTo(false));
tracker.markSeqNoAsCompleted(unFinishedSeq);
assertThat(tracker.getCheckpoint(), equalTo(maxOps - 1L));
Expand Down

0 comments on commit cce7dda

Please sign in to comment.