Skip to content

Commit 7f87991

Browse files
authored
Merge pull request #4602 from owncloud/technical/integration_of_instrumented_tests
[TECHNICAL] Integrate instrumented tests into GitHub Actions
2 parents 747e9e0 + 41360be commit 7f87991

File tree

4 files changed

+62
-3
lines changed

4 files changed

+62
-3
lines changed
Lines changed: 41 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,41 @@
1+
name: Android Instrumented Data Tests
2+
3+
permissions:
4+
contents: read
5+
6+
on:
7+
pull_request:
8+
9+
jobs:
10+
instrumented-tests:
11+
name: Run Android Instrumented Data Tests
12+
runs-on: ubuntu-latest
13+
14+
steps:
15+
- name: Checkout
16+
uses: actions/checkout@v4
17+
18+
- name: Set up JDK 17
19+
uses: actions/setup-java@v4
20+
with:
21+
java-version: '17'
22+
distribution: 'temurin'
23+
24+
- name: Enable KVM
25+
run: |
26+
echo 'KERNEL=="kvm", GROUP="kvm", MODE="0666", OPTIONS+="static_node=kvm"' | sudo tee /etc/udev/rules.d/99-kvm4all.rules
27+
sudo udevadm control --reload-rules
28+
sudo udevadm trigger --name-match=kvm
29+
30+
- name: Run Instrumented Data Tests with emulator
31+
uses: reactivecircus/android-emulator-runner@v2
32+
with:
33+
api-level: 33
34+
target: google_apis
35+
arch: x86_64
36+
profile: pixel
37+
avd-name: instrumented-tests-avd
38+
force-avd-creation: true
39+
disable-animations: true
40+
emulator-options: -no-window -no-audio -no-boot-anim -accel auto -memory 2048
41+
script: ./gradlew :ownCloudData:connectedAndroidTest

.github/workflows/android-unit-tests.yml

Lines changed: 5 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,12 +1,14 @@
11
name: Android Unit Tests
22

3+
permissions:
4+
contents: read
5+
36
on:
47
pull_request:
5-
branches:
6-
- "*"
78

89
jobs:
9-
unit_tests:
10+
unit-tests:
11+
name: Run Android Unit Tests
1012
runs-on: ubuntu-latest
1113

1214
steps:

CHANGELOG.md

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -52,6 +52,7 @@ ownCloud admins and users.
5252
* Enhancement - Shares space in Android native file explorer: [#4515](https://github.com/owncloud/android/issues/4515)
5353
* Enhancement - Accessibility reports in 4.5.1: [#4568](https://github.com/owncloud/android/issues/4568)
5454
* Enhancement - Support for Kiteworks servers without client secret: [#4588](https://github.com/owncloud/android/issues/4588)
55+
* Enhancement - Integration of instrumented tests in GitHub Actions: [#4595](https://github.com/owncloud/android/issues/4595)
5556
* Enhancement - SBOM (Software Bill of Materials): [#4598](https://github.com/owncloud/android/issues/4598)
5657

5758
## Details
@@ -187,6 +188,14 @@ ownCloud admins and users.
187188
https://github.com/owncloud/android/issues/4588
188189
https://github.com/owncloud/android/pull/4589
189190

191+
* Enhancement - Integration of instrumented tests in GitHub Actions: [#4595](https://github.com/owncloud/android/issues/4595)
192+
193+
A new workflow has been added to run instrumented tests in GitHub Actions in
194+
order to have a more consistent CI pipeline in the project.
195+
196+
https://github.com/owncloud/android/issues/4595
197+
https://github.com/owncloud/android/pull/4602
198+
190199
* Enhancement - SBOM (Software Bill of Materials): [#4598](https://github.com/owncloud/android/issues/4598)
191200

192201
SBOM to be generated in every PR via GitHub Actions with the list of all

changelog/unreleased/4602

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,7 @@
1+
Enhancement: Integration of instrumented tests in GitHub Actions
2+
3+
A new workflow has been added to run instrumented tests in GitHub Actions
4+
in order to have a more consistent CI pipeline in the project.
5+
6+
https://github.com/owncloud/android/issues/4595
7+
https://github.com/owncloud/android/pull/4602

0 commit comments

Comments
 (0)