Skip to content

Commit 3106999

Browse files
committed
test(expo): archive native-auth-driven flows to flows/native-side/
Move the flows whose primary act is driving the native auth/profile UI (email-password, sign-in-sign-out-sign-in, sign-out-from-profile, google-sso, open-profile-modal) to flows/native-side/, excluded from the runners + CI the same way flows/common/ is. They duplicate clerk-ios/clerk-android native coverage and were the main source of flakiness. The Expo automated suite now targets only bridge/config concerns: mount (cold-launch), theming light+dark (config plugin), token-cache persistence, and the Android AuthView bridge regression. See flows/native-side/README.md.
1 parent 2f45f9a commit 3106999

10 files changed

Lines changed: 40 additions & 6 deletions

File tree

.github/workflows/mobile-e2e.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -592,7 +592,7 @@ jobs:
592592
pattern="$(echo "$excluded" | sed 's/,/|/g')" &&
593593
( maestro test --flatten-debug-output flows/common/_warmup.yaml || true ) &&
594594
( adb shell am force-stop com.clerk.clerkexpoquickstart 2>/dev/null || true ) &&
595-
find flows -type f -name '*.yaml' ! -path '*/common/*' ${FLOWS_FILTER:+-path "*$FLOWS_FILTER*"}
595+
find flows -type f -name '*.yaml' ! -path '*/common/*' ! -path '*/native-side/*' ${FLOWS_FILTER:+-path "*$FLOWS_FILTER*"}
596596
| sort
597597
| while read f; do grep -qE "^[[:space:]]*-[[:space:]]*(${pattern})[[:space:]]*$" "$f" || printf '%s\n' "$f"; done
598598
| xargs -n 1 -I FLOW bash -c 'flow="$1"; for a in 1 2; do if maestro test --env CLERK_TEST_EMAIL="$CLERK_TEST_EMAIL" --env CLERK_TEST_PASSWORD="$CLERK_TEST_PASSWORD" --flatten-debug-output "$flow"; then exit 0; fi; if [ "$a" -eq 2 ]; then echo "::error::Flow $flow failed after 2 attempts"; exit 1; fi; echo "::warning::Flow $flow failed attempt $a, retrying after 10s..."; adb shell am force-stop com.clerk.clerkexpoquickstart >/dev/null 2>&1 || true; sleep 10; done' _ FLOW
@@ -1008,7 +1008,7 @@ jobs:
10081008
# quirk is easy to reproduce.
10091009
excluded="$EXCLUDE_TAGS,androidOnly"
10101010
pattern="$(echo "$excluded" | sed 's/,/|/g')"
1011-
find flows -type f -name '*.yaml' ! -path '*/common/*' \
1011+
find flows -type f -name '*.yaml' ! -path '*/common/*' ! -path '*/native-side/*' \
10121012
${FLOWS_FILTER:+-path "*$FLOWS_FILTER*"} | sort | \
10131013
while IFS= read -r f; do
10141014
if grep -qE "^[[:space:]]*-[[:space:]]*(${pattern})[[:space:]]*\$" "$f"; then
Lines changed: 32 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,32 @@
1+
# native-side flows (archived — not run by the Expo e2e suite)
2+
3+
These Maestro flows are **intentionally excluded** from the `@clerk/expo` e2e
4+
run. The runners (`run-ios.sh`, `run-android.sh`, `run-regressions.sh`) and the
5+
CI workflow (`.github/workflows/mobile-e2e.yml`) skip `flows/native-side/*` the
6+
same way they skip `flows/common/*`.
7+
8+
## Why
9+
10+
The Expo e2e suite's job is the **bridge / integration layer** — the parts the
11+
native SDKs can't see: config-plugin codegen (theming), native↔JS event
12+
plumbing, view-factory mounting, and token-cache persistence.
13+
14+
The flows in here are primarily **exercising the native auth/profile UI**
15+
driving the sign-in form to completion, the sign-in→sign-out→sign-in cycle,
16+
signing out from inside the native profile modal, the native OAuth button, and
17+
opening the native profile modal. That behavior is owned and tested by the
18+
native SDK suites (clerk-ios / clerk-android). Running them here duplicated that
19+
coverage and was the main source of flakiness (they lean hardest on native UI
20+
timing).
21+
22+
They're kept (not deleted) for reference and as a starting point if any of this
23+
coverage needs to be ported to the native repos.
24+
25+
## What still runs in the Expo suite
26+
27+
- `smoke/cold-launch-no-flash` — bridge mounts the AuthView (no white flash)
28+
- `theming/custom-theme-applied` + `theming/dark-mode-applied` — config plugin
29+
delivers the theme to the rendered native component
30+
- `session/persists-across-restart` — token-cache (expo-secure-store) rehydrates
31+
the session across a cold restart (sign-in here is setup, not the assertion)
32+
- `sign-in/get-help-loop-regression` — Android `<AuthView>` bridge nav regression

