Add GitHub workflow to run tests on pushes to main
This commit is contained in:
parent
ed57785d0a
commit
e75e0a07d1
1 changed files with 32 additions and 0 deletions
32
.github/workflows/android.yml
vendored
Normal file
32
.github/workflows/android.yml
vendored
Normal file
|
@ -0,0 +1,32 @@
|
||||||
|
name: Android CI
|
||||||
|
|
||||||
|
on:
|
||||||
|
push:
|
||||||
|
branches: [ main ]
|
||||||
|
|
||||||
|
jobs:
|
||||||
|
build:
|
||||||
|
|
||||||
|
runs-on: ubuntu-latest
|
||||||
|
|
||||||
|
steps:
|
||||||
|
- uses: actions/checkout@v2
|
||||||
|
- name: set up JDK 1.8
|
||||||
|
uses: actions/setup-java@v1
|
||||||
|
with:
|
||||||
|
java-version: 1.8
|
||||||
|
- name: Grant execute permission for gradlew
|
||||||
|
run: chmod +x gradlew
|
||||||
|
- name: Build with Gradle
|
||||||
|
run: ./gradlew assemblePlayDebug assemblePlayDebugAndroidTest assemblePlayDebugUnitTest
|
||||||
|
- name: Run unit tests
|
||||||
|
run: ./gradlew testPlayDebugUnitTest
|
||||||
|
- name: Add auth for flank
|
||||||
|
env:
|
||||||
|
GCLOUD_KEY: ${{ secrets.GCLOUD_KEY }}
|
||||||
|
GCLOUD_DIR: "$HOME/.config/gcloud/"
|
||||||
|
run: |
|
||||||
|
mkdir -p "$GCLOUD_DIR"
|
||||||
|
echo "$GCLOUD_KEY" | base64 --decode > "$GCLOUD_DIR/application_default_credentials.json"
|
||||||
|
- name: Run UI tests
|
||||||
|
run: ./gradlew runFlank
|
Loading…
Reference in a new issue