-
Notifications
You must be signed in to change notification settings - Fork 46
65 lines (63 loc) · 2.14 KB
/
check_tests.yaml
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
62
63
64
65
name: "✔️ Check Tests"
on:
push:
branches:
- master
jobs:
check-android-tests:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- name: "Set up JDK 17"
id: setup-java
uses: actions/setup-java@v4
with:
distribution: 'temurin'
java-version: '17'
- name: "Enable KVM group perms"
run: |
echo 'KERNEL=="kvm", GROUP="kvm", MODE="0666", OPTIONS+="static_node=kvm"' | sudo tee /etc/udev/rules.d/99-kvm4all.rules
sudo udevadm control --reload-rules
sudo udevadm trigger --name-match=kvm
- name: "Prepare env"
run: |
echo ${{ secrets.GOOGLE_SERVICES }} | base64 -d | zcat >> androidApp/google-services.json
- name: "Setup Gradle"
uses: gradle/actions/setup-gradle@v4
env:
JAVA_HOME: ${{ steps.setup-java.outputs.path }}
- name: "Check and Build licenses"
run: ./gradlew :androidApp:licenseeAndroidPlayStoreRelease
- name: "Move licenses"
run: |
mv -f androidApp/build/reports/licensee/androidPlayStoreRelease/artifacts.json common/src/commonMain/composeResources/files/licenses.json
- name: "Run tests"
id: baseline-profiles
uses: reactivecircus/android-emulator-runner@v2
with:
api-level: 30
arch: x86_64
disable-animations: true
disk-size: 4G
script: |
adb root
./gradlew :androidApp:connectedPlayStoreDebugAndroidTest ; RESULT=$?
mkdir -p artifacts/
adb pull /storage/emulated/0/Movies/ artifactsScreenRecording/ || true
exit $RESULT
- name: 'Upload screen recordings'
uses: actions/upload-artifact@v4
if: always()
with:
name: baselineprofile-screen-recordings
path: |
artifactsScreenRecording/
retention-days: 7
- name: 'Upload logs'
uses: actions/upload-artifact@v4
if: always()
with:
name: baselineprofile-logs
path: |
androidApp/outputs/androidTest-results/
retention-days: 7