mainCoroutineContext
The CoroutineContext that any UI/main thread work will be executed in.
NOTE: This should typically only be used in tests, as View
s and Lifecycle
s will be accessed in this context and those operations will throw if not performed on a valid thread.
Default: Dispatchers.Main.immediate