Skip to content

Instantly share code, notes, and snippets.

Show Gist options
  • Save aataraxiaa/3317928452b74d691b3bd6f4feff7ffe to your computer and use it in GitHub Desktop.
Save aataraxiaa/3317928452b74d691b3bd6f4feff7ffe to your computer and use it in GitHub Desktop.
// MARK: - Asserts
extension ShowBugRobot {
@discardableResult
func assertShowBugAlertMessageDisplayed(file: StaticString = #file, line: UInt = #line) -> Self {
let alertMessage = ShowBugPage.Alerts.showBugAlertMessage.waitForExistence(timeout: 5)
XCTAssertTrue(alertMessage, "Show bug alert message not displayed", file: file, line: line)
return self
}
@discardableResult
func assertShowBugAlertMessageNotDisplayed(file: StaticString = #file, line: UInt = #line) -> Self {
let alertMessage = ShowBugPage.Alerts.showBugAlertMessage
XCTAssertFalse(alertMessage.exists, "Show bug alert message displayed", file: file, line: line)
return self
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment