@@ -18,68 +18,44 @@ jobs:
18
18
build :
19
19
runs-on : ubuntu-latest
20
20
timeout-minutes : 30
21
-
22
- steps :
23
- - name : Checkout
24
- uses : actions/checkout@v2
25
-
26
- - name : Copy CI gradle.properties
27
- run : mkdir -p ~/.gradle ; cp .github/ci-gradle.properties ~/.gradle/gradle.properties
28
-
29
- - name : Set up JDK 11
30
- uses : actions/setup-java@v1
31
- with :
32
- java-version : 11
33
-
34
- - uses : actions/cache@v2
35
- with :
36
- path : |
37
- ~/.gradle/caches/modules-*
38
- ~/.gradle/caches/jars-*
39
- ~/.gradle/caches/build-cache-*
40
- key : gradle-${{ hashFiles('checksum.txt') }}
41
-
42
- - name : Build project
43
- run : ./gradlew build test --stacktrace
44
-
45
- - name : Upload build reports
46
- if : always()
47
- uses : actions/upload-artifact@v2
48
- with :
49
- name : build-reports
50
- path : app/build/reports/
51
-
52
- test :
53
- needs : build
54
- runs-on : macOS-latest # enables hardware acceleration in the virtual machine
55
- timeout-minutes : 30
56
21
strategy :
57
22
matrix :
58
- api-level : [23, 29]
23
+ api-level : [29]
59
24
60
25
steps :
61
- - name : Checkout
62
- uses : actions/checkout@v2
63
-
64
- - name : Copy CI gradle.properties
65
- run : mkdir -p ~/.gradle ; cp .github/ci-gradle.properties ~/.gradle/gradle.properties
66
-
67
- - name : Set up JDK 11
68
- uses : actions/setup-java@v1
26
+ - uses : actions/checkout@v4
27
+
28
+ - name : Enable KVM group perms
29
+ run : |
30
+ echo 'KERNEL=="kvm", GROUP="kvm", MODE="0666", OPTIONS+="static_node=kvm"' | sudo tee /etc/udev/rules.d/99-kvm4all.rules
31
+ sudo udevadm control --reload-rules
32
+ sudo udevadm trigger --name-match=kvm
33
+ ls /dev/kvm
34
+
35
+ - name : Set Up JDK
36
+ uses : actions/setup-java@v4
69
37
with :
70
- java-version : 11
71
-
38
+ distribution : ' zulu' # See 'Supported distributions' for available options
39
+ java-version : ' 17'
40
+ cache : ' gradle'
41
+
42
+ - name : Setup Gradle
43
+ uses : gradle/actions/setup-gradle@v4
44
+
45
+ - name : Setup Android SDK
46
+ uses : android-actions/setup-android@v3
47
+
72
48
- name : Run instrumentation tests
73
49
uses : reactivecircus/android-emulator-runner@v2
74
50
with :
75
51
api-level : ${{ matrix.api-level }}
76
52
arch : x86
77
53
disable-animations : true
78
- script : ./gradlew app:cC --stacktrace
54
+ script : ./gradlew connectedCheck --stacktrace
79
55
80
56
- name : Upload test reports
81
57
if : always()
82
- uses : actions/upload-artifact@v2
58
+ uses : actions/upload-artifact@v4
83
59
with :
84
- name : test-reports
85
- path : app/build/reports/
60
+ name : test-reports-${{ matrix.api-level }}
61
+ path : ./ app/build/reports/androidTests
0 commit comments