Skip to content

Commit 4e64cdd

Browse files
Merge branch 'main' into expo
2 parents e9e2c8c + 6522812 commit 4e64cdd

File tree

5 files changed

+116
-44
lines changed

5 files changed

+116
-44
lines changed

.github/dependabot.yml

+26-15
Original file line numberDiff line numberDiff line change
@@ -1,18 +1,29 @@
11
version: 2
22
updates:
3-
- package-ecosystem: npm
4-
directory: "/"
5-
schedule:
6-
interval: weekly
7-
open-pull-requests-limit: 2
8-
ignore:
9-
- dependency-name: "@sentry*"
10-
- package-ecosystem: gradle
11-
directory: "/android"
12-
schedule:
13-
interval: weekly
14-
open-pull-requests-limit: 2
15-
- package-ecosystem: "github-actions"
16-
directory: "/"
17-
schedule:
3+
- package-ecosystem: npm
4+
directory: '/'
5+
schedule:
6+
interval: weekly
7+
open-pull-requests-limit: 0 # security updates only
8+
groups:
9+
# The name of the group, it will be used in PR titles and branch
10+
babel-dependencies:
11+
patterns:
12+
- '@babel/*'
13+
react-native-deps:
14+
patterns:
15+
- '@react-native/*'
16+
typescript-eslint-deps:
17+
patterns:
18+
- '@typescript-eslint/*'
19+
ignore:
20+
- dependency-name: '@sentry*'
21+
- package-ecosystem: gradle
22+
directory: '/android'
23+
schedule:
24+
interval: weekly
25+
open-pull-requests-limit: 2
26+
- package-ecosystem: 'github-actions'
27+
directory: '/'
28+
schedule:
1829
interval: weekly

.github/workflows/codegen.yml

+2
Original file line numberDiff line numberDiff line change
@@ -33,6 +33,8 @@ jobs:
3333
with:
3434
java-version: '17'
3535
distribution: "adopt"
36+
- name: Gradle cache
37+
uses: gradle/gradle-build-action@v2
3638
- uses: actions/cache@v3
3739
id: cache
3840
with:

.github/workflows/e2e.yml

+52-11
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,7 @@ jobs:
2222
access_token: ${{ github.token }}
2323

2424
metrics:
25-
runs-on: macos-latest
25+
runs-on: ${{ matrix.runs-on }}
2626
strategy:
2727
# we want that the matrix keeps running, default is to cancel them if it fails.
2828
fail-fast: false
@@ -31,9 +31,11 @@ jobs:
3131
platform: ["ios", "android"]
3232
include:
3333
- platform: ios
34+
runs-on: macos-latest
3435
name: iOS
3536
appPlain: test/perf/test-app-plain.ipa
3637
- platform: android
38+
runs-on: ubuntu-latest
3739
name: Android
3840
appPlain: test/perf/TestAppPlain/android/app/build/outputs/apk/release/app-release.apk
3941
steps:
@@ -45,6 +47,8 @@ jobs:
4547
with:
4648
java-version: '17'
4749
distribution: "adopt"
50+
- name: Gradle cache
51+
uses: gradle/gradle-build-action@v2
4852
- name: Install Global Dependencies
4953
run: yarn global add react-native-cli @sentry/cli yalc
5054
- uses: actions/cache@v3
@@ -141,7 +145,7 @@ jobs:
141145

142146
react-native-build:
143147
name: Build RN ${{ matrix.rn-version }} ${{ matrix.rn-architecture }} ${{ matrix.engine }} ${{ matrix.platform }} ${{ matrix.build-type }} ${{ matrix.ios-use-frameworks }}
144-
runs-on: macos-latest
148+
runs-on: ${{ matrix.runs-on }}
145149
env:
146150
RN_SENTRY_POD_NAME: RNSentry
147151
RN_DIFF_REPOSITORY: https://github.com/react-native-community/rn-diff-purge.git
@@ -151,16 +155,19 @@ jobs:
151155
rn-version: ['0.65.3', '0.73.2']
152156
rn-architecture: ['legacy', 'new']
153157
platform: ['android', 'ios']
154-
build-type: ['dev', 'production']
158+
build-type: ['production']
155159
ios-use-frameworks: ['no', 'static', 'dynamic']
156160
engine: ['hermes', 'jsc']
157161
include:
158162
- platform: ios
163+
runs-on: macos-latest
159164
runtime: 'latest'
160165
device: 'iPhone 14'
166+
- platform: android
167+
runs-on: ubuntu-latest
161168
exclude:
162169
# exclude JSC for new RN versions (keeping the matrix manageable)
163-
- rn-version: '0.72.4'
170+
- rn-version: '0.73.2'
164171
engine: 'jsc'
165172
# exclude all rn versions lower than 0.70.0 for new architecture
166173
- rn-version: '0.65.3'
@@ -215,10 +222,16 @@ jobs:
215222
java-version: '17'
216223
distribution: 'adopt'
217224

