Method WaitUntil
- Namespace
- GrindFest
- Assembly
- GrindFest.dll
WaitUntil(string, Func<bool>, float, Func<string>)
Wait until a condition is true, or throw on timeout.
protected IEnumerator WaitUntil(string description, Func<bool> condition, float timeout = 10, Func<string> describeOnTimeout = null)
Parameters
descriptionstringconditionFunc<bool>timeoutfloatdescribeOnTimeoutFunc<string>Built only on the failure path, so a passing wait pays nothing for it - and that matters: the usual one walks the whole UI tree. Without it a timeout says only WHICH condition stayed false, which is how "Timeout waiting for 'Master Volume' visible" named neither the panel nor the state it was in.