@@ -411,8 +411,8 @@ abstract class BaseSyncIntegrationTest(
411411 db2.disconnect()
412412 turbine2.waitFor { ! it.connecting }
413413
414- turbine1.cancel ()
415- turbine2.cancel ()
414+ turbine1.cancelAndIgnoreRemainingEvents ()
415+ turbine2.cancelAndIgnoreRemainingEvents ()
416416 }
417417 }
418418
@@ -433,7 +433,7 @@ abstract class BaseSyncIntegrationTest(
433433 database.disconnect()
434434 turbine.waitFor { ! it.connecting }
435435
436- turbine.cancel ()
436+ turbine.cancelAndIgnoreRemainingEvents ()
437437 }
438438 }
439439
@@ -449,7 +449,7 @@ abstract class BaseSyncIntegrationTest(
449449 database.connect(connector, 1000L , retryDelayMs = 5000 , options = options)
450450 turbine.waitFor { it.connecting }
451451
452- turbine.cancel ()
452+ turbine.cancelAndIgnoreRemainingEvents ()
453453 }
454454 }
455455
@@ -650,7 +650,7 @@ abstract class BaseSyncIntegrationTest(
650650 turbine.waitFor { ! it.connected }
651651 connector.cachedCredentials shouldBe null
652652
653- turbine.cancel ()
653+ turbine.cancelAndIgnoreRemainingEvents ()
654654 }
655655 }
656656
@@ -686,7 +686,7 @@ abstract class BaseSyncIntegrationTest(
686686 // Should retry, and the second fetchCredentials call will work
687687 turbine.waitFor { it.connected }
688688
689- turbine.cancel ()
689+ turbine.cancelAndIgnoreRemainingEvents ()
690690 }
691691 }
692692}
@@ -740,7 +740,7 @@ class NewSyncIntegrationTest : BaseSyncIntegrationTest(true) {
740740
741741 turbine.waitFor { it.connected }
742742 fetchCredentialsCount shouldBe 2
743- turbine.cancel ()
743+ turbine.cancelAndIgnoreRemainingEvents ()
744744 }
745745 }
746746
0 commit comments