Skip to content

Commit

Permalink
reverted removal of waitForValueMatchingPredicate
Browse files Browse the repository at this point in the history
  • Loading branch information
mossmana committed Sep 11, 2023
1 parent 7222352 commit b9a655c
Showing 1 changed file with 7 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -949,7 +949,13 @@ void googleMapsTests() {
expect(iwVisibleStatus, false);

await controller.showMarkerInfoWindow(marker.markerId);
iwVisibleStatus = await controller.isMarkerInfoWindowShown(marker.markerId);
// The Maps SDK doesn't always return true for whether it is shown
// immediately after showing it, so wait for it to report as shown.
iwVisibleStatus = await waitForValueMatchingPredicate<bool>(
tester,
() => controller.isMarkerInfoWindowShown(marker.markerId),
(bool visible) => visible) ??
false;
expect(iwVisibleStatus, true);

await controller.hideMarkerInfoWindow(marker.markerId);
Expand Down

0 comments on commit b9a655c

Please sign in to comment.