Skip to content

Commit

Permalink
ARTEMIS-5173 Fixing a flaky test
Browse files Browse the repository at this point in the history
  • Loading branch information
clebertsuconic committed Dec 12, 2024
1 parent 3d6a1db commit 69df7ea
Showing 1 changed file with 5 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -159,7 +159,11 @@ protected void sendCrashBackupReceive() throws Exception {

CountDownLatch failoverHappened = new CountDownLatch(1);

session0.addFailoverListener((FailoverEventType type) -> failoverHappened.countDown());
session0.addFailoverListener((FailoverEventType type) -> {
if (type == FailoverEventType.FAILOVER_COMPLETED) {
failoverHappened.countDown();
}
});

for (TestableServer testableServer : toCrash) {
testableServer.crash().await(10, TimeUnit.SECONDS);
Expand Down

0 comments on commit 69df7ea

Please sign in to comment.