Method WaitUntil
WaitUntil(Func<bool>, CancellationToken?)
Waits until the specified expression returns true.
public static Task WaitUntil(Func<bool> test, CancellationToken? cancellationToken = null)
Parameters
testFunc<bool>The test expression.
cancellationTokenCancellationToken?A cancellation token that should be used to cancel the work.