225+
- name: Gradle cache
226+
uses: gradle/gradle-build-action@v2
227+
218228
- name: Setup Global Tools
219229
run: |
220230
yarn global add yalc semver
221-
brew install xcbeautify
231+
232+
- name: Setup Global Xcode Tools
233+
if: ${{ matrix.platform == 'ios' }}
234+
run: brew install xcbeautify
222235

223236
- name: NPM cache SDK
224237
uses: actions/cache@v3
@@ -387,7 +400,7 @@ jobs:
387400
react-native-test:
388401
name: Test RN ${{ matrix.rn-version }} ${{ matrix.rn-architecture }} ${{ matrix.engine }} ${{ matrix.platform }} ${{ matrix.build-type }} ${{ matrix.ios-use-frameworks }}
389402
needs: react-native-build
390-
runs-on: macos-latest
403+
runs-on: ${{ matrix.runs-on }}
391404
strategy:
392405
fail-fast: false # keeps matrix running if one fails
393406
matrix:
@@ -399,24 +412,32 @@ jobs:
399412
engine: ['hermes', 'jsc']
400413
include:
401414
- platform: ios
415+
runs-on: macos-latest
402416
runtime: 'latest'
403417
device: 'iPhone 14'
418+
- platform: android
419+
runs-on: ubuntu-latest
404420
exclude:
405421
# exclude all rn versions lower than 0.70.0 for new architecture
406422
- rn-version: '0.65.3'
407423
rn-architecture: 'new'
408424
# e2e test only the default combinations
409425
- rn-version: '0.65.3'
410426
engine: 'hermes'
411-
- rn-version: '0.72.4'
427+
- rn-version: '0.73.2'
412428
engine: 'jsc'
429+
# E2E timeout due to a race condition https://github.com/facebook/react-native/issues/42123#issuecomment-1881203719
430+
- rn-version: '0.73.2'
431+
platform: 'ios'
432+
rn-architecture: 'new'
413433
env:
414434
PLATFORM: ${{ matrix.platform }}
415435
DEVICE: ${{ matrix.device }}
416436
steps:
417437
- uses: actions/checkout@v4
418438

419-
- name: Setup Global Tools
439+
- name: Setup Global Xcode Tools
440+
if: ${{ matrix.platform == 'ios' }}
420441
run: brew install xcbeautify
421442

422443
- name: Download App Package
@@ -445,6 +466,21 @@ jobs:
445466
java-version: '17'
446467
distribution: 'adopt'
447468

469+
- name: Gradle cache
470+
uses: gradle/gradle-build-action@v2
471+
472+
- name: Setup KVM
473+
if: ${{ matrix.platform == 'android' }}
474+
shell: bash
475+
run: |
476+
# check if virtualization is supported...
477+
sudo apt install -y --no-install-recommends cpu-checker coreutils && echo "CPUs=$(nproc --all)" && kvm-ok
478+
# allow access to KVM to run the emulator
479+
echo 'KERNEL=="kvm", GROUP="kvm", MODE="0666", OPTIONS+="static_node=kvm"' \
480+
| sudo tee /etc/udev/rules.d/99-kvm4all.rules
481+
sudo udevadm control --reload-rules
482+
sudo udevadm trigger --name-match=kvm
483+
448484
- name: NPM cache E2E Tests Library
449485
uses: actions/cache@v3
450486
id: deps-cache-e2e-library
@@ -494,10 +530,15 @@ jobs:
494530
uses: reactivecircus/android-emulator-runner@50986b1464923454c95e261820bc626f38490ec0 # pin@v2
495531
with:
496532
working-directory: test/e2e
497-
api-level: 29
533+
api-level: 30
534+
force-avd-creation: false
535+
disable-animations: true
536+
disable-spellchecker: true
537+
target: 'aosp_atd'
538+
channel: canary # Necessary for ATDs
498539
emulator-options: >
499-
-accel on
500-
-no-snapshot
540+
-no-window
541+
-no-snapshot-save
501542
-gpu swiftshader_indirect
502543
-noaudio
503544
-no-boot-anim

.github/workflows/native-tests.yml

+26-14
Original file line numberDiff line numberDiff line change
@@ -62,54 +62,66 @@ jobs:
6262
- name: Gradle cache
6363
uses: gradle/gradle-build-action@v2
6464

