Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
47 commits
Select commit Hold shift + click to select a range
f9896f6
introduce initial maestro flow
achou11 Apr 30, 2026
4fa4528
record test
achou11 Apr 30, 2026
b4ea31b
update app id used in test
achou11 May 4, 2026
b4ddadc
rename maestro flow
achou11 May 4, 2026
9ca36be
wip workflow
achou11 May 5, 2026
bafab2b
specify maestro version to use
achou11 May 5, 2026
d38fb7a
remove stopRecording command
achou11 May 5, 2026
ab12dde
simplify test jobs
achou11 May 5, 2026
2571dfa
allow test suite upload to happen immediately
achou11 May 5, 2026
1135e42
minor cleanup
achou11 May 5, 2026
a8ffdcd
fix test-android env
achou11 May 7, 2026
afadca4
add polling for result step
achou11 May 7, 2026
eb5cf3c
update secrets and vars names
achou11 May 7, 2026
ea4303c
fix missing npm install step for build-ios
achou11 May 7, 2026
2ff9c2a
fix e2e app setup step for build-ios
achou11 May 7, 2026
e8ab704
rename flow file
achou11 May 7, 2026
1762251
maybe fix -F curl usage
achou11 May 7, 2026
4c6bcd1
fix build-android
achou11 May 7, 2026
e5fe3ff
improve curl calls
achou11 May 7, 2026
101e0ce
fix upload step in build-ios
achou11 May 7, 2026
6254152
add commented out needs spec to upload-test-suite
achou11 May 7, 2026
3dbcd6c
rename zip file used for upload
achou11 May 7, 2026
93c6f61
curl fixes
achou11 May 7, 2026
b01826b
fix caching of nodejs-mobile for ios
achou11 May 7, 2026
0d72bc1
minor fixup
achou11 May 7, 2026
44335e7
limit devices used due to browserstack plan limitations
achou11 May 7, 2026
f9cebcf
browserstack project adjustements
achou11 May 7, 2026
490d6f7
fix url used when executing build
achou11 May 7, 2026
ec186be
fix dumb mistake
achou11 May 7, 2026
fd2ee69
update devices
achou11 May 7, 2026
557529e
increase timeout for flow in CI
achou11 May 7, 2026
f9a6b47
fix timeout interpolation
achou11 May 7, 2026
4b7fe32
stick with (larger) hardcoded timeout for now
achou11 May 7, 2026
132f414
remove startRecording command
achou11 May 7, 2026
d8c6387
Merge branch 'main' into e2e-maestro
gmaclennan May 19, 2026
f4d47e8
stop browserstack build/tests on workflow cancel
gmaclennan May 19, 2026
8545120
fix cache step ID
gmaclennan May 19, 2026
2430a78
fix(e2e): raise jasmine timeout, close projects, surface done signal
gmaclennan May 19, 2026
749a791
ci(e2e): drop --ignore-scripts so root prepare runs
gmaclennan May 19, 2026
d532088
fix: fix Android 8.1 crash by overriding sodium-native v5
gmaclennan Jun 10, 2026
8012789
fix(e2e): add BUILD_LIBRARY_FOR_DISTRIBUTION to Sentry pods for Xcode…
Copilot Jun 10, 2026
8155aa2
Revert "fix(e2e): add BUILD_LIBRARY_FOR_DISTRIBUTION to Sentry pods f…
gmaclennan Jun 10, 2026
92618bf
fix: remove Oppo device from e2e tests
gmaclennan Jun 10, 2026
378fe89
Merge remote-tracking branch 'origin/main' into e2e-maestro
gmaclennan Jun 10, 2026
401f682
fix(build): don't drop overridden packages when collecting native mod…
gmaclennan Jun 10, 2026
f52ed59
fix(ios): build Sentry pods with library evolution for Xcode 26
gmaclennan Jun 10, 2026
7758fda
fix(ci): cache android/libnode in the iOS build job too
gmaclennan Jun 10, 2026
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
130 changes: 130 additions & 0 deletions .github/actions/run-browserstack-maestro/action.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,130 @@
name: Run BrowserStack Maestro Tests

description: Triggers a BrowserStack Maestro build and polls until completion

