From f5561c5caea16f38df21eecd85afdf0d12f63d9a Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=C3=81lison=20Fernandes?= Date: Mon, 27 Oct 2025 16:45:21 +0000 Subject: [PATCH 1/8] Output booted simulator ID and use it in Test step --- .github/actions/boot-simulator/action.yml | 7 +++++++ .github/workflows/test-bwa.yml | 5 ++++- .github/workflows/test.yml | 5 ++++- 3 files changed, 15 insertions(+), 2 deletions(-) diff --git a/.github/actions/boot-simulator/action.yml b/.github/actions/boot-simulator/action.yml index 2c217e7d2c..41a6b2d0d1 100644 --- a/.github/actions/boot-simulator/action.yml +++ b/.github/actions/boot-simulator/action.yml @@ -10,10 +10,16 @@ inputs: description: 'iOS version for the simulator (e.g., 26.0)' required: true +outputs: + simulator-id: + description: 'The UDID of the booted simulator device' + value: ${{ steps.boot.outputs.device-id }} + runs: using: 'composite' steps: - name: Boot Simulator + id: boot shell: bash env: _SIMULATOR_NAME: ${{ inputs.simulator-name }} @@ -28,6 +34,7 @@ runs: xcrun simctl runtime dyld_shared_cache update --all echo "--------------------------------" echo "👀 Booting simulator: $_SIMULATOR_NAME ($_SIMULATOR_VERSION) with ID: $DEVICE_ID" + echo "device-id=$DEVICE_ID" >> "$GITHUB_OUTPUT" i=1 max=5 diff --git a/.github/workflows/test-bwa.yml b/.github/workflows/test-bwa.yml index 6e70269a3f..5788ec415b 100644 --- a/.github/workflows/test-bwa.yml +++ b/.github/workflows/test-bwa.yml @@ -128,6 +128,7 @@ jobs: ./Scripts/bootstrap.sh - name: Boot Simulator + id: boot-simulator uses: ./.github/actions/boot-simulator with: simulator-name: ${{ env._SIMULATOR_NAME }} @@ -147,13 +148,15 @@ jobs: kill "$PYEETD_PID" - name: Test + env: + _SIMULATOR_ID: ${{ steps.boot-simulator.outputs.simulator-id }} run: | python Scripts/pyeetd/main.py & PYEETD_PID=$! xcrun xcodebuild test-without-building \ -workspace Bitwarden.xcworkspace \ -scheme Authenticator \ -configuration Debug \ - -destination "platform=iOS Simulator,name=$_SIMULATOR_NAME,OS=$_SIMULATOR_VERSION" \ + -destination "platform=iOS Simulator,id=$_SIMULATOR_ID" \ -resultBundlePath "$_TESTS_RESULT_BUNDLE_PATH" \ -derivedDataPath build/DerivedData \ -test-timeouts-enabled yes \ diff --git a/.github/workflows/test.yml b/.github/workflows/test.yml index 887a0b5143..be2277e816 100644 --- a/.github/workflows/test.yml +++ b/.github/workflows/test.yml @@ -123,6 +123,7 @@ jobs: ./Scripts/bootstrap.sh - name: Boot Simulator + id: boot-simulator uses: ./.github/actions/boot-simulator with: simulator-name: ${{ env._SIMULATOR_NAME }} @@ -142,13 +143,15 @@ jobs: kill "$PYEETD_PID" - name: Test + env: + _SIMULATOR_ID: ${{ steps.boot-simulator.outputs.simulator-id }} run: | python Scripts/pyeetd/main.py & PYEETD_PID=$! xcrun xcodebuild test-without-building \ -workspace Bitwarden.xcworkspace \ -scheme Bitwarden \ -configuration Debug \ - -destination "platform=iOS Simulator,name=$_SIMULATOR_NAME,OS=$_SIMULATOR_VERSION" \ + -destination "platform=iOS Simulator,id=$_SIMULATOR_ID" \ -resultBundlePath $_TESTS_RESULT_BUNDLE_PATH \ -derivedDataPath build/DerivedData \ -test-timeouts-enabled yes \ From a329c2f28b6d47be7c05ae7d4d5a454fd5406b18 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=C3=81lison=20Fernandes?= Date: Mon, 27 Oct 2025 16:45:40 +0000 Subject: [PATCH 2/8] Remove simulator destionation from Build step --- .github/workflows/test-bwa.yml | 1 - .github/workflows/test.yml | 1 - 2 files changed, 2 deletions(-) diff --git a/.github/workflows/test-bwa.yml b/.github/workflows/test-bwa.yml index 5788ec415b..930cee3d96 100644 --- a/.github/workflows/test-bwa.yml +++ b/.github/workflows/test-bwa.yml @@ -141,7 +141,6 @@ jobs: -workspace Bitwarden.xcworkspace \ -scheme Authenticator \ -configuration Debug \ - -destination "platform=iOS Simulator,name=$_SIMULATOR_NAME,OS=$_SIMULATOR_VERSION" \ -derivedDataPath build/DerivedData \ -resultBundlePath "$_BUILD_RESULT_BUNDLE_PATH" \ -quiet diff --git a/.github/workflows/test.yml b/.github/workflows/test.yml index be2277e816..27d4e99554 100644 --- a/.github/workflows/test.yml +++ b/.github/workflows/test.yml @@ -136,7 +136,6 @@ jobs: -workspace Bitwarden.xcworkspace \ -scheme Bitwarden \ -configuration Debug \ - -destination "platform=iOS Simulator,name=$_SIMULATOR_NAME,OS=$_SIMULATOR_VERSION" \ -derivedDataPath build/DerivedData \ -resultBundlePath "$_BUILD_RESULT_BUNDLE_PATH" \ -quiet From f721669f9514fdb7cb5dca6034b9503e2a584cbc Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=C3=81lison=20Fernandes?= Date: Mon, 27 Oct 2025 16:56:35 +0000 Subject: [PATCH 3/8] Revert "Remove simulator destionation from Build step" This reverts commit a329c2f28b6d47be7c05ae7d4d5a454fd5406b18. --- .github/workflows/test-bwa.yml | 1 + .github/workflows/test.yml | 1 + 2 files changed, 2 insertions(+) diff --git a/.github/workflows/test-bwa.yml b/.github/workflows/test-bwa.yml index 930cee3d96..5788ec415b 100644 --- a/.github/workflows/test-bwa.yml +++ b/.github/workflows/test-bwa.yml @@ -141,6 +141,7 @@ jobs: -workspace Bitwarden.xcworkspace \ -scheme Authenticator \ -configuration Debug \ + -destination "platform=iOS Simulator,name=$_SIMULATOR_NAME,OS=$_SIMULATOR_VERSION" \ -derivedDataPath build/DerivedData \ -resultBundlePath "$_BUILD_RESULT_BUNDLE_PATH" \ -quiet diff --git a/.github/workflows/test.yml b/.github/workflows/test.yml index 27d4e99554..be2277e816 100644 --- a/.github/workflows/test.yml +++ b/.github/workflows/test.yml @@ -136,6 +136,7 @@ jobs: -workspace Bitwarden.xcworkspace \ -scheme Bitwarden \ -configuration Debug \ + -destination "platform=iOS Simulator,name=$_SIMULATOR_NAME,OS=$_SIMULATOR_VERSION" \ -derivedDataPath build/DerivedData \ -resultBundlePath "$_BUILD_RESULT_BUNDLE_PATH" \ -quiet From 18a67e071c669f336eb0c22ffc37dde7479a1002 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=C3=81lison=20Fernandes?= Date: Mon, 27 Oct 2025 16:58:31 +0000 Subject: [PATCH 4/8] Use simulator ID in build step --- .github/workflows/test-bwa.yml | 2 +- .github/workflows/test.yml | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/.github/workflows/test-bwa.yml b/.github/workflows/test-bwa.yml index 5788ec415b..b47efa70b6 100644 --- a/.github/workflows/test-bwa.yml +++ b/.github/workflows/test-bwa.yml @@ -141,7 +141,7 @@ jobs: -workspace Bitwarden.xcworkspace \ -scheme Authenticator \ -configuration Debug \ - -destination "platform=iOS Simulator,name=$_SIMULATOR_NAME,OS=$_SIMULATOR_VERSION" \ + -destination "platform=iOS Simulator,name=$_SIMULATOR_NAME,OS=26.0.1" \ -derivedDataPath build/DerivedData \ -resultBundlePath "$_BUILD_RESULT_BUNDLE_PATH" \ -quiet diff --git a/.github/workflows/test.yml b/.github/workflows/test.yml index be2277e816..d689e4055d 100644 --- a/.github/workflows/test.yml +++ b/.github/workflows/test.yml @@ -136,7 +136,7 @@ jobs: -workspace Bitwarden.xcworkspace \ -scheme Bitwarden \ -configuration Debug \ - -destination "platform=iOS Simulator,name=$_SIMULATOR_NAME,OS=$_SIMULATOR_VERSION" \ + -destination "platform=iOS Simulator,id=$_SIMULATOR_ID" \ -derivedDataPath build/DerivedData \ -resultBundlePath "$_BUILD_RESULT_BUNDLE_PATH" \ -quiet From 5772816632f4de0dfab47144fff2b110d3c33f4e Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=C3=81lison=20Fernandes?= Date: Wed, 29 Oct 2025 21:42:00 +0000 Subject: [PATCH 5/8] Set Test Iterations 1 --- .github/workflows/test-bwa.yml | 5 ++++- .github/workflows/test.yml | 3 +++ 2 files changed, 7 insertions(+), 1 deletion(-) diff --git a/.github/workflows/test-bwa.yml b/.github/workflows/test-bwa.yml index 980bd4f83e..ee84c8bdb1 100644 --- a/.github/workflows/test-bwa.yml +++ b/.github/workflows/test-bwa.yml @@ -135,13 +135,15 @@ jobs: simulator-version: ${{ env._SIMULATOR_VERSION }} - name: Build + env: + _SIMULATOR_ID: ${{ steps.boot-simulator.outputs.simulator-id }} run: | python Scripts/pyeetd/main.py & PYEETD_PID=$! xcrun xcodebuild build-for-testing \ -workspace Bitwarden.xcworkspace \ -scheme Authenticator \ -configuration Debug \ - -destination "platform=iOS Simulator,name=$_SIMULATOR_NAME,OS=26.0.1" \ + -destination "platform=iOS Simulator,id=$_SIMULATOR_ID" \ -derivedDataPath build/DerivedData \ -resultBundlePath "$_BUILD_RESULT_BUNDLE_PATH" \ -quiet @@ -162,6 +164,7 @@ jobs: -test-timeouts-enabled yes \ -maximum-test-execution-time-allowance 1 \ -retry-tests-on-failure \ + -test-iterations 1 \ -test-repetition-relaunch-enabled YES \ -quiet kill "$PYEETD_PID" diff --git a/.github/workflows/test.yml b/.github/workflows/test.yml index f0eac21ae9..4fe58ed064 100644 --- a/.github/workflows/test.yml +++ b/.github/workflows/test.yml @@ -130,6 +130,8 @@ jobs: simulator-version: ${{ env._SIMULATOR_VERSION }} - name: Build + env: + _SIMULATOR_ID: ${{ steps.boot-simulator.outputs.simulator-id }} run: | python Scripts/pyeetd/main.py & PYEETD_PID=$! xcrun xcodebuild build-for-testing \ @@ -157,6 +159,7 @@ jobs: -test-timeouts-enabled yes \ -maximum-test-execution-time-allowance 1 \ -retry-tests-on-failure \ + -test-iterations 1 \ -test-repetition-relaunch-enabled YES \ -quiet kill $PYEETD_PID From 302c2b34b09e3253c66fedd77be18ea515f2b8ca Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=C3=81lison=20Fernandes?= Date: Thu, 30 Oct 2025 21:52:11 +0000 Subject: [PATCH 6/8] Remove retry tests on failure and test repetition relaunch. --- .github/workflows/test-bwa.yml | 3 --- .github/workflows/test.yml | 3 --- 2 files changed, 6 deletions(-) diff --git a/.github/workflows/test-bwa.yml b/.github/workflows/test-bwa.yml index ee84c8bdb1..2858eb5df9 100644 --- a/.github/workflows/test-bwa.yml +++ b/.github/workflows/test-bwa.yml @@ -163,9 +163,6 @@ jobs: -derivedDataPath build/DerivedData \ -test-timeouts-enabled yes \ -maximum-test-execution-time-allowance 1 \ - -retry-tests-on-failure \ - -test-iterations 1 \ - -test-repetition-relaunch-enabled YES \ -quiet kill "$PYEETD_PID" diff --git a/.github/workflows/test.yml b/.github/workflows/test.yml index 4fe58ed064..9e360e43ce 100644 --- a/.github/workflows/test.yml +++ b/.github/workflows/test.yml @@ -158,9 +158,6 @@ jobs: -derivedDataPath build/DerivedData \ -test-timeouts-enabled yes \ -maximum-test-execution-time-allowance 1 \ - -retry-tests-on-failure \ - -test-iterations 1 \ - -test-repetition-relaunch-enabled YES \ -quiet kill $PYEETD_PID From 87cc5e643d37a19b9cad416a2a7df008be3878ec Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=C3=81lison=20Fernandes?= Date: Thu, 30 Oct 2025 22:00:52 +0000 Subject: [PATCH 7/8] Update description --- .github/actions/boot-simulator/action.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/actions/boot-simulator/action.yml b/.github/actions/boot-simulator/action.yml index c94ccef42b..75a9083e7b 100644 --- a/.github/actions/boot-simulator/action.yml +++ b/.github/actions/boot-simulator/action.yml @@ -12,7 +12,7 @@ inputs: outputs: simulator-id: - description: 'The UDID of the booted simulator device' + description: 'The identifier of the booted simulator device' value: ${{ steps.boot.outputs.device-id }} runs: From 88dd8e72c68fa56a6e92a6ed880000d491523a32 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=C3=81lison=20Fernandes?= Date: Thu, 30 Oct 2025 23:13:01 +0000 Subject: [PATCH 8/8] Add quotes missed in previous PRs. --- .github/workflows/test.yml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/.github/workflows/test.yml b/.github/workflows/test.yml index 9e360e43ce..b5131a30f5 100644 --- a/.github/workflows/test.yml +++ b/.github/workflows/test.yml @@ -154,12 +154,12 @@ jobs: -scheme Bitwarden \ -configuration Debug \ -destination "platform=iOS Simulator,id=$_SIMULATOR_ID" \ - -resultBundlePath $_TESTS_RESULT_BUNDLE_PATH \ + -resultBundlePath "$_TESTS_RESULT_BUNDLE_PATH" \ -derivedDataPath build/DerivedData \ -test-timeouts-enabled yes \ -maximum-test-execution-time-allowance 1 \ -quiet - kill $PYEETD_PID + kill "$PYEETD_PID" - name: Print Logs Summary if: always()