feat: add QR sync SRP e2e inject path and SmokeAccounts specs#33238
feat: add QR sync SRP e2e inject path and SmokeAccounts specs#33238grvgoel81 wants to merge 7 commits into
Conversation
Add HAS_TEST_OVERRIDES sync-ready injection, page objects/flows, and new/existing user Detox smoke coverage for mobile↔extension QR account sync. Co-authored-by: Cursor <cursoragent@cursor.com>
|
CLA Signature Action: All authors have signed the CLA. You may need to manually re-run the blocking PR check if it doesn't pass in a few minutes. |
PR template — items to address before "Ready for review"Warnings — informational, address before merging:
See docs/readme/ready-for-review.md for the full Definition of Ready for Review. |
There was a problem hiding this comment.
Cursor Bugbot has reviewed your changes and found 1 potential issue.
❌ Bugbot Autofix is OFF. To automatically fix reported issues with cloud agents, have a team admin enable autofix in the Cursor dashboard.
Reviewed by Cursor Bugbot for commit 0fc0cf5. Configure here.
Codecov Report❌ Patch coverage is Additional details and impacted files@@ Coverage Diff @@
## main #33238 +/- ##
==========================================
+ Coverage 84.37% 84.41% +0.04%
==========================================
Files 6127 6136 +9
Lines 163530 163894 +364
Branches 39887 40012 +125
==========================================
+ Hits 137974 138351 +377
- Misses 16050 16051 +1
+ Partials 9506 9492 -14 ☔ View full report in Codecov by Harness. 🚀 New features to boost your workflow:
|
🧪 Flaky unit test detectionRun history flaky detectionHistorical failure rate is a hint, not proof — review each suggestion in context. See the flaky-test-detection skill for the full pattern reference and manual audit workflow. Failures / runs sampled per window:
AI-detected flaky patterns
|
🔍 Smart E2E Test Selection
click to see 🤖 AI reasoning detailsE2E Test Selection: The PR introduces QR sync SRP import functionality for E2E testing, with the following key changes:
App code changes analyzed:
Test infrastructure changes:
No other smoke tags are impacted — the changes are scoped to QR sync/SRP import flows, onboarding, and account management. No confirmations, swaps, browser, snaps, or network changes are involved. Performance Test Selection: |
|




Description
Description
Adds Appium smoke coverage for mobile ↔ extension QR account sync (SRP) for new-user and existing-user flows.
Real MWP pairing is impractical in CI, so this PR adds a
HAS_TEST_OVERRIDES-gated inject path:applyQrSyncSyncReady) while the Add Device screen is mounted (more reliable than warm-session deep links). A deep-link bridge (e2e://qr-sync/apply-sync-ready?.../metamask://e2e/qr-sync/...) remains as a fallback.tests/smoke-appium/seedless/qr-sync-srp.spec.ts(SmokeSeedlessOnboarding) and cover new-user onboarding and existing-user “link extension” paths withaddDeviceSyncEnabledmocked on.waitForWalletHomePlaywright) after inject / onboarding.Changelog
CHANGELOG entry: null
Related issues
Refs: https://consensyssoftware.atlassian.net/browse/TO-810, https://consensyssoftware.atlassian.net/browse/TO-881
Manual testing steps
Screenshots/Recordings
Before
After
Pre-merge author checklist
Performance checks (if applicable)
trace()for usage andaddTokenfor an exampleFor performance guidelines and tooling, see the Performance Guide.
Pre-merge reviewer checklist
Note
Medium Risk
E2E bridge accepts plaintext mnemonics via deep links but is gated to test builds; it still touches wallet import state and must not ship enabled in production.
Overview
Adds an E2E-only path to exercise mobile↔extension QR account sync without MWP pairing, plus Detox/Appium smoke tests for new and existing users.
When
HAS_TEST_OVERRIDESis on,QrSyncController.applyTestSyncReadyPayloadseedsawaiting_password/ pending SRP state as ifsync-readyarrived;e2eBridgeQrSynclistens formetamask://e2e/qr-sync/apply-sync-ready(ande2e://qr-sync/...) and is wired fromqr-sync-controller-init. The shared E2E deep-link helper now maps per-scheme prefixes (including newQR_SYNC), not only perps.UI test hooks:
testIDs on Add Device to Wallet and the import-from-extension link. Tests:qr-sync.flow, page objects, andqr-sync-srp.spec(onboarding inject → password → wallet; logged-in add-wallet → second SRP).Reviewed by Cursor Bugbot for commit 0fc0cf5. Configure here.