waitForSleepers

suspend fun waitForSleepers(count: Int, timeout: Duration = 2.seconds)(source)

Waits in real time until at least count coroutines are sleeping on this clock.

Parameters

count

The nonnegative number of sleepers to wait for.

timeout

The real-time observation budget.

Throws

with the last sleeper count when the deadline passes.