Skip to content

Commit

Permalink
GEODE-8602: Wait for view to change in locator test
Browse files Browse the repository at this point in the history
Wait for the view to have size 2 instead of asserting it in
MembershipIntegrationTest.locatorsStopWaitingForLocatorWaitTimeIfAllLocatorsContacted,
because the view is updated asynchronously.
  • Loading branch information
upthewaterspout authored Oct 14, 2020
1 parent 4d5ed9d commit 55a6cea
Showing 1 changed file with 2 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -305,8 +305,8 @@ public void locatorsStopWaitingForLocatorWaitTimeIfAllLocatorsContacted()
Membership<MemberIdentifier> membership1 = createMembership1.get(2, TimeUnit.MINUTES);

// Make sure the members see each other in the view
assertThat(membership0.getView().getMembers()).hasSize(2);
assertThat(membership1.getView().getMembers()).hasSize(2);
await().untilAsserted(() -> assertThat(membership0.getView().getMembers()).hasSize(2));
await().untilAsserted(() -> assertThat(membership1.getView().getMembers()).hasSize(2));
}

private CompletableFuture<Membership<MemberIdentifier>> launchLocator(
Expand Down

0 comments on commit 55a6cea

Please sign in to comment.