Skip to content

Bump CI emulator version to Android 14 #332

Bump CI emulator version to Android 14

Bump CI emulator version to Android 14 #332

Workflow file for this run

name: Unit Test
on:
pull_request:
workflow_dispatch:
jobs:
unit-tests:
timeout-minutes: 5
runs-on: ubuntu-latest
steps:
- name: Checkout code
uses: actions/checkout@v4
- name: Setup Java
uses: actions/setup-java@v4
with:
distribution: 'corretto'
java-version: '17'
- name: Detect gradle version
uses: actions/github-script@v7
id: gradle-version-detector
with:
result-encoding: string
script: |
const scriptPath = '/./.github/scripts/gradle-version-detector.js'
const script = require(`${process.env.GITHUB_WORKSPACE}${scriptPath}`)
return script()
- name: Fetch gradle cache
uses: actions/cache@v4
with:
path: |
~/.gradle/caches
~/.gradle/wrapper
key: ${{ runner.os }}-${{ steps.gradle-version-detector.outputs.result }}
- name: Copy CI gradle.properties
run: mkdir -p ~/.gradle ; cp .github/ci-gradle.properties ~/.gradle/gradle.properties
- name: Make gradlew executable
run: chmod +x ./gradlew
- name: Run unit tests
run: ./gradlew testDebugUnitTest --continue
- name: Publish Unit Test Results
uses: EnricoMi/publish-unit-test-result-action@v2
if: ${{ github.event_name == 'pull_request' }}
with:
github_token: ${{ secrets.GITHUB_TOKEN }}
check_name: Unit Test Results
junit_files: '**/test-results/**/*.xml'