inputs:
platform:
description: Platform to run tests on (android or ios)
required: true
app_url:
description: BrowserStack app URL (bs://...)
required: true
test_suite_url:
description: BrowserStack test suite URL (bs://...)
required: true
devices:
description: JSON array of device strings
required: true
browserstack_project:
description: BrowserStack project
required: true
browserstack_username:
description: BrowserStack username
required: true
browserstack_access_key:
description: BrowserStack access key
required: true
timeout:
description: Test run timeout in seconds
required: false
default: "600"

runs:
using: composite
steps:
- name: Validate inputs
env:
PLATFORM: ${{ inputs.platform }}
TIMEOUT: ${{ fromJson(inputs.timeout) }}
shell: bash
run: |
if [[ "$PLATFORM" != "android" && "$PLATFORM" != "ios" ]]; then
echo "platform must be android or ios"
exit 1
fi

if [[ "$TIMEOUT" -lt 30 ]]; then
echo "timeout must be at least 30 seconds"
exit 1
fi

- name: Trigger build
id: trigger
env:
APP_URL: ${{ inputs.app_url }}
TEST_SUITE_URL: ${{ inputs.test_suite_url }}
DEVICES: ${{ inputs.devices }}
BROWSERSTACK_PROJECT: ${{ inputs.browserstack_project }}
BROWSERSTACK_USERNAME: ${{ inputs.browserstack_username }}
BROWSERSTACK_ACCESS_KEY: ${{ inputs.browserstack_access_key }}
PLATFORM: ${{ inputs.platform }}
shell: bash
run: |
PAYLOAD=$(jq -n \
--arg app "$APP_URL" \
--arg suite "$TEST_SUITE_URL" \
--argjson devices "$DEVICES" \
--arg project "$BROWSERSTACK_PROJECT" \
'{
app: $app,
testSuite: $suite,
devices: $devices,
project: $project,
deviceLogs: true,
maestroVersion: "latest"
}'
)

BUILD_ID=$(curl --fail --show-error -s -u "$BROWSERSTACK_USERNAME:$BROWSERSTACK_ACCESS_KEY" \
-X POST "https://api-cloud.browserstack.com/app-automate/maestro/v2/$PLATFORM/build" \
-H "Content-Type: application/json" \
-d "$PAYLOAD" \
| jq -r '.build_id')

echo "Triggered build: $BUILD_ID"
echo "build_id=$BUILD_ID" >> $GITHUB_OUTPUT

- name: Poll for result
env:
BUILD_ID: ${{ steps.trigger.outputs.build_id }}
BROWSERSTACK_USERNAME: ${{ inputs.browserstack_username }}
BROWSERSTACK_ACCESS_KEY: ${{ inputs.browserstack_access_key }}
TIMEOUT: ${{ fromJson(inputs.timeout) }}
shell: bash
run: |
MAX_WAIT=$TIMEOUT
POLL_INTERVAL=30
ELAPSED=0

while [ "$ELAPSED" -lt "$MAX_WAIT" ]; do
RESPONSE=$(curl --fail --show-error -s -u "$BROWSERSTACK_USERNAME:$BROWSERSTACK_ACCESS_KEY" \
"https://api-cloud.browserstack.com/app-automate/maestro/v2/builds/$BUILD_ID")

STATUS=$(echo "$RESPONSE" | jq -r '.status')
echo "[${ELAPSED}s] Build $BUILD_ID status: $STATUS"

case "$STATUS" in
passed|completed) echo "Tests passed"; exit 0 ;;
failed) echo "Tests failed"; exit 1 ;;
esac

sleep "$POLL_INTERVAL"
ELAPSED=$((ELAPSED + POLL_INTERVAL))
done

echo "Timed out after ${MAX_WAIT}s waiting for build $BUILD_ID"
exit 1

- name: Stop BrowserStack build on cancel
if: cancelled() && steps.trigger.outputs.build_id != ''
env:
BUILD_ID: ${{ steps.trigger.outputs.build_id }}
BROWSERSTACK_USERNAME: ${{ inputs.browserstack_username }}
BROWSERSTACK_ACCESS_KEY: ${{ inputs.browserstack_access_key }}
shell: bash
run: |
[[ "$BUILD_ID" == "null" ]] && exit 0
echo "Stopping BrowserStack build $BUILD_ID"
curl --show-error -s -u "$BROWSERSTACK_USERNAME:$BROWSERSTACK_ACCESS_KEY" \
-X POST "https://api-cloud.browserstack.com/app-automate/maestro/builds/$BUILD_ID/stop" \
-H "Content-Type: application/json" || true
Loading
Loading