Bump com.android.tools.build:gradle from 7.4.2 to 8.3.1 #471
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: "Android CI" | |
on: | |
pull_request: | |
push: | |
branches: | |
- master | |
jobs: | |
build: | |
name: Build & Run Unit Tests | |
runs-on: ubuntu-latest | |
steps: | |
- name: Fetch Source | |
uses: actions/checkout@v4 | |
- name: Setup Java | |
uses: actions/[email protected] | |
with: | |
java-version: 11 | |
distribution: 'adopt' | |
- name: Build & Test | |
run: ./gradlew build test | |
instrumentation-tests: | |
name: Instrumentation Tests | |
runs-on: macos-latest | |
timeout-minutes: 30 | |
strategy: | |
# Allow tests to continue on other devices if they fail on one device. | |
fail-fast: false | |
matrix: | |
api-level: | |
- 33 | |
steps: | |
- name: Fetch Source | |
uses: actions/checkout@v4 | |
- name: Set up JDK | |
uses: actions/[email protected] | |
with: | |
java-version: 11 | |
distribution: 'adopt' | |
- name: Instrumentation Tests | |
uses: reactivecircus/android-emulator-runner@v2 | |
with: | |
api-level: ${{ matrix.api-level }} | |
target: google_apis | |
arch: x86_64 | |
script: adb logcat *:S TestRunner:V & ./gradlew connectedCheck --no-build-cache --no-daemon --stacktrace | |
instrumentation-test-summary: | |
if: ${{ always() }} | |
runs-on: ubuntu-latest | |
name: Instrumentation Test Matrix Summary | |
needs: instrumentation-tests | |
steps: | |
- name: Check build matrix status | |
if: ${{ needs.instrumentation-tests.result != 'success' }} | |
run: exit 1 | |
publish-snapshot: | |
name: Publish OSS Sonatype Snapshot | |
runs-on: ubuntu-latest | |
if: "github.event_name == 'push'" | |
needs: | |
- build | |
- instrumentation-test-summary | |
steps: | |
- name: Checkout | |
uses: actions/checkout@v4 | |
- name: Configure JDK | |
uses: actions/[email protected] | |
with: | |
java-version: 11 | |
distribution: 'adopt' | |
- name: Upload Snapshot | |
run: ./gradlew publish | |
env: | |
ORG_GRADLE_PROJECT_signingKeyId: ${{ secrets.SIGNING_KEY_ID }} | |
ORG_GRADLE_PROJECT_signingKey: ${{ secrets.SIGNING_KEY }} | |
ORG_GRADLE_PROJECT_signingPassword: ${{ secrets.SIGNING_PASSWORD }} | |
OSSRH_USERNAME: ${{ secrets.OSSRH_USERNAME }} | |
OSSRH_PASSWORD: ${{ secrets.OSSRH_PASSWORD }} |