diff --git a/.github/workflows/integration-tests.yml b/.github/workflows/integration-tests.yml index c06abbbb3..fad570a06 100644 --- a/.github/workflows/integration-tests.yml +++ b/.github/workflows/integration-tests.yml @@ -9,7 +9,7 @@ on: jobs: integration_tests: name: Integration Tests - runs-on: macos-26 + runs-on: macos-26-xlarge concurrency: # Only allow a single run of this workflow on each branch, automatically cancelling older runs. diff --git a/IntegrationTests/Sources/Common.swift b/IntegrationTests/Sources/Common.swift index 981c9ce9c..a1aa9d92c 100644 --- a/IntegrationTests/Sources/Common.swift +++ b/IntegrationTests/Sources/Common.swift @@ -57,25 +57,25 @@ extension XCUIApplication { } if alerts.count > 0 { - alerts.firstMatch.buttons["OK"].tap() + alerts.firstMatch.buttons["OK"].firstMatch.tap() } } webAuthenticationSessionAlertContinueButton.tap(.center) - let webAuthenticationView = webViews.firstMatch + let webAuthenticationView = XCUIApplication(bundleIdentifier: "com.apple.SafariViewService") XCTAssertTrue(webAuthenticationView.waitForExistence(timeout: 10.0)) webAuthenticationView.tap(.top) // Tap the web view to properly focus the app again. let webUsernameTextField = textFields["Username or Email"] XCTAssertTrue(webUsernameTextField.waitForExistence(timeout: 10.0)) webUsernameTextField.clearAndTypeText(username, app: self) - buttons["Done"].tap() // Dismiss the keyboard so that the password text field is fully hittable. + webAuthenticationView.buttons["selected"].firstMatch.tap() // Dismiss the keyboard so that the password text field is fully hittable. let webPasswordTextField = secureTextFields["Password"] XCTAssertTrue(webPasswordTextField.waitForExistence(timeout: 10.0)) webPasswordTextField.clearAndTypeText(password, app: self) - buttons["Done"].tap() // Dismiss the keyboard so that the continue button is fully hittable. + webAuthenticationView.buttons["selected"].firstMatch.tap() // Dismiss the keyboard so that the continue button is fully hittable. let webLoginButton = webAuthenticationView.buttons["Continue"] XCTAssertTrue(webLoginButton.waitForExistence(timeout: 10.0)) @@ -123,7 +123,7 @@ extension XCUIApplication { logoutButton.tap(.center) // Confirm logout - let alertLogoutButton = alerts.firstMatch.buttons["Sign out"] + let alertLogoutButton = alerts.firstMatch.buttons["Sign out"].firstMatch XCTAssertTrue(alertLogoutButton.waitForExistence(timeout: 10.0)) alertLogoutButton.tap(.center) diff --git a/IntegrationTests/Sources/UserFlowTests.swift b/IntegrationTests/Sources/UserFlowTests.swift index 74e68bee1..b9824d440 100644 --- a/IntegrationTests/Sources/UserFlowTests.swift +++ b/IntegrationTests/Sources/UserFlowTests.swift @@ -60,7 +60,7 @@ class UserFlowTests: XCTestCase { tapOnBackButton("Chats") // Cancel initial the room search - let searchCancelButton = app.buttons["Cancel"].firstMatch + let searchCancelButton = app.buttons["Close"].firstMatch XCTAssertTrue(searchCancelButton.waitForExistence(timeout: 10.0)) searchCancelButton.tap(.center) } @@ -263,7 +263,7 @@ class UserFlowTests: XCTestCase { /// When there are multiple buttons with the same label in the hierarchy, all the buttons we created /// should have an identifier set, and so this method will ignore those picking the one with only a label. private func tapOnBackButton(_ label: String = "Back") { - let button = app.buttons.matching(NSPredicate(format: "label == %@ && identifier == ''", label)).firstMatch + let button = app.buttons.matching(NSPredicate(format: "label == %@ && identifier == 'BackButton'", label)).firstMatch XCTAssertTrue(button.waitForExistence(timeout: 10.0)) button.tap(.center) }