CLOVIS
09/21/2023, 8:44 PMTestScope from KotlinX.Coroutines.test (e.g. to have access to the backgroundScope). According to https://kotest.io/docs/framework/coroutines/test-coroutine-dispatcher.html, adding .config(coroutineTestScope = true) should be enough to enable it, but I'm not sure how to access it.
The only CoroutineScope I see is the ContainerScope provided in the test, and it doesn't look like it provides those accessors.sam
09/22/2023, 7:59 PMtestCoroutineSchedulerCLOVIS
09/23/2023, 10:14 AMCLOVIS
09/23/2023, 10:15 AMtestScheduler was renamed to coroutineTestScope , so I assume the scope is available somehow?CLOVIS
09/23/2023, 10:55 AMTestCoroutineInterceptor.kt:27 but never stored/passed to anything else, so it is just lost 😕CLOVIS
09/23/2023, 11:00 AMTestScopeContainer, but it never reaches the coroutine context of the test for some reason. Even if it did, it doesn't look like io.kotest.core.coroutines.TestScopeContainer is available externally?
Context of a test in StringSpec:
[RunningInRunTest, kotlinx.coroutines.test.TestCoroutineScheduler@2b4738b0, kotlinx.coroutines.test.CoroutineExceptionHandler$1@2b569700, TestScope[test started], StandardTestDispatcher[scheduler=kotlinx.coroutines.test.TestCoroutineScheduler@2b4738b0]]