diff --git a/.github/workflows/integration-tests.yml b/.github/workflows/integration-tests.yml index 076865d23..a4e9895b8 100644 --- a/.github/workflows/integration-tests.yml +++ b/.github/workflows/integration-tests.yml @@ -2,14 +2,14 @@ name: Integration tests on: schedule: - - cron: '0 2 * * 1-5' + - cron: '0 * * * *' workflow_dispatch: jobs: integration_tests: name: Integration Tests - runs-on: macos-13 + runs-on: perf-only concurrency: # Only allow a single run of this workflow on each branch, automatically cancelling older runs. @@ -54,7 +54,6 @@ jobs: path: ~/Library/Logs/scan/IntegrationTests-IntegrationTests.log retention-days: 2 if-no-files-found: ignore - - name: Checkout gh-pages branch (for perf stats) if: always() diff --git a/IntegrationTests/Sources/ApplicationTests.swift b/IntegrationTests/Sources/ApplicationTests.swift index 13c161d50..e41d3cfaf 100644 --- a/IntegrationTests/Sources/ApplicationTests.swift +++ b/IntegrationTests/Sources/ApplicationTests.swift @@ -30,8 +30,5 @@ class ApplicationTests: XCTestCase { XCTFail("Couldn't retrieve app launch duration") return } - - let expectedDuration = 10.0 - XCTAssertLessThanOrEqual(actualDuration, expectedDuration) } } diff --git a/IntegrationTests/Sources/LoginTests.swift b/IntegrationTests/Sources/LoginTests.swift index cf35d478a..207513cef 100644 --- a/IntegrationTests/Sources/LoginTests.swift +++ b/IntegrationTests/Sources/LoginTests.swift @@ -17,8 +17,6 @@ import XCTest class LoginTests: XCTestCase { - let expectedDuration = 100.0 - func testLoginFlow() throws { let parser = TestMeasurementParser() parser.capture(testCase: self) { @@ -31,10 +29,8 @@ class LoginTests: XCTestCase { XCTFail("Couldn't retrieve duration") return } - - XCTAssertLessThanOrEqual(actualDuration, expectedDuration) } - + private func runLoginLogoutFlow() { let app = Application.launch() @@ -79,8 +75,10 @@ class LoginTests: XCTestCase { // Wait for login to finish let doesNotExistPredicate = NSPredicate(format: "exists == 0") expectation(for: doesNotExistPredicate, evaluatedWith: nextButton) - waitForExpectations(timeout: expectedDuration) - + + // timeout is huge because we're waiting for server actions as well. + waitForExpectations(timeout: 300.0) + // Handle save password sheet let savePasswordButton = app.buttons["Save Password"] if savePasswordButton.waitForExistence(timeout: 10.0) { diff --git a/fastlane/Fastfile b/fastlane/Fastfile index 93144121a..ae4324f41 100644 --- a/fastlane/Fastfile +++ b/fastlane/Fastfile @@ -151,7 +151,8 @@ lane :integration_tests do scheme: "IntegrationTests", devices: ["iPhone 13 Pro"], ensure_devices_found: true, - result_bundle: true + result_bundle: true, + include_simulator_logs: true ) slather(