Created
May 23, 2018 12:50
-
-
Save Pulichev/49d7bbda5b4cb5620d25873a4bcdb405 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
func testExample() { | |
app.launchArguments.append("--clearuser") | |
app.launch() | |
expectation(for: exists, evaluatedWith: app.buttons["Other options"], handler: nil) | |
waitForExpectations(timeout: 20, handler: nil) | |
snapshot("Auth") | |
app.buttons["Other options"].tap() | |
app.buttons["Sign In"].tap() | |
let emailTextField = app.textFields.matching(identifier: "email") | |
let passwordTextField = app.secureTextFields.matching(identifier: "password") | |
emailTextField.element.tap() | |
emailTextField.element.typeText("eeeeemaaaaaiiiillll\n") | |
passwordTextField.element.typeText("123456") | |
sleep(1) | |
app.buttons.matching(identifier: "final").element.tap() | |
expectation(for: exists, evaluatedWith: app.tabBars.buttons["Profile"], handler: nil) | |
waitForExpectations(timeout: 5, handler: nil) | |
app.tabBars.buttons["Profile"].tap() | |
sleep(2) | |
snapshot("Profile") | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment