add missing actions (#120) #91
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 AppCenter Tests | |
on: | |
workflow_dispatch: | |
push: | |
branches: [ main ] | |
paths: | |
- 'demo/android/OctopusDemo/**' | |
- '!demo/android/OctopusDemo/README.md' | |
- 'res/audio/**' | |
- '.github/workflows/android-appcenter.yml' | |
pull_request: | |
branches: [ main, 'v[0-9]+.[0-9]+' ] | |
paths: | |
- 'demo/android/OctopusDemo/**' | |
- '!demo/android/OctopusDemo/README.md' | |
- 'res/audio/**' | |
- '.github/workflows/android-appcenter.yml' | |
defaults: | |
run: | |
working-directory: demo/android/OctopusDemo | |
jobs: | |
build: | |
name: Run Android Tests on AppCenter | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v3 | |
- name: Set up Node.js LTS | |
uses: actions/setup-node@v3 | |
with: | |
node-version: lts/* | |
- name: Install AppCenter CLI | |
run: npm install -g appcenter-cli | |
- name: set up JDK 11 | |
uses: actions/setup-java@v3 | |
with: | |
java-version: '11' | |
distribution: 'temurin' | |
- name: Copy test_resources | |
run: ./copy_test_resources.sh | |
- name: Inject AccessKey | |
run: echo pvTestingAccessKey="${{secrets.PV_VALID_ACCESS_KEY}}" >> local.properties | |
- name: Build app | |
run: ./gradlew assembleDebug | |
- name: Build androidTest | |
run: ./gradlew assembleAndroidTest | |
- name: Run tests on AppCenter | |
run: appcenter test run espresso | |
--token ${{secrets.APPCENTERAPITOKEN}} | |
--app "Picovoice/Octopus-Android" | |
--devices "Picovoice/android-min-max" | |
--app-path octopus-demo-app/build/outputs/apk/debug/octopus-demo-app-debug.apk | |
--test-series "octopus-android" | |
--locale "en_US" | |
--build-dir octopus-demo-app/build/outputs/apk/androidTest/debug |