Embed JS bundle in nightly E2E apps

This commit is contained in:
Samuel Newman
2026-07-17 15:58:28 +03:00
parent 6f8f363949
commit b6b0e41fd4
6 changed files with 30 additions and 57 deletions
-1
View File
@@ -28,7 +28,6 @@ stop_pid_file() {
}
stop_pid_file "$artifact_dir/logcat.pid"
stop_pid_file "$artifact_dir/metro.pid"
stop_pid_file "$artifact_dir/mock-server.pid"
stop_pid_file "$artifact_dir/emulator.pid"
+1 -12
View File
@@ -53,7 +53,7 @@ stop_pid_file() {
pid="$(cat "$pid_file")"
[[ -n "$pid" ]] || return 0
# pnpm and Expo both spawn multiple generations of children.
# pnpm can spawn multiple generations of children.
stop_process_tree "$pid"
}
@@ -61,7 +61,6 @@ stop_pid_file() {
cleanup() {
set +e
stop_pid_file "$artifact_dir/logcat.pid"
stop_pid_file "$artifact_dir/metro.pid"
stop_pid_file "$artifact_dir/mock-server.pid"
if [[ "$platform" == "ios" ]]; then
@@ -134,19 +133,9 @@ fi
printf '%s\n' "$!" >"$artifact_dir/mock-server.pid"
wait_for_port 1986 "the E2E mock-server manager"
phase "Starting Metro"
EXPO_PUBLIC_ENV=e2e \
NODE_ENV=test \
RN_SRC_EXT=e2e.ts,e2e.tsx \
pnpm exec expo start --dev-client --clear --port 8081 \
>"$artifact_dir/metro.log" 2>&1 &
printf '%s\n' "$!" >"$artifact_dir/metro.pid"
wait_for_port 8081 "Metro"
if [[ "$platform" == "android" ]]; then
phase "Configuring Android localhost routing"
adb -s "$device_id" reverse tcp:3000 tcp:3000
adb -s "$device_id" reverse tcp:8081 tcp:8081
fi
phase "Running Maestro flows"
+8 -8
View File
@@ -117,10 +117,10 @@ jobs:
xcrun simctl bootstatus "$udid" -b
echo "Using $device_name on $runtime_name ($udid)"
- name: Mark iOS development client build phase
run: echo "Building the iOS development client" > artifacts/ios/phase.txt
- name: Mark iOS E2E app build phase
run: echo "Building the iOS E2E app" > artifacts/ios/phase.txt
- name: Build iOS development client
- name: Build iOS E2E app
uses: ./.github/actions/eas-local-build
with:
platform: ios
@@ -128,7 +128,7 @@ jobs:
output: ${{ runner.temp }}/nightly-e2e-ios.tar.gz
log-path: artifacts/ios/build.log
- name: Install iOS development client
- name: Install iOS E2E app
run: |
build_contents="$RUNNER_TEMP/nightly-e2e-ios-build"
mkdir -p "$build_contents"
@@ -275,10 +275,10 @@ jobs:
adb -s emulator-5554 shell settings put global transition_animation_scale 0
adb -s emulator-5554 shell settings put global animator_duration_scale 0
- name: Mark Android development client build phase
run: echo "Building the Android development client" > artifacts/android/phase.txt
- name: Mark Android E2E app build phase
run: echo "Building the Android E2E app" > artifacts/android/phase.txt
- name: Build Android development client
- name: Build Android E2E app
uses: ./.github/actions/eas-local-build
with:
platform: android
@@ -286,7 +286,7 @@ jobs:
output: ${{ runner.temp }}/nightly-e2e-android.apk
log-path: artifacts/android/build.log
- name: Install Android development client
- name: Install Android E2E app
run: |
adb -s emulator-5554 install -r "$RUNNER_TEMP/nightly-e2e-android.apk" \
2>&1 | tee -a artifacts/android/build.log