integration/mobile/flows/sign-in/email-password.yaml renamed to integration/mobile/flows/native-side/email-password.yaml

File renamed without changes.

integration/mobile/flows/sign-in/google-sso-from-forgot-password.yaml renamed to integration/mobile/flows/native-side/google-sso-from-forgot-password.yaml

File renamed without changes.

integration/mobile/flows/profile/open-profile-modal.yaml renamed to integration/mobile/flows/native-side/open-profile-modal.yaml

File renamed without changes.

integration/mobile/flows/cycles/sign-in-sign-out-sign-in.yaml renamed to integration/mobile/flows/native-side/sign-in-sign-out-sign-in.yaml

File renamed without changes.

integration/mobile/flows/profile/sign-out-from-profile.yaml renamed to integration/mobile/flows/native-side/sign-out-from-profile.yaml

File renamed without changes.

integration/mobile/scripts/run-android.sh

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -23,7 +23,7 @@ echo "==> Running all non-manual flows on Android..."
2323
ALL_FLOWS=()
2424
while IFS= read -r f; do
2525
ALL_FLOWS+=("$f")
26-
done < <(find "$FLOWS_DIR" -type f -name "*.yaml" ! -path "*/common/*")
26+
done < <(find "$FLOWS_DIR" -type f -name "*.yaml" ! -path "*/common/*" ! -path "*/native-side/*")
2727

2828
# Maestro's --exclude-tags is a no-op when explicit file paths are passed,
2929
# so pre-filter the list ourselves before handing it off.

integration/mobile/scripts/run-ios.sh

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -25,7 +25,7 @@ echo "==> Running all non-manual flows on iOS..."
2525
ALL_FLOWS=()
2626
while IFS= read -r f; do
2727
ALL_FLOWS+=("$f")
28-
done < <(find "$FLOWS_DIR" -type f -name "*.yaml" ! -path "*/common/*")
28+
done < <(find "$FLOWS_DIR" -type f -name "*.yaml" ! -path "*/common/*" ! -path "*/native-side/*")
2929

3030
# Maestro's --exclude-tags is a no-op when explicit file paths are passed,
3131
# so pre-filter the list ourselves before handing it off. See

integration/mobile/scripts/run-regressions.sh

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -9,10 +9,12 @@ PLATFORM="${1:-both}"
99
# shellcheck disable=SC1091
1010
source "$SCRIPT_DIR/lib/filter-flows.sh"
1111

12+
# Note: google-sso-from-forgot-password and sign-in-sign-out-sign-in were moved
13+
# to flows/native-side/ (they primarily exercise native auth UI, which the
14+
# clerk-ios/clerk-android suites own). They no longer run as part of the Expo
15+
# regression set. See flows/native-side/README.md.
1216
REGRESSION_FLOWS=(
13-
"$FLOWS_DIR/sign-in/google-sso-from-forgot-password.yaml"
1417
"$FLOWS_DIR/sign-in/get-help-loop-regression.yaml"
15-
"$FLOWS_DIR/cycles/sign-in-sign-out-sign-in.yaml"
1618
"$FLOWS_DIR/theming/custom-theme-applied.yaml"
1719
"$FLOWS_DIR/smoke/cold-launch-no-flash.yaml"
1820
)

0 commit comments

Comments
 (0)