From 4224fc42de44bb76c247b7a9cb940a79b62f2523 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?R=C3=BAben=20Sousa?= Date: Wed, 18 Sep 2024 01:03:41 +0200 Subject: [PATCH 1/2] Align PR config --- .github/workflows/pr.yml | 6 +++++- .github/workflows/push.yml | 13 ++++++++++++- 2 files changed, 17 insertions(+), 2 deletions(-) diff --git a/.github/workflows/pr.yml b/.github/workflows/pr.yml index 2fa0ebb3..27705936 100644 --- a/.github/workflows/pr.yml +++ b/.github/workflows/pr.yml @@ -43,7 +43,7 @@ jobs: strategy: fail-fast: false matrix: - arch: [x86_64] + arch: [x86_64, x86] target: [ google_apis, android-tv ] api-level: [34] profile: [pixel_6, tv_1080p] @@ -52,6 +52,10 @@ jobs: profile: tv_1080p - target: android-tv profile: pixel_6 + - arch: x86 + profile: pixel_6 + - arch: x86_64 + profile: tv_1080p steps: - name: checkout uses: actions/checkout@v4 diff --git a/.github/workflows/push.yml b/.github/workflows/push.yml index adfbf04e..e9415685 100644 --- a/.github/workflows/push.yml +++ b/.github/workflows/push.yml @@ -55,7 +55,18 @@ jobs: - name: Setup Gradle uses: gradle/actions/setup-gradle@v4 + # Retrieve the cached emulator snapshot. + - name: AVD cache + uses: actions/cache@v4 + id: avd-cache + with: + path: | + ~/.android/avd/* + ~/.android/adb* + key: avd-${{ matrix.api-level }}-${{ matrix.profile }} + - name: Create AVD snapshot + if: steps.avd-cache.outputs.cache-hit != 'true' uses: reactivecircus/android-emulator-runner@v2 with: api-level: ${{ matrix.api-level }} @@ -63,7 +74,7 @@ jobs: arch: ${{ matrix.arch }} profile: ${{ matrix.profile }} disable-animations: false - force-avd-creation: true + force-avd-creation: false ram-size: 4096M emulator-options: -no-window -gpu swiftshader_indirect -noaudio -no-boot-anim -camera-back none script: echo "Generated AVD snapshot." From 6e4c5897ffd71d22beb4edc84b3a4b4dfe3721a7 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?R=C3=BAben=20Sousa?= Date: Wed, 18 Sep 2024 01:27:48 +0200 Subject: [PATCH 2/2] Add free disk space --- .github/workflows/pr.yml | 6 ++++-- .github/workflows/push.yml | 5 +++++ 2 files changed, 9 insertions(+), 2 deletions(-) diff --git a/.github/workflows/pr.yml b/.github/workflows/pr.yml index 27705936..39a67964 100644 --- a/.github/workflows/pr.yml +++ b/.github/workflows/pr.yml @@ -76,8 +76,10 @@ jobs: - name: Setup Gradle uses: gradle/actions/setup-gradle@v4 - - name: Compile instrumented tests - run: ./gradlew --build-cache assembleDebugAndroidTest + - name: Free Disk Space (Ubuntu) + uses: jlumbroso/free-disk-space@main + with: + android: false # Retrieve the cached emulator snapshot. - name: AVD cache diff --git a/.github/workflows/push.yml b/.github/workflows/push.yml index e9415685..b9dc8e9d 100644 --- a/.github/workflows/push.yml +++ b/.github/workflows/push.yml @@ -55,6 +55,11 @@ jobs: - name: Setup Gradle uses: gradle/actions/setup-gradle@v4 + - name: Free Disk Space (Ubuntu) + uses: jlumbroso/free-disk-space@main + with: + android: false + # Retrieve the cached emulator snapshot. - name: AVD cache uses: actions/cache@v4