ci: split android into its own job for graph visibility
The merged test-and-build matrix hid Android behind an OS-keyed matrix leg, so the workflow graph no longer showed a distinct Android node. Restore visibility by splitting into two parallel jobs after lint: - build-desktop (matrix: ubuntu/macos/windows): runs JVM tests for the KMP/JVM modules (quartz, commons, cli, desktopApp) and packages the native installer per OS. - test-and-build-android (ubuntu): runs the full test sweep and assembleBenchmark, uploads APKs and reports. Trade-off: Ubuntu spins up two parallel runners instead of one, but wall time is unchanged and Android is once again a visible node.
This commit is contained in:
+31
-20
@@ -31,7 +31,7 @@ jobs:
|
|||||||
- name: Linter (gradle)
|
- name: Linter (gradle)
|
||||||
run: ./gradlew spotlessCheck
|
run: ./gradlew spotlessCheck
|
||||||
|
|
||||||
test-and-build:
|
build-desktop:
|
||||||
needs: lint
|
needs: lint
|
||||||
strategy:
|
strategy:
|
||||||
fail-fast: false
|
fail-fast: false
|
||||||
@@ -66,22 +66,7 @@ jobs:
|
|||||||
cache: gradle
|
cache: gradle
|
||||||
|
|
||||||
- name: Test + Build Desktop (gradle)
|
- name: Test + Build Desktop (gradle)
|
||||||
run: ./gradlew test :desktopApp:${{ matrix.desktop-task }} --no-daemon
|
run: ./gradlew :quartz:test :commons:test :cli:test :desktopApp:test :desktopApp:${{ matrix.desktop-task }} --no-daemon
|
||||||
|
|
||||||
- name: Build Android Benchmark APKs (gradle)
|
|
||||||
if: matrix.os == 'ubuntu-latest'
|
|
||||||
run: ./gradlew assembleBenchmark --no-daemon
|
|
||||||
|
|
||||||
- name: Android Test Report
|
|
||||||
uses: asadmansr/android-test-report-action@v1.2.0
|
|
||||||
if: ${{ always() && matrix.os == 'ubuntu-latest' }}
|
|
||||||
|
|
||||||
- name: Upload Test Results
|
|
||||||
uses: actions/upload-artifact@v7
|
|
||||||
if: ${{ always() && matrix.os == 'ubuntu-latest' }}
|
|
||||||
with:
|
|
||||||
name: Test Reports
|
|
||||||
path: amethyst/build/reports
|
|
||||||
|
|
||||||
- name: Upload Desktop Distribution
|
- name: Upload Desktop Distribution
|
||||||
uses: actions/upload-artifact@v7
|
uses: actions/upload-artifact@v7
|
||||||
@@ -89,23 +74,49 @@ jobs:
|
|||||||
name: ${{ matrix.desktop-artifact-name }}
|
name: ${{ matrix.desktop-artifact-name }}
|
||||||
path: ${{ matrix.desktop-artifact-path }}
|
path: ${{ matrix.desktop-artifact-path }}
|
||||||
|
|
||||||
|
test-and-build-android:
|
||||||
|
needs: lint
|
||||||
|
runs-on: ubuntu-latest
|
||||||
|
timeout-minutes: 60
|
||||||
|
steps:
|
||||||
|
- name: Checkout code
|
||||||
|
uses: actions/checkout@v6
|
||||||
|
|
||||||
|
- name: Set up JDK 21
|
||||||
|
uses: actions/setup-java@v5
|
||||||
|
with:
|
||||||
|
distribution: 'zulu'
|
||||||
|
java-version: 21
|
||||||
|
cache: gradle
|
||||||
|
|
||||||
|
- name: Test + Build Android (gradle)
|
||||||
|
run: ./gradlew test assembleBenchmark --no-daemon
|
||||||
|
|
||||||
|
- name: Android Test Report
|
||||||
|
uses: asadmansr/android-test-report-action@v1.2.0
|
||||||
|
if: always()
|
||||||
|
|
||||||
|
- name: Upload Test Results
|
||||||
|
uses: actions/upload-artifact@v7
|
||||||
|
if: always()
|
||||||
|
with:
|
||||||
|
name: Test Reports
|
||||||
|
path: amethyst/build/reports
|
||||||
|
|
||||||
- name: Upload Play APK Benchmark
|
- name: Upload Play APK Benchmark
|
||||||
uses: actions/upload-artifact@v7
|
uses: actions/upload-artifact@v7
|
||||||
if: matrix.os == 'ubuntu-latest'
|
|
||||||
with:
|
with:
|
||||||
name: Play Benchmark APK
|
name: Play Benchmark APK
|
||||||
path: amethyst/build/outputs/apk/play/benchmark/amethyst-play-universal-benchmark.apk
|
path: amethyst/build/outputs/apk/play/benchmark/amethyst-play-universal-benchmark.apk
|
||||||
|
|
||||||
- name: Upload FDroid APK Benchmark
|
- name: Upload FDroid APK Benchmark
|
||||||
uses: actions/upload-artifact@v7
|
uses: actions/upload-artifact@v7
|
||||||
if: matrix.os == 'ubuntu-latest'
|
|
||||||
with:
|
with:
|
||||||
name: FDroid Benchmark APK
|
name: FDroid Benchmark APK
|
||||||
path: amethyst/build/outputs/apk/fdroid/benchmark/amethyst-fdroid-universal-benchmark.apk
|
path: amethyst/build/outputs/apk/fdroid/benchmark/amethyst-fdroid-universal-benchmark.apk
|
||||||
|
|
||||||
- name: Upload Compose Reports
|
- name: Upload Compose Reports
|
||||||
uses: actions/upload-artifact@v7
|
uses: actions/upload-artifact@v7
|
||||||
if: matrix.os == 'ubuntu-latest'
|
|
||||||
with:
|
with:
|
||||||
name: Compose Reports
|
name: Compose Reports
|
||||||
path: amethyst/build/compose_compiler
|
path: amethyst/build/compose_compiler
|
||||||
|
|||||||
Reference in New Issue
Block a user