You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Background info: runTest won't finish unless all the coroutines launched inside also finished. This is what I'd expect for most cases but it becomes problematic if I want something along the lines of:
val uiState = myFlow
.stateIn(viewModelScope, SharingStarted.Eagerly, UiStates.Empty)
The problem is that runTest will hang and time out because of the job started by stateIn/shareIn which is kept active until viewModelScope is canceled.
The text was updated successfully, but these errors were encountered:
Background info:
runTest
won't finish unless all the coroutines launched inside also finished. This is what I'd expect for most cases but it becomes problematic if I want something along the lines of:The problem is that
runTest
will hang and time out because of the job started bystateIn
/shareIn
which is kept active untilviewModelScope
is canceled.The text was updated successfully, but these errors were encountered: