-
Notifications
You must be signed in to change notification settings - Fork 83
61 lines (55 loc) · 1.65 KB
/
instumented_tests.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
name: Instrumented tests
on:
push:
branches:
- release/**
paths-ignore:
- '**.md'
- app/**
pull_request:
branches:
- release/**
paths-ignore:
- '**.md'
- app/**
jobs:
instrumented_tests:
runs-on: macos-latest
strategy:
fail-fast: false
matrix:
test_config: [
{ api_level: 21, target: "default", description: "21_default" },
{ api_level: 30, target: "default", description: "30_default" },
{ api_level: 32, target: "google_apis", description: "32_google_apis" }
]
steps:
- name: checkout
uses: actions/checkout@v3
- name: Set up Java env
uses: actions/setup-java@v3
with:
distribution: 'temurin'
java-version: '17'
- name: Instrumented tests
id: instrumented_tests
uses: reactivecircus/android-emulator-runner@v2
with:
api-level: ${{ matrix.test_config.api_level }}
target: ${{ matrix.test_config.target }}
arch: x86_64
profile: Nexus 6
script: |
adb logcat -c
touch emulator.log
chmod 777 emulator.log
adb logcat >> emulator.log &
./gradlew :fingerprint:connectedCheck -PCItest="true"
- name: Save report if tests failed
if: always() && (steps.instrumented_tests.outcome == 'failure')
uses: actions/upload-artifact@v2
with:
name: ${{ format('test_failed_report_{0}', matrix.test_config.description) }}
path: |
fingerprint/build/reports/androidTests/connected/
emulator.log