Skip to content

Commit 41f6558

Browse files
authored
ci: move Android build to Ubuntu and use FlyCI for iOS (#10492)
1 parent 4b36334 commit 41f6558

File tree

2 files changed

+68
-26
lines changed

2 files changed

+68
-26
lines changed
Lines changed: 60 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,60 @@
1+
name: 'apps/automated/android'
2+
3+
on:
4+
push:
5+
branches:
6+
- main
7+
- 'ci/**'
8+
pull_request:
9+
workflow_dispatch:
10+
11+
concurrency:
12+
group: ${{ github.workflow }}-${{ github.event.pull_request.number || github.ref }}
13+
cancel-in-progress: true
14+
15+
jobs:
16+
test-android:
17+
runs-on: ubuntu-latest
18+
19+
steps:
20+
- uses: actions/checkout@v4
21+
22+
- uses: actions/setup-node@v4
23+
with:
24+
node-version: 20.10.0
25+
26+
- uses: actions/setup-java@v4
27+
with:
28+
distribution: 'temurin'
29+
java-version: '17'
30+
31+
- name: Install Python
32+
uses: actions/setup-python@v5
33+
with:
34+
python-version: '3'
35+
36+
- name: Install NativeScript
37+
run: |
38+
python3 -m pip install --upgrade pip six
39+
npm i -g nativescript --ignore-scripts --legacy-peer-deps
40+
ns usage-reporting disable
41+
ns error-reporting disable
42+
43+
- name: Setup
44+
run: npm run setup
45+
46+
- name: Unit Tests
47+
run: npx nx run-many --target=test --configuration=ci --projects=core
48+
49+
- name: Enable KVM group perms
50+
run: |
51+
echo 'KERNEL=="kvm", GROUP="kvm", MODE="0666", OPTIONS+="static_node=kvm"' | sudo tee /etc/udev/rules.d/99-kvm4all.rules
52+
sudo udevadm control --reload-rules
53+
sudo udevadm trigger --name-match=kvm
54+
55+
- name: Run tests on Android Emulator
56+
uses: reactivecircus/android-emulator-runner@v2
57+
with:
58+
api-level: 34
59+
arch: x86_64
60+
script: node tools/scripts/run-automated.js android
Lines changed: 8 additions & 26 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
name: 'apps/automated'
1+
name: 'apps/automated/ios'
22

33
on:
44
push:
@@ -13,25 +13,20 @@ concurrency:
1313
cancel-in-progress: true
1414

1515
jobs:
16-
test:
17-
runs-on: macos-12
16+
test-ios:
17+
runs-on: flyci-macos-14-m2
1818

1919
steps:
20-
- uses: actions/checkout@v3
20+
- uses: actions/checkout@v4
2121

22-
- uses: actions/setup-node@v3
22+
- uses: actions/setup-node@v4
2323
with:
2424
node-version: 20.10.0
2525

26-
- uses: actions/setup-java@v3
27-
with:
28-
distribution: 'temurin'
29-
java-version: '17'
30-
3126
- name: Install Python
3227
uses: actions/setup-python@v4
3328
with:
34-
python-version: '3'
29+
python-version: '3'
3530

3631
- name: Install NativeScript
3732
run: |
@@ -47,21 +42,8 @@ jobs:
4742
- name: Unit Tests
4843
run: npx nx run-many --target=test --configuration=ci --projects=core
4944

50-
- name: Create Emulator
51-
uses: rigor789/action-create-emulator@main
52-
with:
53-
package: system-images;android-34;default;x86_64
54-
55-
- name: Test (Android)
56-
run: node tools/scripts/run-automated.js android
57-
5845
- name: Start iOS Simulator
59-
if: ${{ always() && !cancelled() }} # run iOS tests even if Android tests failed
60-
uses: futureware-tech/simulator-action@v2
61-
with:
62-
model: 'iPhone 13 Pro Max'
63-
os_version: '>=15.0'
46+
uses: futureware-tech/simulator-action@v3
6447

65-
- name: Test (iOS)
66-
if: ${{ always() && !cancelled() }} # run iOS tests even if Android tests failed
48+
- name: Run tests on iOS Simulator
6749
run: node tools/scripts/run-automated.js ios

0 commit comments

Comments
 (0)