38 lines
867 B
YAML
38 lines
867 B
YAML
name: Android Test CI
|
|
|
|
on:
|
|
push:
|
|
branches: [ feature/git-actions ]
|
|
pull_request:
|
|
branches: [ feature/git-actions ]
|
|
|
|
jobs:
|
|
build:
|
|
|
|
runs-on: [ self-hosted ]
|
|
|
|
steps:
|
|
- name: Checkout
|
|
uses: actions/checkout@v2
|
|
- name: set up JDK 11
|
|
uses: actions/setup-java@v2
|
|
with:
|
|
java-version: '11'
|
|
distribution: 'adopt'
|
|
- name: Setup Android SDK
|
|
uses: android-actions/setup-android@v2
|
|
|
|
- uses: actions/cache@v2
|
|
with:
|
|
path: |
|
|
~/.gradle/caches
|
|
~/.gradle/wrapper
|
|
key: ${{ runner.os }}-gradle-${{ hashFiles('**/*.gradle*', '**/gradle-wrapper.properties') }}
|
|
restore-keys: |
|
|
${{ runner.os }}-gradle-
|
|
|
|
- name: Grant execute permission for gradlew
|
|
run: chmod +x gradlew
|
|
- name: Unit Test
|
|
run: ./gradlew testDebugUnitTest
|