On this page
LibTmux.Testing.TmuxWait.UntilAsync
- Module
- LibTmux.Testing
- Declared in
- TmuxWait
- Package
- LibTmux
- Source
- src/LibTmux/Testing/TmuxWait.cs
- UntilAsync ( probe : Func<CancellationToken, Task<bool>> , timeout : TimeSpan , interval : TimeSpan , throwOnTimeout : bool , cancellationToken : CancellationToken ) Task<bool> ( probe : Func<CancellationToken, Task<T>> , predicate : Func<T, bool> , timeout : TimeSpan , interval : TimeSpan , cancellationToken : CancellationToken ) Task<T>
-
Waits until a probe reports the state was reached.
- Parameters
-
-
probe ( Func<CancellationToken, Task<T>> ) – Reads the current value.
-
predicate ( Func<T, bool> ) – Answers whether a reading is the wanted one.
-
timeout ( TimeSpan ) – How long to keep reading.
-
interval ( TimeSpan ) – How long to wait between readings.
-
cancellationToken ( CancellationToken ) – Cancels the wait.
-
- Returns
-
The first reading the predicate accepted.
- Raises
-
-
TmuxWaitTimeoutException – No reading was accepted in time.
-
Discussed in Waiting and retrying
0 declared, 0 inherited