coWaitForLiveData
suspend fun <T> LiveData<T>.coWaitForLiveData(timeoutMs: Long = DEFAULT_WAIT_LIVE_DATA_TIMEOUT_MS, predicate: (T) -> Boolean): Boolean
Content copied to clipboard
Wait for the LiveData instance to have a given predicate from a coroutine context on the main thread.
Throws a TimeoutCancellationException if the timeoutMs was exceeded.