force ci #43
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| name: avd-cache-warmup | |
| on: | |
| push: | |
| branches: | |
| - master | |
| permissions: | |
| contents: read | |
| jobs: | |
| warmup: | |
| runs-on: ubuntu-latest | |
| name: Warm up AVD cache (API ${{ matrix.api-level }}) | |
| timeout-minutes: 60 | |
| strategy: | |
| fail-fast: false | |
| matrix: | |
| api-level: [ 30, 31, 34 ] | |
| steps: | |
| - name: Checkout | |
| uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # 6.0.2 | |
| with: | |
| persist-credentials: false | |
| - name: Enable KVM | |
| run: | | |
| echo 'KERNEL=="kvm", GROUP="kvm", MODE="0666", OPTIONS+="static_node=kvm"' | sudo tee /etc/udev/rules.d/99-kvm4all.rules | |
| sudo udevadm control --reload-rules | |
| sudo udevadm trigger --name-match=kvm | |
| - name: Setup environment | |
| uses: ./.github/actions/setup-gradle-environment-action | |
| with: | |
| gradle-encryption-key: ${{ secrets.GRADLE_ENCRYPTION_KEY }} | |
| - name: Copy debug.keystore | |
| run: | | |
| mkdir -p /home/runner/.config/.android/ | |
| cp .github/debug.keystore /home/runner/.config/.android/debug.keystore | |
| - name: Accept Android licenses | |
| run: | | |
| yes | $ANDROID_HOME/cmdline-tools/latest/bin/sdkmanager --licenses | |
| - name: Cache AVD | |
| uses: actions/cache@cdf6c1fa76f9f475f3d7449005a359c84ca0f306 # 5.0.3 | |
| with: | |
| path: /home/runner/.config/.android/avd | |
| key: >- | |
| avd-api${{ matrix.api-level }}-aosp-x86_64-${{ hashFiles( | |
| 'build-logic/src/main/kotlin/ru/solrudev/ackpine/gradle/testing/ManagedDevicesConventionPlugin.kt' | |
| ) }} | |
| - name: Set up AVD | |
| run: | | |
| ./gradlew api${{ matrix.api-level }}Setup \ | |
| -Pandroid.testoptions.manageddevices.emulator.gpu=swiftshader_indirect \ | |
| --stacktrace |