@@ -188,11 +188,11 @@ class AuthenticationExampleUITests: XCTestCase {
188188 let testEmail = " [email protected] " 189189 app. textFields [ " Email " ] . tap ( )
190190 app. typeText ( testEmail)
191- app. buttons [ " return " ] . tap ( ) // Dismiss keyboard
191+ app. buttons [ " return " ] . tap ( ) // dismiss keyboard
192192 let testPassword = " sampleauthios "
193193 app. textFields [ " Password " ] . tap ( )
194194 app. typeText ( testPassword)
195- app. buttons [ " return " ] . tap ( ) // Dismiss keyboard
195+ app. buttons [ " return " ] . tap ( ) // dismiss keyboard
196196 app. buttons [ " Login " ] . tap ( )
197197 // enroll multifactor with phone
198198 app. tabBars. buttons [ " Authentication " ] . tap ( )
@@ -215,7 +215,7 @@ class AuthenticationExampleUITests: XCTestCase {
215215 app. tables. cells. staticTexts [ " Multifactor unenroll " ] . tap ( )
216216 XCTAssertFalse ( app. buttons [ " phone1 " ] . exists) // unenrollment successful
217217 app. buttons [ " Cancel " ] . tap ( )
218- // Sign out after unenroll
218+ // sign out after unenroll
219219 app. tabBars. buttons [ " Current User " ] . tap ( )
220220 app. tabBars. firstMatch. buttons. element ( boundBy: 1 ) . tap ( )
221221 }
@@ -226,20 +226,24 @@ class AuthenticationExampleUITests: XCTestCase {
226226 let testEmail = " [email protected] " 227227 app. textFields [ " Email " ] . tap ( )
228228 app. typeText ( testEmail)
229- app. buttons [ " return " ] . tap ( ) // Dismiss keyboard
229+ app. buttons [ " return " ] . tap ( ) // dismiss keyboard
230230 let testPassword = " sampleios123 "
231231 app. textFields [ " Password " ] . tap ( )
232232 app. typeText ( testPassword)
233- app. buttons [ " return " ] . tap ( ) // Dismiss keyboard
233+ app. buttons [ " return " ] . tap ( ) // dismiss keyboard
234234 app. buttons [ " Login " ] . tap ( )
235235 // login with second factor
236- XCTAssertTrue ( app. staticTexts [ " Choose a second factor to continue. " ] . waitForExistence ( timeout: 5 ) )
237- let secondFactor = app. staticTexts [ " phone2 " ] // Select 'phone2' from the modal list
236+ XCTAssertTrue ( app. staticTexts [ " Choose a second factor to continue. " ]
237+ . waitForExistence ( timeout: 5 ) )
238+ let secondFactor = app. staticTexts [ " phone2 " ] // select 'phone2' as second factor
238239 XCTAssertTrue ( secondFactor. exists, " 'phone2' option should be visible in the modal. " )
239240 secondFactor. tap ( )
240241 app. buttons [ " Send Verification Code " ] . tap ( )
241242 let verificationCodeInput = app. textFields [ " Enter verification code. " ]
242- XCTAssertTrue ( verificationCodeInput. waitForExistence ( timeout: 2 ) , " OTP input field should appear. " ) // Wait for the OTP input field to appear
243+ XCTAssertTrue (
244+ verificationCodeInput. waitForExistence ( timeout: 2 ) ,
245+ " Verification code input field should appear. "
246+ ) // wait for the verification code input field to appear
243247 verificationCodeInput. tap ( )
244248 let testVerificationCode = " 123456 "
245249 verificationCodeInput. typeText ( testVerificationCode)
@@ -249,7 +253,7 @@ class AuthenticationExampleUITests: XCTestCase {
249253 // sign out
250254 let signOutButton = app. buttons [ " Sign Out " ]
251255 if signOutButton. exists {
252- signOutButton. tap ( )
256+ signOutButton. tap ( )
253257 }
254258 }
255259
0 commit comments