ci: don't test API level 27 in CI because it's causing problems too #37
This file contains 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: build | |
on: | |
pull_request: | |
paths-ignore: | |
- "**.md" | |
push: | |
paths-ignore: | |
- "**.md" | |
jobs: | |
build: | |
runs-on: ubuntu-latest | |
steps: | |
- name: Delete unnecessary tools to free up some space | |
uses: jlumbroso/[email protected] | |
with: | |
android: false # Don't remove Android tools | |
large-packages: false # includes google-cloud-sdk and it's slow | |
tool-cache: true | |
dotnet: true | |
haskell: true | |
swap-storage: true | |
docker-images: true | |
- name: Checkout the code | |
uses: actions/checkout@v4 | |
- name: Validate Gradle wrapper | |
uses: gradle/wrapper-validation-action@v2 | |
- uses: actions/setup-java@v4 | |
with: | |
distribution: "temurin" | |
java-version: "17" | |
- name: Setup Gradle | |
uses: gradle/actions/setup-gradle@v3 | |
- name: Enable KVM group perms | |
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: Accept Android licenses | |
run: yes | "$ANDROID_HOME"/cmdline-tools/latest/bin/sdkmanager --licenses || true | |
# NOTE: Limiting to one gradle worker because otherwise it was trying to install the Android Emulator multiple times | |
# simultaneously, causing FileAlreadyExistsExceptions. | |
- name: Run instrumented tests on a subset of supported devices | |
run: | | |
./gradlew someDevicesGroupdebugAndroidTest \ | |
-Dorg.gradle.workers.max=1 \ | |
-Pandroid.testoptions.manageddevices.emulator.gpu=swiftshader_indirect \ | |
--info | |
- name: Build the app | |
run: ./gradlew build | |
- uses: actions/upload-artifact@v4 | |
with: | |
name: apk | |
path: app/build/outputs/apk/debug/app-debug.apk |