Skip to content

mem backend for tx5 #288

mem backend for tx5

mem backend for tx5 #288

Workflow file for this run

name: Android Test
on:
merge_group:
branches:
- main
push:
branches:
- main
pull_request:
branches:
- main
jobs:
test:
runs-on: ubuntu-latest
strategy:
fail-fast: false
matrix:
#android-arch: ["arm64-v8a", "x86_64"]
android-arch: ["x86_64"]
android-api-level: [29, 33]
android-ndk-version: ["26.0.10792818"]
steps:
- name: Checkout
uses: actions/checkout@v4
- 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: Go Toolchain
uses: actions/setup-go@v5
with:
go-version: '=1.20.0'
- name: Rust Toolchain
run: |
rustup toolchain install stable --profile minimal --no-self-update
#rustup target add aarch64-linux-android
rustup target add x86_64-linux-android
- name: Rust Cache
uses: Swatinem/rust-cache@v2
- name: Avd Cache
uses: actions/cache@v3
id: avd-cache
with:
path: |
~/.android/avd/*
~/.android/adb*
key: avd-${{ matrix.android-api-level }}
- name: Avd Snapshot
if: steps.avd-cache.outputs.cache-hit != 'true'
env:
ANDROID_API_LEVEL: ${{ matrix.android-api-level }}
ANDROID_NDK_VERSION: ${{ matrix.android-ndk-version }}
ANDROID_ARCH: ${{ matrix.android-arch }}
uses: reactivecircus/android-emulator-runner@v2
with:
api-level: ${{ matrix.android-api-level }}
ndk: ${{ matrix.android-ndk-version }}
arch: ${{ matrix.android-arch }}
target: google_apis
force-avd-creation: false
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 and Run Tests
env:
ANDROID_API_LEVEL: ${{ matrix.android-api-level }}
ANDROID_NDK_VERSION: ${{ matrix.android-ndk-version }}
ANDROID_ARCH: ${{ matrix.android-arch }}
uses: reactivecircus/android-emulator-runner@v2
with:
api-level: ${{ matrix.android-api-level }}
ndk: ${{ matrix.android-ndk-version }}
arch: ${{ matrix.android-arch }}
target: google_apis
force-avd-creation: false
emulator-options: -no-snapshot-save -no-window -gpu swiftshader_indirect -noaudio -no-boot-anim -camera-back none
disable-animations: true
script: ./android-build-tests.bash && ./android-run-tests.bash