65+
- name: Setup KVM
66+
shell: bash
67+
run: |
68+
# check if virtualization is supported...
69+
sudo apt install -y --no-install-recommends cpu-checker coreutils && echo "CPUs=$(nproc --all)" && kvm-ok
70+
# allow access to KVM to run the emulator
71+
echo 'KERNEL=="kvm", GROUP="kvm", MODE="0666", OPTIONS+="static_node=kvm"' \
72+
| sudo tee /etc/udev/rules.d/99-kvm4all.rules
73+
sudo udevadm control --reload-rules
74+
sudo udevadm trigger --name-match=kvm
75+
6576
- name: AVD cache
6677
uses: actions/cache@v3
6778
id: avd-cache
6879
with:
6980
path: |
7081
~/.android/avd/*
7182
~/.android/adb*
72-
key: avd-21
83+
key: avd-aosp-atd-30
7384

7485
- name: Create AVD and generate snapshot for caching
7586
if: steps.avd-cache.outputs.cache-hit != 'true'
7687
uses: reactivecircus/android-emulator-runner@d94c3fbe4fe6a29e4a5ba47c12fb47677c73656b #[email protected]
7788
with:
78-
api-level: 21
89+
api-level: 30
90+
force-avd-creation: false
91+
disable-animations: true
92+
disable-spellchecker: true
93+
target: 'aosp_atd'
94+
channel: canary # Necessary for ATDs
7995
emulator-options: >
80-
-accel on
8196
-no-window
97+
-no-snapshot-save
8298
-gpu swiftshader_indirect
8399
-noaudio
84100
-no-boot-anim
85101
-camera-back none
86102
-camera-front none
87103
-timezone US/Pacific
88-
force-avd-creation: false
89-
disable-animations: true
90-
arch: x86_64
91-
profile: Nexus 6
92104
script: echo "Generated AVD snapshot for caching."
93105

94106
- name: Run connected tests
95107
uses: reactivecircus/android-emulator-runner@d94c3fbe4fe6a29e4a5ba47c12fb47677c73656b #[email protected]
96108
with:
97109
working-directory: RNSentryAndroidTester
98-
api-level: 21
110+
api-level: 30
111+
force-avd-creation: false
112+
disable-animations: true
113+
disable-spellchecker: true
114+
target: 'aosp_atd'
115+
channel: canary # Necessary for ATDs
99116
emulator-options: >
100-
-no-snapshot-save
101-
-accel on
102117
-no-window
118+
-no-snapshot-save
103119
-gpu swiftshader_indirect
104120
-noaudio
105121
-no-boot-anim
106122
-camera-back none
107123
-camera-front none
108124
-timezone US/Pacific
109-
force-avd-creation: false
110-
disable-animations: true
111-
arch: x86_64
112-
profile: Nexus 6
113125
script: |
114126
./gradlew uninstallDebug uninstallDebugAndroidTest
115127
./gradlew connectedCheck

.github/workflows/sample-application.yml

+10-4
Original file line numberDiff line numberDiff line change
@@ -24,8 +24,7 @@ jobs:
2424

2525
build:
2626
name: Build ${{ matrix.rn-architecture }} ${{ matrix.platform }} ${{ matrix.build-type }}
27-
# Android emulator said to perform best with macos HAXM
28-
runs-on: macos-latest
27+
runs-on: ${{ matrix.runs-on }}
2928
strategy:
3029
# we want that the matrix keeps running, default is to cancel them if it fails.
3130
fail-fast: false
@@ -35,8 +34,11 @@ jobs:
3534
build-type: ['dev', 'production']
3635
include:
3736
- platform: ios
37+
runs-on: macos-latest
3838
runtime: 'latest'
3939
device: 'iPhone 14'
40+
- platform: android
41+
runs-on: ubuntu-latest
4042
steps:
4143
- uses: actions/checkout@v4
4244

@@ -52,7 +54,11 @@ jobs:
5254
java-version: '17'
5355
distribution: 'adopt'
5456

55-
- name: Install Global Dependencies
57+
- name: Gradle cache
58+
uses: gradle/gradle-build-action@v2
59+
60+
- name: Setup Global Xcode Tools
61+
if: ${{ matrix.platform == 'ios' }}
5662
run: brew install xcbeautify
5763

5864
- name: NPM cache
@@ -62,7 +68,7 @@ jobs:
6268
path: |
6369
node_modules
6470
samples/react-native/node_modules
65-
key: ${{ github.workflow }}-${{ github.job }}-npm-${{ hashFiles('yarn.lock', 'samples/react-native/yarn.lock') }}
71+
key: ${{ github.workflow }}-${{ github.job }}-${{ runner.os }}-npm-${{ hashFiles('yarn.lock', 'samples/react-native/yarn.lock') }}
6672

6773
- name: Install SDK Dependencies
6874
if: ${{ steps.deps-cache.outputs['cache-hit'] != 'true' }}

0 commit comments

Comments
 (0)