From f5445dd6d587b1192faf6d83e3ebb7e4a993486d Mon Sep 17 00:00:00 2001 From: Katherine Bertelsen Date: Thu, 24 Oct 2024 13:45:33 -0500 Subject: [PATCH 1/5] Pull test simulator information into separate files --- .github/workflows/test.yml | 4 +++- .test-simulator-device-name | 1 + .test-simulator-ios-version | 1 + 3 files changed, 5 insertions(+), 1 deletion(-) create mode 100644 .test-simulator-device-name create mode 100644 .test-simulator-ios-version diff --git a/.github/workflows/test.yml b/.github/workflows/test.yml index 2cbcec84f9..d68aa30bc4 100644 --- a/.github/workflows/test.yml +++ b/.github/workflows/test.yml @@ -72,6 +72,8 @@ jobs: - name: Read default Xcode version run: | echo "DEFAULT_XCODE_VERSION=$(cat .xcode-version | tr -d '\n')" >> "$GITHUB_ENV" + echo "DEFAULT_SIMULATOR_NAME=$(cat .test-simulator-device-name | tr -d '\n')" >> "$GITHUB_ENV" + echo "DEFAULT_SIMULATOR_VERSION=$(cat .test-simulator-ios-version | tr -d '\n')" >> "$GITHUB_ENV" - name: Set Xcode version uses: maxim-lobanov/setup-xcode@60606e260d2fc5762a71e64e74b2174e8ea3c8bd # v1.6.0 @@ -117,7 +119,7 @@ jobs: -project Bitwarden.xcodeproj \ -scheme Bitwarden \ -configuration Debug \ - -destination "platform=iOS Simulator,name=${{ env.SIMULATOR_NAME }},OS=${{ env.SIMULATOR_VERSION }}" \ + -destination "platform=iOS Simulator,name=${{ env.SIMULATOR_NAME || env.DEFAULT_SIMULATOR_NAME }},OS=${{ env.SIMULATOR_VERSION || env.DEFAULT_SIMULATOR_VERSION }}" \ -resultBundlePath ${{ env.RESULT_BUNDLE_PATH }} \ -derivedDataPath build/DerivedData \ | xcbeautify --renderer github-actions diff --git a/.test-simulator-device-name b/.test-simulator-device-name new file mode 100644 index 0000000000..5b8e0214cc --- /dev/null +++ b/.test-simulator-device-name @@ -0,0 +1 @@ +iPhone 16 Pro diff --git a/.test-simulator-ios-version b/.test-simulator-ios-version new file mode 100644 index 0000000000..33718932a4 --- /dev/null +++ b/.test-simulator-ios-version @@ -0,0 +1 @@ +18.1 From 4d275410958dce4cee0029cc31f8da721fbcab33 Mon Sep 17 00:00:00 2001 From: Katherine Bertelsen Date: Thu, 24 Oct 2024 14:19:28 -0500 Subject: [PATCH 2/5] Remove previous defaults --- .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 d68aa30bc4..b4d4028f3c 100644 --- a/.github/workflows/test.yml +++ b/.github/workflows/test.yml @@ -36,8 +36,8 @@ env: MINT_LINK_PATH: .mint/bin MINT_PATH: .mint/lib RESULT_BUNDLE_PATH: build/BitwardenTests.xcresult - SIMULATOR_NAME: ${{ inputs.simulator-name || 'iPhone 15 Pro' }} - SIMULATOR_VERSION: ${{ inputs.simulator-version || '18.0' }} + SIMULATOR_NAME: ${{ inputs.simulator-name }} + SIMULATOR_VERSION: ${{ inputs.simulator-version }} XCODE_VERSION: ${{ inputs.xcode-version }} jobs: From cfb3bcb1ff08869f61a8b87f2ee7f9f485e4da51 Mon Sep 17 00:00:00 2001 From: Katherine Bertelsen Date: Fri, 25 Oct 2024 08:36:00 -0500 Subject: [PATCH 3/5] Use old versions --- .test-simulator-device-name | 2 +- .test-simulator-ios-version | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/.test-simulator-device-name b/.test-simulator-device-name index 5b8e0214cc..64a0502071 100644 --- a/.test-simulator-device-name +++ b/.test-simulator-device-name @@ -1 +1 @@ -iPhone 16 Pro +iPhone 15 Pro diff --git a/.test-simulator-ios-version b/.test-simulator-ios-version index 33718932a4..3e17df0287 100644 --- a/.test-simulator-ios-version +++ b/.test-simulator-ios-version @@ -1 +1 @@ -18.1 +17.0.1 From 92db10f9ee8ea553f4db1acf6327ca7baac36df8 Mon Sep 17 00:00:00 2001 From: Katherine Bertelsen Date: Fri, 25 Oct 2024 08:49:13 -0500 Subject: [PATCH 4/5] Use actual iOS version we're using for tests --- .test-simulator-ios-version | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.test-simulator-ios-version b/.test-simulator-ios-version index 3e17df0287..0034b6527f 100644 --- a/.test-simulator-ios-version +++ b/.test-simulator-ios-version @@ -1 +1 @@ -17.0.1 +18.0 From 08efe262d3e2b2726e5e83841add8d69e33b0423 Mon Sep 17 00:00:00 2001 From: Katherine Bertelsen Date: Fri, 25 Oct 2024 12:06:15 -0500 Subject: [PATCH 5/5] Update step name --- .github/workflows/test.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/test.yml b/.github/workflows/test.yml index b4d4028f3c..0aebb0953a 100644 --- a/.github/workflows/test.yml +++ b/.github/workflows/test.yml @@ -69,7 +69,7 @@ jobs: with: ref: ${{ github.event.pull_request.head.sha }} - - name: Read default Xcode version + - name: Read default Xcode version and simulator configuration run: | echo "DEFAULT_XCODE_VERSION=$(cat .xcode-version | tr -d '\n')" >> "$GITHUB_ENV" echo "DEFAULT_SIMULATOR_NAME=$(cat .test-simulator-device-name | tr -d '\n')" >> "$GITHUB_ENV"