From 256923453d2606ed39a72c28ebf16e12b7ec8014 Mon Sep 17 00:00:00 2001 From: Denis Andrasec Date: Tue, 5 Sep 2023 10:57:44 +0200 Subject: [PATCH 1/5] Use iOS 16.4 simulator to run native tests --- .github/workflows/flutter_test.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/flutter_test.yml b/.github/workflows/flutter_test.yml index 375db90f57..5beddb26a9 100644 --- a/.github/workflows/flutter_test.yml +++ b/.github/workflows/flutter_test.yml @@ -134,7 +134,7 @@ jobs: - name: launch ios simulator id: sim run: | - simulator_id=$(xcrun simctl create sentryPhone com.apple.CoreSimulator.SimDeviceType.iPhone-14 com.apple.CoreSimulator.SimRuntime.iOS-16-2) + simulator_id=$(xcrun simctl create sentryPhone com.apple.CoreSimulator.SimDeviceType.iPhone-14 com.apple.CoreSimulator.SimRuntime.iOS-16-4) echo "SIMULATOR_ID=${simulator_id}" >> "$GITHUB_OUTPUT" xcrun simctl boot ${simulator_id} # Disable flutter integration tests because of flaky execution From 530a18527682afd05df5d98dc84bb68ac5878147 Mon Sep 17 00:00:00 2001 From: Denis Andrasec Date: Tue, 5 Sep 2023 11:32:33 +0200 Subject: [PATCH 2/5] Update andorid emulator params --- .github/workflows/flutter_test.yml | 27 +++++++++++++++------------ 1 file changed, 15 insertions(+), 12 deletions(-) diff --git a/.github/workflows/flutter_test.yml b/.github/workflows/flutter_test.yml index 5beddb26a9..517172705b 100644 --- a/.github/workflows/flutter_test.yml +++ b/.github/workflows/flutter_test.yml @@ -66,12 +66,13 @@ jobs: uses: reactivecircus/android-emulator-runner@d94c3fbe4fe6a29e4a5ba47c12fb47677c73656b #pin@v2.28.0 with: working-directory: ./flutter/example - api-level: 21 - force-avd-creation: false - emulator-options: -no-window -gpu swiftshader_indirect -noaudio -no-boot-anim -camera-back none - disable-animations: false - arch: x86_64 + api-level: 31 profile: Nexus 6 + arch: arm64-v8a + force-avd-creation: false + avd-name: macOS-avd-arm64-v8a-31 + emulator-options: -no-snapshot-save -no-window -gpu swiftshader_indirect -noaudio -no-boot-anim -camera-back none + disable-animations: true script: echo 'Generated AVD snapshot for caching.' - name: build apk @@ -81,25 +82,27 @@ jobs: - name: launch android emulator & run android native test uses: reactivecircus/android-emulator-runner@d94c3fbe4fe6a29e4a5ba47c12fb47677c73656b #pin@v2.28.0 with: - working-directory: ./flutter/example/android - api-level: 21 + working-directory: ./flutter/example + api-level: 31 + profile: Nexus 6 + arch: arm64-v8a force-avd-creation: false + avd-name: macOS-avd-arm64-v8a-31 emulator-options: -no-snapshot-save -no-window -gpu swiftshader_indirect -noaudio -no-boot-anim -camera-back none disable-animations: true - arch: x86_64 - profile: Nexus 6 script: ./gradlew testDebugUnitTest - name: launch android emulator & run android integration test uses: reactivecircus/android-emulator-runner@d94c3fbe4fe6a29e4a5ba47c12fb47677c73656b #pin@v2.28.0 with: working-directory: ./flutter/example - api-level: 21 + api-level: 31 + profile: Nexus 6 + arch: arm64-v8a force-avd-creation: false + avd-name: macOS-avd-arm64-v8a-31 emulator-options: -no-snapshot-save -no-window -gpu swiftshader_indirect -noaudio -no-boot-anim -camera-back none disable-animations: true - arch: x86_64 - profile: Nexus 6 script: flutter test integration_test/integration_test.dart --verbose test-ios: From 4c175e62077d1f8a2c52c5370a7d631bf1ede672 Mon Sep 17 00:00:00 2001 From: Denis Andrasec Date: Tue, 5 Sep 2023 11:39:13 +0200 Subject: [PATCH 3/5] change key --- .github/workflows/flutter_test.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/flutter_test.yml b/.github/workflows/flutter_test.yml index 517172705b..ad69a8fca4 100644 --- a/.github/workflows/flutter_test.yml +++ b/.github/workflows/flutter_test.yml @@ -59,7 +59,7 @@ jobs: path: | ~/.android/avd/* ~/.android/adb* - key: avd-21 + key: avd-31 - name: create AVD and generate snapshot for caching if: steps.avd-cache.outputs.cache-hit != 'true' From 4b7e80ba3a7d3680f2c1ddb2b54863c5c800c036 Mon Sep 17 00:00:00 2001 From: Denis Andrasec Date: Tue, 5 Sep 2023 11:48:13 +0200 Subject: [PATCH 4/5] Run on arch x86_64 --- .github/workflows/flutter_test.yml | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/.github/workflows/flutter_test.yml b/.github/workflows/flutter_test.yml index ad69a8fca4..b3607591c9 100644 --- a/.github/workflows/flutter_test.yml +++ b/.github/workflows/flutter_test.yml @@ -68,9 +68,9 @@ jobs: working-directory: ./flutter/example api-level: 31 profile: Nexus 6 - arch: arm64-v8a + arch: x86_64 force-avd-creation: false - avd-name: macOS-avd-arm64-v8a-31 + avd-name: macOS-avd-x86_64-31 emulator-options: -no-snapshot-save -no-window -gpu swiftshader_indirect -noaudio -no-boot-anim -camera-back none disable-animations: true script: echo 'Generated AVD snapshot for caching.' @@ -85,9 +85,9 @@ jobs: working-directory: ./flutter/example api-level: 31 profile: Nexus 6 - arch: arm64-v8a + arch: x86_64 force-avd-creation: false - avd-name: macOS-avd-arm64-v8a-31 + avd-name: macOS-avd-x86_64-31 emulator-options: -no-snapshot-save -no-window -gpu swiftshader_indirect -noaudio -no-boot-anim -camera-back none disable-animations: true script: ./gradlew testDebugUnitTest @@ -98,9 +98,9 @@ jobs: working-directory: ./flutter/example api-level: 31 profile: Nexus 6 - arch: arm64-v8a + arch: x86_64 force-avd-creation: false - avd-name: macOS-avd-arm64-v8a-31 + avd-name: macOS-avd-x86_64-31 emulator-options: -no-snapshot-save -no-window -gpu swiftshader_indirect -noaudio -no-boot-anim -camera-back none disable-animations: true script: flutter test integration_test/integration_test.dart --verbose From 1d825ed75351d8379c6108d330a29f56e1fb8e7f Mon Sep 17 00:00:00 2001 From: Denis Andrasec Date: Tue, 5 Sep 2023 13:00:11 +0200 Subject: [PATCH 5/5] fix working dir --- .github/workflows/flutter_test.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/flutter_test.yml b/.github/workflows/flutter_test.yml index b3607591c9..15305acb7d 100644 --- a/.github/workflows/flutter_test.yml +++ b/.github/workflows/flutter_test.yml @@ -82,7 +82,7 @@ jobs: - name: launch android emulator & run android native test uses: reactivecircus/android-emulator-runner@d94c3fbe4fe6a29e4a5ba47c12fb47677c73656b #pin@v2.28.0 with: - working-directory: ./flutter/example + working-directory: ./flutter/example/android api-level: 31 profile: Nexus 6 arch: x86_64