How can I mock the following function act
.
class Some {
internal lateinit var coroutineScope: LifecycleCoroutineScope
...
fun act() {
coroutineScope.launch {
...
}
}
}
I am using mockk
and kotlinx-coroutines-test
for unit-testing this. But it can only mock CoroutineScope
and not LifecycleCoroutineScope
.