pedigree root-root is just root #137
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: Test GitHub Runners | |
on: push | |
jobs: | |
build-and-test: | |
name: Kotlin Multiplatform Project Build | |
runs-on: ubuntu-latest | |
steps: | |
- name: Checkout code | |
uses: actions/checkout@v4 | |
- name: Set up JDK | |
uses: actions/setup-java@v4 | |
with: | |
distribution: 'adopt' | |
java-version: '21' | |
- name: Build Project | |
run: ./gradlew assemble | |
- name: Setup Xvfb on screen 0 | |
run: Xvfb :1 -screen 0 1024x768x24 & | |
- name: Run Desktop Tests | |
run: ./gradlew composeApp:desktopTest | |
env: | |
DISPLAY: :1 | |
- name: Run Android Unit Tests | |
run: ./gradlew composeApp:testDebugUnitTest | |
env: | |
DISPLAY: :1 | |
- 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: Run Android Emulator Tests | |
uses: reactivecircus/android-emulator-runner@v2 | |
with: | |
api-level: 30 | |
script: ./gradlew connectedAndroidTest | |
arch: x86_64 | |
- name: Shutdown Xvfb | |
run: killall Xvfb | |
- name: Create Test Summary | |
uses: test-summary/action@v2 | |
with: | |
paths: '**/*est-results/**/*.xml' | |
show: "pass, fail, skip" | |
- name: Upload Test Results | |
if: always() | |
uses: actions/upload-artifact@v4 | |
with: | |
name: desktop-test-report | |
path: composeApp/build/reports/tests/desktopTest |