Skip to content

Commit 9dad432

Browse files
committed
Move to GH Actions (#158)
* Revert "feat: implement visionOS CI (#54)" This reverts commit ae6f903. * fix: implement GH actions CI
1 parent dd16e36 commit 9dad432

File tree

6 files changed

+141
-44
lines changed

6 files changed

+141
-44
lines changed

.github/actions/test-ios-helloworld/action.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -43,7 +43,7 @@ runs:
4343
- name: Run yarn
4444
uses: ./.github/actions/yarn-install-with-cache
4545
- name: Setup ruby
46-
uses: ruby/setup-ruby@v1.170.0
46+
uses: ruby/setup-ruby@v1.171.0
4747
with:
4848
ruby-version: ${{ inputs.ruby-version }}
4949
- name: Install iOS dependencies - Configuration ${{ inputs.flavor }}; New Architecture ${{ inputs.architecture }}; JS Engine ${{ inputs.jsengine }}

.github/actions/test-ios-rntester/action.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -48,7 +48,7 @@ runs:
4848
name: hermes-darwin-bin-${{ inputs.flavor }}
4949
path: ${{ inputs.hermes-tarball-artifacts-dir }}
5050
- name: Setup ruby
51-
uses: ruby/setup-ruby@v1.170.0
51+
uses: ruby/setup-ruby@v1.171.0
5252
with:
5353
ruby-version: ${{ inputs.ruby-version }}
5454
- name: Prepare IOS Tests
Lines changed: 66 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,66 @@
1+
name: test-visionos-rntester
2+
description: Build visionOS RNTester using JSC
3+
inputs:
4+
use-frameworks:
5+
description: The dependency building and linking strategy to use. Must be one of "StaticLibraries", "DynamicFrameworks"
6+
default: StaticLibraries
7+
architecture:
8+
description: The React Native architecture to Test. RNTester has always Fabric enabled, but we want to run integration test with the old arch setup
9+
default: NewArch
10+
ruby-version:
11+
description: The version of ruby that must be used
12+
default: 2.6.10
13+
flavor:
14+
description: The flavor of the build. Must be one of "Debug", "Release".
15+
default: Debug
16+
react-native-version:
17+
description: The version of react-native
18+
required: true
19+
run-e2e-tests:
20+
description: Whether we want to run E2E tests or not
21+
required: false
22+
default: false
23+
24+
runs:
25+
using: composite
26+
steps:
27+
- name: Setup xcode
28+
uses: ./.github/actions/setup-xcode
29+
with:
30+
xcode-version: "15.4"
31+
- name: Setup node.js
32+
uses: ./.github/actions/setup-node
33+
- name: Run yarn
34+
uses: ./.github/actions/yarn-install-with-cache
35+
- name: Setup ruby
36+
uses: ruby/[email protected]
37+
with:
38+
ruby-version: ${{ inputs.ruby-version }}
39+
- name: Setup xcode build cache
40+
uses: ./.github/actions/setup-xcode-build-cache
41+
- name: Install CocoaPods dependencies
42+
shell: bash
43+
run: |
44+
export USE_HERMES=0
45+
46+
if [[ ${{ inputs.use-frameworks }} == "DynamicFrameworks" ]]; then
47+
export USE_FRAMEWORKS=dynamic
48+
fi
49+
50+
if [[ ${{ inputs.architecture }} == "NewArch" ]]; then
51+
export RCT_NEW_ARCH_ENABLED=1
52+
fi
53+
54+
cd packages/rn-tester
55+
56+
bundle install
57+
bundle exec pod install
58+
- name: Build RNTester for visionOS
59+
if: ${{ inputs.run-e2e-tests == 'false' }}
60+
shell: bash
61+
run: |
62+
xcodebuild build \
63+
-workspace packages/rn-tester/RNTesterPods.xcworkspace \
64+
-scheme RNTester-visionOS \
65+
-sdk xrsimulator \
66+
-destination "platform=visionOS Simulator,name=Apple Vision Pro"

.github/workflows/test-all.yml

Lines changed: 42 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -1,21 +1,20 @@
11
name: Test All
22

3-
# on:
4-
# workflow_dispatch:
5-
# pull_request:
6-
# push:
7-
# tags:
8-
# - 'v*'
9-
# # nightly build @ 2:15 AM UTC
10-
# schedule:
11-
# - cron: '15 2 * * *'
3+
on:
4+
workflow_dispatch:
5+
pull_request:
6+
push:
7+
branches:
8+
- main
9+
- "*-stable"
1210

1311
concurrency:
1412
group: ${{ github.workflow }}-${{ github.ref }}
1513
cancel-in-progress: ${{ github.ref != 'refs/heads/main' && !contains(github.ref, 'stable')}}
1614

1715
jobs:
1816
set_release_type:
17+
if: github.repository == 'facebook/react-native'
1918
runs-on: ubuntu-latest
2019
outputs:
2120
RELEASE_TYPE: ${{ steps.set_release_type.outputs.RELEASE_TYPE }}
@@ -37,6 +36,7 @@ jobs:
3736
fi
3837
3938
prepare_hermes_workspace:
39+
if: github.repository == 'facebook/react-native'
4040
runs-on: ubuntu-latest
4141
env:
4242
HERMES_WS_DIR: /tmp/hermes
@@ -55,6 +55,7 @@ jobs:
5555
hermes-version-file: ${{ env.HERMES_VERSION_FILE }}
5656

5757
build_hermesc_apple:
58+
if: github.repository == 'facebook/react-native'
5859
runs-on: macos-13
5960
needs: prepare_hermes_workspace
6061
env:
@@ -69,6 +70,7 @@ jobs:
6970
react-native-version: ${{ needs.prepare_hermes_workspace.outputs.react-native-version }}
7071

7172
build_apple_slices_hermes:
73+
if: github.repository == 'facebook/react-native'
7274
runs-on: macos-14
7375
needs: [build_hermesc_apple, prepare_hermes_workspace]
7476
env:
@@ -95,6 +97,7 @@ jobs:
9597
react-native-version: ${{ needs.prepare_hermes_workspace.outputs.react-native-version }}
9698

9799
build_hermes_macos:
100+
if: github.repository == 'facebook/react-native'
98101
runs-on: macos-13
99102
needs: [build_apple_slices_hermes, prepare_hermes_workspace]
100103
env:
@@ -116,6 +119,7 @@ jobs:
116119
flavor: ${{ matrix.flavor }}
117120

118121
test_ios_rntester_ruby_3_2_0:
122+
if: github.repository == 'facebook/react-native'
119123
runs-on: macos-13
120124
needs:
121125
[build_apple_slices_hermes, prepare_hermes_workspace, build_hermes_macos]
@@ -133,6 +137,7 @@ jobs:
133137
react-native-version: ${{ needs.prepare_hermes_workspace.outputs.react-native-version }}
134138

135139
test_ios_rntester_dynamic_frameworks:
140+
if: github.repository == 'facebook/react-native'
136141
runs-on: macos-13
137142
needs:
138143
[build_apple_slices_hermes, prepare_hermes_workspace, build_hermes_macos]
@@ -156,6 +161,7 @@ jobs:
156161
react-native-version: ${{ needs.prepare_hermes_workspace.outputs.react-native-version }}
157162

158163
test_ios_rntester:
164+
if: github.repository == 'facebook/react-native'
159165
runs-on: macos-13
160166
needs:
161167
[build_apple_slices_hermes, prepare_hermes_workspace, build_hermes_macos]
@@ -166,7 +172,6 @@ jobs:
166172
strategy:
167173
fail-fast: false
168174
matrix:
169-
jsengine: [Hermes, JSC]
170175
architecture: [NewArch, OldArch]
171176
steps:
172177
- name: Checkout
@@ -181,6 +186,26 @@ jobs:
181186
hermes-version: ${{ needs.prepare_hermes_workspace.outputs.hermes-version }}
182187
react-native-version: ${{ needs.prepare_hermes_workspace.outputs.react-native-version }}
183188

189+
test_visionos_rntester:
190+
runs-on: macos-14-xlarge
191+
continue-on-error: true
192+
strategy:
193+
fail-fast: false
194+
matrix:
195+
architecture: [NewArch, OldArch]
196+
steps:
197+
- name: Checkout
198+
uses: actions/checkout@v4
199+
- name: Run it
200+
uses: ./.github/actions/test-visionos-rntester
201+
with:
202+
jsengine: ${{ matrix.jsengine }}
203+
architecture: ${{ matrix.architecture }}
204+
run-unit-tests: "false"
205+
use-frameworks: StaticLibraries
206+
hermes-version: ${{ needs.prepare_hermes_workspace.outputs.hermes-version }}
207+
react-native-version: ${{ needs.prepare_hermes_workspace.outputs.react-native-version }}
208+
184209
test_e2e_ios_rntester:
185210
if: ${{ github.ref == 'refs/heads/main' || contains(github.ref, 'stable') }}
186211
runs-on: macos-13
@@ -238,7 +263,7 @@ jobs:
238263
- name: Run yarn
239264
uses: ./.github/actions/yarn-install-with-cache
240265
- name: Setup ruby
241-
uses: ruby/setup-ruby@v1.170.0
266+
uses: ruby/setup-ruby@v1.171.0
242267
with:
243268
ruby-version: 2.6.10
244269
- name: Download Hermes
@@ -342,6 +367,7 @@ jobs:
342367
install-java: 'false'
343368

344369
build_hermesc_linux:
370+
if: github.repository == 'facebook/react-native'
345371
runs-on: ubuntu-latest
346372
needs: prepare_hermes_workspace
347373
env:
@@ -357,6 +383,7 @@ jobs:
357383
react-native-version: ${{ needs.prepare_hermes_workspace.outputs.react-native-version }}
358384

359385
build_hermesc_windows:
386+
if: github.repository == 'facebook/react-native'
360387
runs-on: windows-2019
361388
needs: prepare_hermes_workspace
362389
env:
@@ -376,6 +403,7 @@ jobs:
376403
react-native-version: ${{ needs.prepare_hermes_workspace.outputs.react-native-version }}
377404

378405
build_android:
406+
if: github.repository == 'facebook/react-native'
379407
runs-on: 8-core-ubuntu
380408
needs: [set_release_type]
381409
container:
@@ -516,6 +544,7 @@ jobs:
516544
compression-level: 0
517545

518546
test_ios_helloworld_with_ruby_3_2_0:
547+
if: github.repository == 'facebook/react-native'
519548
runs-on: macos-13
520549
needs: [prepare_hermes_workspace, build_hermes_macos] # prepare_hermes_workspace must be there because we need its reference to retrieve a couple of outputs
521550
env:
@@ -534,6 +563,7 @@ jobs:
534563
react-native-version: ${{ needs.prepare_hermes_workspace.outputs.react-native-version }}
535564

536565
test_ios_helloworld:
566+
if: github.repository == 'facebook/react-native'
537567
runs-on: macos-13
538568
needs: [prepare_hermes_workspace, build_hermes_macos] # prepare_hermes_workspace must be there because we need its reference to retrieve a couple of outputs
539569
strategy:
@@ -577,6 +607,7 @@ jobs:
577607

578608
lint:
579609
runs-on: ubuntu-latest
610+
if: github.repository == 'facebook/react-native'
580611
env:
581612
GH_TOKEN: ${{ secrets.GITHUB_TOKEN }}
582613
steps:

packages/react-native/Libraries/__tests__/__snapshots__/public-api-test.js.snap

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -9717,7 +9717,7 @@ exports[`public API should not change unintentionally Libraries/WebSocket/WebSoc
97179717
exports[`public API should not change unintentionally Libraries/WebSocket/WebSocketInterceptor.js 1`] = `"UNTYPED MODULE"`;
97189718

97199719
exports[`public API should not change unintentionally Libraries/WindowManager/NativeWindowManager.js 1`] = `
9720-
"export * from \\"../../src/private/specs/visionos_modules/NativeWindowManager\\";
9720+
"export * from \\"../../visionos_modules/NativeWindowManager\\";
97219721
declare export default typeof NativeWindowManager;
97229722
"
97239723
`;
@@ -9739,7 +9739,7 @@ declare module.exports: WindowManager;
97399739
`;
97409740

97419741
exports[`public API should not change unintentionally Libraries/XR/NativeXRModule.js 1`] = `
9742-
"export * from \\"../../src/private/specs/visionos_modules/NativeXRModule\\";
9742+
"export * from \\"../../visionos_modules/NativeXRModule\\";
97439743
declare export default typeof NativeXRModule;
97449744
"
97459745
`;

yarn.lock

Lines changed: 29 additions & 29 deletions
Original file line numberDiff line numberDiff line change
@@ -1944,17 +1944,17 @@
19441944
resolved "https://registry.yarnpkg.com/@react-native/assets-registry/-/assets-registry-0.74.0.tgz#560bec29b2699c4d4cbfecfb4c2c5025397aac23"
19451945
integrity sha512-I8Yy6bCKU5R4qZX4jfXsAPsHyuGHlulbnbG3NqO9JgZ3T2DJxJiZE39rHORP0trLnRh0rIeRcs4Mc14fAE6hrw==
19461946

1947-
"@react-native/[email protected].85":
1948-
version "0.74.85"
1949-
resolved "https://registry.yarnpkg.com/@react-native/babel-plugin-codegen/-/babel-plugin-codegen-0.74.85.tgz#067224bf5099ee2679babd700c7115822a747004"
1950-
integrity sha512-48TSDclRB5OMXiImiJkLxyCfRyLsqkCgI8buugCZzvXcYslfV7gCvcyFyQldtcOmerV+CK4RAj7QS4hmB5Mr8Q==
1947+
"@react-native/[email protected].86":
1948+
version "0.74.86"
1949+
resolved "https://registry.yarnpkg.com/@react-native/babel-plugin-codegen/-/babel-plugin-codegen-0.74.86.tgz#4edbb8887c5cedefd52e8fda973b1da97c779db4"
1950+
integrity sha512-fO7exk0pdsOSsK3fvDz4YKe5nMeAMrsIGi525pft/L+dedjdeiWYmEoQVc9NElxwwNCldwRY6eNMw6IhKyjzLA==
19511951
dependencies:
1952-
"@react-native/codegen" "0.74.85"
1952+
"@react-native/codegen" "0.74.86"
19531953

1954-
"@react-native/[email protected].85":
1955-
version "0.74.85"
1956-
resolved "https://registry.yarnpkg.com/@react-native/babel-preset/-/babel-preset-0.74.85.tgz#3ce6ca77a318dec226fd9e3fff9c2ef7b0aa66e3"
1957-
integrity sha512-yMHUlN8INbK5BBwiBuQMftdWkpm1IgCsoJTKcGD2OpSgZhwwm8RUSvGhdRMzB2w7bsqqBmaEMleGtW6aCR7B9w==
1954+
"@react-native/[email protected].86":
1955+
version "0.74.86"
1956+
resolved "https://registry.yarnpkg.com/@react-native/babel-preset/-/babel-preset-0.74.86.tgz#8bb3fbd49ce11470eb8022dea2c1e51bfa8dedd4"
1957+
integrity sha512-6A+1NVAHugbBLFNU4iaYrq2lx8P7pINyqoyTtVAqd375PShRmLwu6GvuF3b/4avC97s6LmBljVTJ1xVHukA42g==
19581958
dependencies:
19591959
"@babel/core" "^7.20.0"
19601960
"@babel/plugin-proposal-async-generator-functions" "^7.0.0"
@@ -1996,7 +1996,7 @@
19961996
"@babel/plugin-transform-typescript" "^7.5.0"
19971997
"@babel/plugin-transform-unicode-regex" "^7.0.0"
19981998
"@babel/template" "^7.0.0"
1999-
"@react-native/babel-plugin-codegen" "0.74.85"
1999+
"@react-native/babel-plugin-codegen" "0.74.86"
20002000
babel-plugin-transform-flow-enums "^0.0.2"
20012001
react-refresh "^0.14.0"
20022002

@@ -2010,10 +2010,10 @@
20102010
jscodeshift "^0.14.0"
20112011
nullthrows "^1.1.1"
20122012

2013-
"@react-native/[email protected].85":
2014-
version "0.74.85"
2015-
resolved "https://registry.yarnpkg.com/@react-native/codegen/-/codegen-0.74.85.tgz#568464071c0b9be741da1a1ab43b1df88180ca5d"
2016-
integrity sha512-N7QwoS4Hq/uQmoH83Ewedy6D0M7xbQsOU3OMcQf0eY3ltQ7S2hd9/R4UTalQWRn1OUJfXR6OG12QJ4FStKgV6Q==
2013+
"@react-native/[email protected].86":
2014+
version "0.74.86"
2015+
resolved "https://registry.yarnpkg.com/@react-native/codegen/-/codegen-0.74.86.tgz#90933f5ee555ffb95ca27372ba1e836f698c3192"
2016+
integrity sha512-BOwABta9035GJ/zLMkxQfgPMr47u1/1HqNIMk10FqmTe0jmROOxKEAeP4FbeS5L1voO4ug3dqr+mcuHrG+HNhA==
20172017
dependencies:
20182018
"@babel/parser" "^7.20.0"
20192019
glob "^7.1.1"
@@ -2040,18 +2040,18 @@
20402040
node-fetch "^2.2.0"
20412041
readline "^1.3.0"
20422042

2043-
"@react-native/[email protected].85":
2044-
version "0.74.85"
2045-
resolved "https://registry.yarnpkg.com/@react-native/debugger-frontend/-/debugger-frontend-0.74.85.tgz#a7af94a7b81cb59f241fd1771d1b083445329700"
2046-
integrity sha512-gUIhhpsYLUTYWlWw4vGztyHaX/kNlgVspSvKe2XaPA7o3jYKUoNLc3Ov7u70u/MBWfKdcEffWq44eSe3j3s5JQ==
2043+
"@react-native/[email protected].86":
2044+
version "0.74.86"
2045+
resolved "https://registry.yarnpkg.com/@react-native/debugger-frontend/-/debugger-frontend-0.74.86.tgz#87a3c7dfb12ee6e981165e304bbbe20e9b1fa009"
2046+
integrity sha512-Spq1kFX4qvPmT4HuTwpi1ALFtojlJ6s4GpWU2OnpevC/z7ks36lhD3J0rd0D9U5bkxtTYLcg31fPv7nGFC7XZg==
20472047

20482048
"@react-native/dev-middleware@^0.74.0":
2049-
version "0.74.85"
2050-
resolved "https://registry.yarnpkg.com/@react-native/dev-middleware/-/dev-middleware-0.74.85.tgz#eca35aceb882b1111385f7c20f1aad7a33a2734e"
2051-
integrity sha512-BRmgCK5vnMmHaKRO+h8PKJmHHH3E6JFuerrcfE3wG2eZ1bcSr+QTu8DAlpxsDWvJvHpCi8tRJGauxd+Ssj/c7w==
2049+
version "0.74.86"
2050+
resolved "https://registry.yarnpkg.com/@react-native/dev-middleware/-/dev-middleware-0.74.86.tgz#b95f936c141dd44309a9ec558ed5ce034e270bc4"
2051+
integrity sha512-sc0tYxYt6dkUbNFI1IANzKO67M41BhjbJ6k/CHoFi/tGoNmHzg9IUZ89V4g3H8hn/VW9dETnPOFna1VO0sWrXg==
20522052
dependencies:
20532053
"@isaacs/ttlcache" "^1.4.1"
2054-
"@react-native/debugger-frontend" "0.74.85"
2054+
"@react-native/debugger-frontend" "0.74.86"
20552055
"@rnx-kit/chromium-edge-launcher" "^1.0.0"
20562056
chrome-launcher "^0.15.2"
20572057
connect "^3.6.5"
@@ -2075,12 +2075,12 @@
20752075
integrity sha512-DMpn5l1TVkIBFe9kE54pwOI2fQYbQNZ6cto0IuCUxQVUFJBcFMJ6Gbk8jhz8tvcWuDW3xVK9AWq9DJTkuchWsQ==
20762076

20772077
"@react-native/metro-babel-transformer@^0.74.0":
2078-
version "0.74.85"
2079-
resolved "https://registry.yarnpkg.com/@react-native/metro-babel-transformer/-/metro-babel-transformer-0.74.85.tgz#d530d9a6bd319ece226a2d6aaa00b464a1928089"
2080-
integrity sha512-JIrXqEwhTvWPtGArgMptIPGstMdXQIkwSjKVYt+7VC4a9Pw1GurIWanIJheEW6ZuCVvTc0VZkwglFz9JVjzDjA==
2078+
version "0.74.86"
2079+
resolved "https://registry.yarnpkg.com/@react-native/metro-babel-transformer/-/metro-babel-transformer-0.74.86.tgz#d67d3bf1699fcf834a70155635b30ae9f667b6dd"
2080+
integrity sha512-/9qN5zcnTHGDkC4jWibnoGmRnzDXiurl5wmkvspgnsdrJINN6eGpK8sdIn6nrHFOuPlp3Metqw3HkxbuAfNUXw==
20812081
dependencies:
20822082
"@babel/core" "^7.20.0"
2083-
"@react-native/babel-preset" "0.74.85"
2083+
"@react-native/babel-preset" "0.74.86"
20842084
hermes-parser "0.19.1"
20852085
nullthrows "^1.1.1"
20862086

@@ -2314,9 +2314,9 @@
23142314
integrity sha512-fAtCfv4jJg+ExtXhvCkCqUKZ+4ok/JQk01qDKhL5BDDoS3AxKXhV5/MAVUZyQnSEd2GT92fkgZl0pz0Q0AzcIQ==
23152315

23162316
"@types/node@^18.0.0":
2317-
version "18.19.42"
2318-
resolved "https://registry.yarnpkg.com/@types/node/-/node-18.19.42.tgz#b54ed4752c85427906aab40917b0f7f3d724bf72"
2319-
integrity sha512-d2ZFc/3lnK2YCYhos8iaNIYu9Vfhr92nHiyJHRltXWjXUBjEE+A4I58Tdbnw4VhggSW+2j5y5gTrLs4biNnubg==
2317+
version "18.19.43"
2318+
resolved "https://registry.yarnpkg.com/@types/node/-/node-18.19.43.tgz#fe01bb599b60bb3279c26d0fdb751d2f3e299ae0"
2319+
integrity sha512-Mw/YlgXnyJdEwLoFv2dpuJaDFriX+Pc+0qOBJ57jC1H6cDxIj2xc5yUrdtArDVG0m+KV6622a4p2tenEqB3C/g==
23202320
dependencies:
23212321
undici-types "~5.26.4"
23222322

0 commit comments

Comments
 (0)