Skip to content

Commit ea04f68

Browse files
committed
fix: update coroutines test
1 parent aa63ae4 commit ea04f68

File tree

1 file changed

+4
-5
lines changed

1 file changed

+4
-5
lines changed

src/test/kotlin/com/compiler/server/CoroutinesRunnerTest.kt

Lines changed: 4 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -180,20 +180,19 @@ class CoroutinesRunnerTest : BaseExecutorTest() {
180180
}
181181

182182
@Test
183-
@Disabled("@ToDo: incorrect result - 'A\n<outStream>B\n</outStream>'")
184183
fun `IO coroutine out order`() {
185184
run(
186185
//language=kotlin
187186
code = """
188187
import kotlinx.coroutines.*
189188
190-
fun main() {
191-
CoroutineScope(Dispatchers.IO).launch {
192-
delay(1)
189+
fun main() = runBlocking {
190+
CoroutineScope(Dispatchers.IO).launch {
191+
delay(1000)
193192
println("A")
194193
}
195194
println("B")
196-
195+
delay(2000)
197196
}
198197
""".trimIndent(),
199198
contains = "<outStream>B\nA\n</outStream>"

0 commit comments

Comments
 (0)