Skip to content

Commit 1382050

Browse files
committed
Handled PR notes from Yigit
1 parent 3feddff commit 1382050

File tree

2 files changed

+3
-3
lines changed

2 files changed

+3
-3
lines changed

core/kotlinx-coroutines-test/src/TestBuilders.kt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -83,7 +83,7 @@ fun TestCoroutineDispatcher.runBlockingTest(block: suspend TestCoroutineScope.()
8383
}
8484

8585
private fun CoroutineContext?.checkArguments(): Pair<CoroutineContext, ContinuationInterceptor> {
86-
var safeContext= this ?: TestCoroutineExceptionHandler() + TestCoroutineDispatcher()
86+
var safeContext = this ?: TestCoroutineExceptionHandler() + TestCoroutineDispatcher()
8787

8888
val dispatcher = safeContext[ContinuationInterceptor].run {
8989
this?.let {

core/kotlinx-coroutines-test/test/TestBuildersTest.kt

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -73,7 +73,7 @@ class TestBuildersTest {
7373
scope.runCurrent()
7474
assertTrue(deferred.isActive)
7575

76-
scope.advanceTimeToNextDelayed()
76+
scope.advanceUntilIdle()
7777
assertEquals(3, deferred.getCompleted())
7878
}
7979

@@ -93,7 +93,7 @@ class TestBuildersTest {
9393
retval
9494
}
9595

96-
scope.advanceTimeToNextDelayed()
96+
scope.advanceTimeBy(1_000)
9797
scope.launch {
9898
assertRunsFast {
9999
assertEquals(3, deferred.getCompleted())

0 commit comments

Comments
 (0)