I use the Funspec testing style in kotest and I get a coroutineScope injected automatically by the framework as shown below.
class MyTestSpec: FunSpec() {
init {
test("test event loop") {
mySuspendedFunction() // a coroutineScope is already injected by the test framework here
}
}
}
How can I configure the Kotest framework to use an instance of kotlinx.coroutines.test.TestCoroutineScope
instead of a kotlinx.coroutines.CoroutineScope
in my tests? or is there a reason why this wouldn't make sense?