You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
// function to wait for an ui element to appear on screen, with a default wait time of 20 seconds// XCTWaiter was introduced after Xcode 8.3, which is handling better the timewait, it's not failing the test. It uses an enum which returns: 'Waiters can be used with or without a delegate to respond to events such as completion, timeout, or invalid expectation fulfilment.'@discardableResultfunc uiElementExists(for element:XCUIElement, timeout:TimeInterval=20)->Bool{letexpectation=XCTNSPredicateExpectation(predicate:NSPredicate(format:"exists == true"), object: element)letresult=XCTWaiter().wait(for:[expectation], timeout: timeout)
guard result ==.completed else{return false
}return true
}
The text was updated successfully, but these errors were encountered:
The text was updated successfully, but these errors were encountered: