Skip to content

Commit f1cfe4e

Browse files
committed
[RN][iOS][CI] Restore testing with Cocoapods and use_frameworks
1 parent 4c732b4 commit f1cfe4e

2 files changed

Lines changed: 32 additions & 10 deletions

File tree

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

Lines changed: 14 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,6 @@
11
name: test-ios-rntester
22
description: Test iOS RNTester
33
inputs:
4-
use-frameworks:
5-
description: The dependency building and linking strategy to use. Must be one of "StaticLibraries", "DynamicFrameworks"
6-
default: StaticLibraries
74
ruby-version:
85
description: The version of ruby that must be used
96
default: 2.6.10
@@ -17,6 +14,10 @@ inputs:
1714
description: Whether we want to run E2E tests or not
1815
required: false
1916
default: false
17+
use-frameworks:
18+
description: Whether we have to build with Dynamic Frameworks. If this is set to true, it builds from source
19+
required: false
20+
default: false
2021

2122
runs:
2223
using: composite
@@ -43,29 +44,34 @@ runs:
4344
if: ${{ inputs.run-unit-tests == 'true' }}
4445
uses: ./.github/actions/prepare-ios-tests
4546
- name: Download ReactNativeDependencies
47+
if: ${{ inputs.use-frameworks == 'false' }}
4648
uses: actions/download-artifact@v4
4749
with:
4850
name: ReactNativeDependencies${{ inputs.flavor }}.xcframework.tar.gz
4951
path: /tmp/third-party/
5052
- name: Print third-party folder
53+
if: ${{ inputs.use-frameworks == 'false' }}
5154
shell: bash
5255
run: ls -lR /tmp/third-party
5356
- name: Download React Native Prebuilds
57+
if: ${{ inputs.use-frameworks == 'false' }}
5458
uses: actions/download-artifact@v4
5559
with:
5660
name: ReactCore${{ inputs.flavor }}.xcframework.tar.gz
5761
path: /tmp/ReactCore
5862
- name: Print ReactCore folder
63+
if: ${{ inputs.use-frameworks == 'false' }}
5964
shell: bash
6065
run: ls -lR /tmp/ReactCore
6166
- name: Install CocoaPods dependencies
6267
shell: bash
6368
run: |
64-
export RCT_USE_LOCAL_RN_DEP="/tmp/third-party/ReactNativeDependencies${{ inputs.flavor }}.xcframework.tar.gz"
65-
export RCT_TESTONLY_RNCORE_TARBALL_PATH="/tmp/ReactCore/ReactCore${{ inputs.flavor }}.xcframework.tar.gz"
66-
67-
if [[ ${{ inputs.use-frameworks }} == "DynamicFrameworks" ]]; then
69+
if [[ ${{ inputs.use-frameworks }} == "true" ]]; then
6870
export USE_FRAMEWORKS=dynamic
71+
else
72+
# If use-frameworks is false, let's use prebuilds
73+
export RCT_USE_LOCAL_RN_DEP="/tmp/third-party/ReactNativeDependencies${{ inputs.flavor }}.xcframework.tar.gz"
74+
export RCT_TESTONLY_RNCORE_TARBALL_PATH="/tmp/ReactCore/ReactCore${{ inputs.flavor }}.xcframework.tar.gz"
6975
fi
7076
7177
cd packages/rn-tester
@@ -108,7 +114,7 @@ runs:
108114
name: xcresults
109115
path: /Users/distiller/Library/Developer/Xcode/xcresults.tar.gz
110116
- name: Upload RNTester App
111-
if: ${{ inputs.use-frameworks == 'StaticLibraries' && inputs.ruby-version == '2.6.10' }} # This is needed to avoid conflicts with the artifacts
117+
if: ${{ inputs.use-frameworks == 'false' && inputs.ruby-version == '2.6.10' }} # This is needed to avoid conflicts with the artifacts
112118
uses: actions/upload-artifact@v4.3.4
113119
with:
114120
name: RNTesterApp-NewArch-${{ inputs.flavor }}

.github/workflows/test-all.yml

Lines changed: 18 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -58,6 +58,22 @@ jobs:
5858
ruby-version: "3.2.0"
5959
flavor: Debug
6060

61+
test_ios_rntester_dynamic_frameworks:
62+
runs-on: macos-15-large
63+
strategy:
64+
fail-fast: false
65+
matrix:
66+
flavor: [Debug, Release]
67+
steps:
68+
- name: Checkout
69+
uses: actions/checkout@v4
70+
- name: Run it
71+
uses: ./.github/actions/test-ios-rntester
72+
with:
73+
flavor: Debug
74+
use-frameworks: true
75+
76+
6177
test_ios_rntester:
6278
runs-on: macos-15-large
6379
needs:
@@ -67,7 +83,7 @@ jobs:
6783
fail-fast: false
6884
matrix:
6985
flavor: [Debug, Release]
70-
frameworks: [StaticLibraries, DynamicFrameworks]
86+
frameworks: [false, true]
7187
steps:
7288
- name: Checkout
7389
uses: actions/checkout@v4
@@ -441,7 +457,7 @@ jobs:
441457
strategy:
442458
matrix:
443459
flavor: [Debug, Release]
444-
use_frameworks: [StaticLibraries, DynamicFrameworks]
460+
use_frameworks: [false, true]
445461
exclude:
446462
# This config is tested with Ruby 3.2.0. Let's not double test it.
447463
- flavor: Debug

0 commit comments

Comments
 (0)