Skip to content

Commit 3d5f7be

Browse files
abueideclaude
andcommitted
refactor(rn): separate build and deploy tasks for iOS
Split iOS build and deploy into separate process-compose tasks to enable: - Parallel execution of build-ios with ios-simulator boot - Clear failure attribution (build vs deploy) - Consistent structure with Android test suites Changes: - test-suite-ios-e2e.yaml: Split deploy-ios into build-ios + deploy-ios - test-suite-all-e2e.yaml: Split deploy-ios into build-ios + deploy-ios - Updated device lock files from test runs Co-Authored-By: Claude Sonnet 4.5 <noreply@anthropic.com>
1 parent ec0b215 commit 3d5f7be

5 files changed

Lines changed: 42 additions & 24 deletions

File tree

examples/android/devbox.d/android/devices/devices.lock

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -14,5 +14,5 @@
1414
}
1515
],
1616
"checksum": "8df4d3393b61fbbb08e45cf8762f95c521316938e514527916e4fce88a849d57",
17-
"generated_at": "2026-02-20T00:44:55Z"
17+
"generated_at": "2026-02-20T01:42:04Z"
1818
}

examples/react-native/devbox.d/android/devices/devices.lock

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -14,5 +14,5 @@
1414
}
1515
],
1616
"checksum": "8df4d3393b61fbbb08e45cf8762f95c521316938e514527916e4fce88a849d57",
17-
"generated_at": "2026-02-20T00:55:46Z"
17+
"generated_at": "2026-02-20T01:46:34Z"
1818
}

examples/react-native/devbox.d/ios/devices/devices.lock

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,5 +10,5 @@
1010
}
1111
],
1212
"checksum": "4d5276f203d7ad62860bfc067f76194df53be449d4aa8a3b2d069855ec1f3232",
13-
"generated_at": "2026-02-20T00:55:48Z"
13+
"generated_at": "2026-02-20T01:46:35Z"
1414
}

examples/react-native/tests/test-suite-all-e2e.yaml

Lines changed: 25 additions & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -133,6 +133,29 @@ processes:
133133
success_threshold: 1
134134
failure_threshold: 12
135135

136+
# Phase 5b: Build iOS app
137+
build-ios:
138+
command: |
139+
set -e
140+
141+
BUILD_CONFIG="${IOS_BUILD_CONFIG:-Debug}"
142+
echo "Building React Native app (${BUILD_CONFIG})"
143+
144+
# Source Metro environment so React Native uses correct port
145+
. ${REACT_NATIVE_VIRTENV}/metro/env-all.sh
146+
echo "Metro port: $METRO_PORT"
147+
148+
# Build with ios.sh build
149+
NODE_BINARY="$NODE_BINARY" RCT_METRO_PORT="$METRO_PORT" \
150+
ios.sh build --config "$BUILD_CONFIG" --quiet
151+
152+
echo "Build complete"
153+
depends_on:
154+
install-pods:
155+
condition: process_completed_successfully
156+
availability:
157+
restart: "no"
158+
136159
# Phase 6a: Deploy Android app
137160
deploy-android:
138161
command: |
@@ -167,28 +190,14 @@ processes:
167190
availability:
168191
restart: "no"
169192

170-
# Phase 6b: Build and deploy iOS app
193+
# Phase 6b: Deploy iOS app
171194
deploy-ios:
172195
command: |
173196
set -e
174-
175-
BUILD_CONFIG="${IOS_BUILD_CONFIG:-Debug}"
176-
echo "Building React Native app (${BUILD_CONFIG})"
177-
178-
# Source Metro environment so React Native uses correct port
179-
. ${REACT_NATIVE_VIRTENV}/metro/env-all.sh
180-
echo "Metro port: $METRO_PORT"
181-
182-
# Build with ios.sh build
183-
NODE_BINARY="$NODE_BINARY" RCT_METRO_PORT="$METRO_PORT" \
184-
ios.sh build --config "$BUILD_CONFIG" --quiet
185-
186-
# Deploy to simulator
187197
ios.sh deploy
188-
189198
echo "App deployed and launched successfully"
190199
depends_on:
191-
install-pods:
200+
build-ios:
192201
condition: process_completed_successfully
193202
ios-simulator:
194203
condition: process_healthy

examples/react-native/tests/test-suite-ios-e2e.yaml

Lines changed: 14 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -82,8 +82,8 @@ processes:
8282
success_threshold: 1
8383
failure_threshold: 12
8484

85-
# Phase 6: Build and deploy app
86-
deploy-ios:
85+
# Phase 6a: Build iOS app
86+
build-ios:
8787
command: |
8888
set -e
8989
@@ -98,12 +98,21 @@ processes:
9898
NODE_BINARY="$NODE_BINARY" RCT_METRO_PORT="$METRO_PORT" \
9999
ios.sh build --config "$BUILD_CONFIG" --quiet
100100
101-
# Deploy to simulator
102-
ios.sh deploy
101+
echo "Build complete"
102+
depends_on:
103+
install-pods:
104+
condition: process_completed_successfully
105+
availability:
106+
restart: "no"
103107

108+
# Phase 6b: Deploy iOS app
109+
deploy-ios:
110+
command: |
111+
set -e
112+
ios.sh deploy
104113
echo "App deployed and launched successfully"
105114
depends_on:
106-
install-pods:
115+
build-ios:
107116
condition: process_completed_successfully
108117
ios-simulator:
109118
condition: process_healthy

0 commit comments

Comments
 (0)