pull/1819/merge
Jaehwa Noh 2 days ago committed by GitHub
commit 070ff44be3
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194

@ -213,15 +213,44 @@ jobs:
build-scan-terms-of-use-url: "https://gradle.com/terms-of-service" build-scan-terms-of-use-url: "https://gradle.com/terms-of-service"
build-scan-terms-of-use-agree: "yes" build-scan-terms-of-use-agree: "yes"
- name: AVD cache
uses: actions/cache@v4
id: avd-cache
with:
path: |
~/.android/avd/*
~/.android/adb*
key: avd-${{ matrix.api-level }}
# Take a snapshot if it doesn't have a cache.
- name: create AVD and generate snapshot for caching
if: steps.avd-cache.outputs.cache-hit != 'true'
uses: reactivecircus/android-emulator-runner@v2
with:
api-level: ${{ matrix.api-level }}
avd-name: test-${{ matrix.api-level }}
force-avd-creation: false
arch: x86_64
disk-size: 6000M
heap-size: 600M
emulator-options: -no-window -gpu swiftshader_indirect -noaudio -no-boot-anim -camera-back none
disable-animations: false
script: echo "Generated AVD snapshot for caching."
- name: Build projects and run instrumentation tests - name: Build projects and run instrumentation tests
uses: reactivecircus/android-emulator-runner@v2 uses: reactivecircus/android-emulator-runner@v2
with: with:
api-level: ${{ matrix.api-level }} api-level: ${{ matrix.api-level }}
avd-name: test-${{ matrix.api-level }}
arch: x86_64 arch: x86_64
force-avd-creation: false
disable-animations: true disable-animations: true
disk-size: 6000M disk-size: 6000M
heap-size: 600M heap-size: 600M
script: ./gradlew connectedDemoDebugAndroidTest --daemon # && killall -INT crashpad_handler || true
# came from https://github.com/ReactiveCircus/android-emulator-runner/issues/385#issuecomment-2492035091
script: |
/usr/local/lib/android/sdk/platform-tools/adb -s emulator-5554 shell pm list packages -u | grep com.google.samples.apps.nowinandroid* | cut -d':' -f2 | tr '\r' ' ' | xargs -r -n1 -t adb uninstall; ./gradlew connectedDemoDebugAndroidTest --daemon && killall -INT crashpad_handler || true
- name: Run local tests (including Roborazzi) for the combined coverage report (only API 30) - name: Run local tests (including Roborazzi) for the combined coverage report (only API 30)
if: matrix.api-level == 30 if: matrix.api-level == 30

Loading…
Cancel
Save