Skip to content

Commit

Permalink
lint fixes
Browse files Browse the repository at this point in the history
  • Loading branch information
srushtisv committed Dec 6, 2024
1 parent 555854c commit 3fa8761
Showing 1 changed file with 13 additions and 9 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -188,11 +188,11 @@ class AuthenticationExampleUITests: XCTestCase {
let testEmail = "[email protected]"
app.textFields["Email"].tap()
app.typeText(testEmail)
app.buttons["return"].tap() // Dismiss keyboard
app.buttons["return"].tap() // dismiss keyboard
let testPassword = "sampleauthios"
app.textFields["Password"].tap()
app.typeText(testPassword)
app.buttons["return"].tap() // Dismiss keyboard
app.buttons["return"].tap() // dismiss keyboard
app.buttons["Login"].tap()
// enroll multifactor with phone
app.tabBars.buttons["Authentication"].tap()
Expand All @@ -215,7 +215,7 @@ class AuthenticationExampleUITests: XCTestCase {
app.tables.cells.staticTexts["Multifactor unenroll"].tap()
XCTAssertFalse(app.buttons["phone1"].exists) // unenrollment successful
app.buttons["Cancel"].tap()
// Sign out after unenroll
// sign out after unenroll
app.tabBars.buttons["Current User"].tap()
app.tabBars.firstMatch.buttons.element(boundBy: 1).tap()
}
Expand All @@ -226,20 +226,24 @@ class AuthenticationExampleUITests: XCTestCase {
let testEmail = "[email protected]"
app.textFields["Email"].tap()
app.typeText(testEmail)
app.buttons["return"].tap() // Dismiss keyboard
app.buttons["return"].tap() // dismiss keyboard
let testPassword = "sampleios123"
app.textFields["Password"].tap()
app.typeText(testPassword)
app.buttons["return"].tap() // Dismiss keyboard
app.buttons["return"].tap() // dismiss keyboard
app.buttons["Login"].tap()
// login with second factor
XCTAssertTrue(app.staticTexts["Choose a second factor to continue."].waitForExistence(timeout: 5))
let secondFactor = app.staticTexts["phone2"] // Select 'phone2' from the modal list
XCTAssertTrue(app.staticTexts["Choose a second factor to continue."]
.waitForExistence(timeout: 5))
let secondFactor = app.staticTexts["phone2"] // select 'phone2' as second factor
XCTAssertTrue(secondFactor.exists, "'phone2' option should be visible in the modal.")
secondFactor.tap()
app.buttons["Send Verification Code"].tap()
let verificationCodeInput = app.textFields["Enter verification code."]
XCTAssertTrue(verificationCodeInput.waitForExistence(timeout: 2), "OTP input field should appear.") // Wait for the OTP input field to appear
XCTAssertTrue(

Check failure on line 243 in FirebaseAuth/Tests/SampleSwift/AuthenticationExampleUITests/AuthenticationExampleUITests.swift

View workflow job for this annotation

GitHub Actions / integration-tests (AuthenticationExampleUITests)

testPhoneSecondFactorSignIn, XCTAssertTrue failed - Verification code input field should appear.

Check failure on line 243 in FirebaseAuth/Tests/SampleSwift/AuthenticationExampleUITests/AuthenticationExampleUITests.swift

View workflow job for this annotation

GitHub Actions / integration-tests (AuthenticationExampleUITests)

testPhoneSecondFactorSignIn, XCTAssertTrue failed - Verification code input field should appear.

Check failure on line 243 in FirebaseAuth/Tests/SampleSwift/AuthenticationExampleUITests/AuthenticationExampleUITests.swift

View workflow job for this annotation

GitHub Actions / integration-tests (AuthenticationExampleUITests)

testPhoneSecondFactorSignIn, XCTAssertTrue failed - Verification code input field should appear.
verificationCodeInput.waitForExistence(timeout: 2),
"Verification code input field should appear."
) // wait for the verification code input field to appear
verificationCodeInput.tap()
let testVerificationCode = "123456"
verificationCodeInput.typeText(testVerificationCode)
Expand All @@ -249,7 +253,7 @@ class AuthenticationExampleUITests: XCTestCase {
// sign out
let signOutButton = app.buttons["Sign Out"]
if signOutButton.exists {
signOutButton.tap()
signOutButton.tap()
}
}

Expand Down

0 comments on commit 3fa8761

Please sign in to comment.