Added maestro tests - #210
Draft
ignaciosantise wants to merge 52 commits into
Draft
Conversation
Naughtyknucks
approved these changes
Sep 12, 2025
There was a problem hiding this comment.
Pull Request Overview
This PR adds Maestro end-to-end testing infrastructure to automate testing between dapp and wallet applications. The changes include improved test reliability through testID additions, updated package dependencies, and comprehensive GitHub Actions workflows for both iOS and Android platforms.
- Added testID props to ActionButton component and ModalFooter for reliable test element identification
- Updated package dependencies across multiple dapp projects to newer versions
- Created comprehensive GitHub Actions workflows for building and testing both iOS and Android applications with Maestro
Reviewed Changes
Copilot reviewed 28 out of 36 changed files in this pull request and generated 1 comment.
Show a summary per file
| File | Description |
|---|---|
| wallets/rn_cli_wallet/src/components/ActionButton.tsx | Added testID prop to ActionButton component for test automation |
| wallets/rn_cli_wallet/src/components/Modal/ModalFooter.tsx | Added testID attributes to approve and reject buttons |
| wallets/rn_cli_wallet/src/screens/Scan/index.tsx | Fixed null check comparison for device variable |
| dapps/W3MWagmi/scripts/misc_internal.ts | Temporarily disabled linkMode with TODO comment |
| dapps/W3MWagmi/package.json | Updated multiple package versions including appkit and walletconnect dependencies |
| dapps/W3MEthers5/package.json | Updated appkit and walletconnect package versions |
| dapps/W3MEthers/package.json | Updated appkit and walletconnect package versions |
| .maestro/web/*.yaml | Enhanced test flows with testID-based element selection and improved timing |
| .maestro/native/*.yaml | Enhanced test flows with testID-based element selection and platform-specific handling |
| .github/workflows/ci_e2e_tests_ios.yaml | Created comprehensive iOS E2E testing workflow with app building and Maestro testing |
| .github/workflows/ci_e2e_tests_android.yaml | Created comprehensive Android E2E testing workflow with emulator setup and testing |
| .github/workflows/release-*.yaml | Updated action versions and refactored file setup into reusable actions |
| .github/actions/ci-setup*/action.yml | Created reusable actions for iOS and Android file setup, updated cache versions |
Tip: Customize your code reviews with copilot-instructions.md. Create the file or learn how to get started.
Naughtyknucks
approved these changes
Oct 15, 2025
ignaciosantise
marked this pull request as draft
October 28, 2025 11:54
- Add pull_request triggers with path filters so E2E tests only run on relevant changes - Explicitly disable iOS code signing (CODE_SIGNING_ALLOWED=NO) - Add SENTRY_DISABLE_AUTO_UPLOAD for iOS builds - Simplify Android test script (remove verbose debug, unnecessary sleeps) - Remove commented-out code, fix artifact upload conditions Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
# Conflicts: # .github/actions/ci-setup/action.yml # .github/workflows/release-android-base.yaml # .github/workflows/release-ios-base.yaml # dapps/W3MEthers/ios/Podfile.lock # dapps/W3MEthers/package.json # dapps/W3MEthers/yarn.lock # dapps/W3MEthers5/ios/Podfile.lock # dapps/W3MEthers5/package.json # dapps/W3MEthers5/yarn.lock # dapps/W3MWagmi/ios/Podfile.lock # dapps/W3MWagmi/package.json # dapps/W3MWagmi/scripts/misc_internal.ts # dapps/W3MWagmi/yarn.lock # wallets/rn_cli_wallet/android/build.gradle # wallets/rn_cli_wallet/ios/Podfile.lock # wallets/rn_cli_wallet/ios/RNWeb3Wallet.xcodeproj/project.pbxproj # wallets/rn_cli_wallet/package.json # wallets/rn_cli_wallet/src/components/ActionButton.tsx # wallets/rn_cli_wallet/src/components/Modal/ModalFooter.tsx # wallets/rn_cli_wallet/src/screens/Scan/index.tsx # wallets/rn_cli_wallet/yarn.lock
|
The latest updates on your projects. Learn more about Vercel for GitHub.
|
# Conflicts: # .github/workflows/ci_e2e_tests_ios.yaml # wallets/rn_cli_wallet/src/components/ActionButton.tsx
… suite Cross-app WalletConnect relay E2E between appkit-wagmi and rn_cli_wallet, separate from the WC Pay E2E. Named by the SDK under test: - relay-walletkit: native rn_cli_wallet vs deployed appkit web dapp - relay-appkit: native appkit-wagmi vs deployed rn_cli_wallet web Each drives the native app + its web counterparty in the device browser in one Maestro flow. Covers connect, sign, switch chain, sign on another chain, disconnect (both sides), and session restore. Adds: - .maestro/relay/ flows + per-SDK _connect subflows (relay-appkit bridges the wc: URI via AppKit copy-to-clipboard -> wallet button-paste-url, since a native dapp can't deep-link a web wallet). - .github/workflows/ci_e2e_relay.yaml (walletkit android/ios + appkit android; appkit ios dispatch-only/unverified). Daily cron + PR + dispatch. - testIDs: wallet session-item, session-disconnect-button; dapp dapp-connected, connected-address, connected-chain, sign-result. Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
- android-emulator-runner `script:` doesn't honor backslash line-continuations (leaked a literal "\" as the flow path -> "Flow path does not exist"); collapse both android maestro invocations to a single line, matching the walletkit composite. - appkit android Build APK: run gradlew app:assembleInternal --stacktrace to surface the config-time `node` exec failure (default lifecycle log swallows its stderr). Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
The relay suite now runs the native rn_cli_wallet (app under test) against the appkit-wagmi WEB dapp in the device browser, driven by one Maestro flow. 7/7 flows (connect / sign / switch-chain / sign-other-chain / disconnect x2 / restore) pass locally on the iOS simulator. Key mechanics for same-device web<->native on the simulator: - Connect via the dapp's QR "Copy link" (Web Clipboard API) -> the native wallet's paste-URL button; return to the dapp by RESUMING the browser (Home + app icon), not relaunching, so the live client receives the queued session settlement. - Dapp actions/asserts matched by TEXT (Safari webview doesn't expose testIDs); wallet by testID. Cross-app browser return extracted to a platform-aware `_focus_browser` subflow (iOS Safari validated; Android Chrome best-effort). Dapp (appkit-wagmi) changes, all TEST_MODE-gated / web-only: - OpenQrButton: `open-qr` (open QR view directly), `Switch to Polygon (E2E)`, `Disconnect (E2E)` — text-matchable substitutes for AppKit controls that aren't driveable on web (icon-only / not testID-matchable in Safari). - clipboardClient uses the Web Clipboard API on web (the native lib no-ops). - SIWX defaults off in TEST_MODE (otherwise it gates every connect on a SIWE sig). - metadata redirect -> window.location.origin on web (was lab.reown.com, so the wallet never returned to our dapp). - WalletInfoView gated on isConnected; `Chain: X` rendered as one text node. CI (ci_e2e_relay.yaml): reworked to the web model — build the wallet natively and serve the appkit dapp as a static web export from source (no native appkit build). iOS job runs on PR/schedule/dispatch; Android job is dispatch-only + UNVERIFIED (Chrome return + 10.0.2.2 need emulator validation). Removed the relay-appkit (mirror) flows — relay is covered by native wallet -> web appkit. Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
… return
Validated the relay-walletkit suite on the Android emulator (native wallet <->
web appkit dapp). Two Android-specific requirements found and applied:
- _focus_browser: return to the browser via Home + tap Chrome (resumes the tab),
not the Back button — the wallet's own navigation consumes Back instead of
returning to Chrome.
- ci_e2e_relay Android job: `adb reverse tcp:8081` + DAPP_URL=http://localhost:8081
(not 10.0.2.2). Chrome only allows the dapp's navigator.clipboard.writeText
("Copy link") from a secure context, which localhost satisfies and 10.0.2.2
does not.
Status: iOS is the validated CI platform (7/7). On Android, connect / switch /
sign_other_chain / disconnect (both) / restore pass; `sign` is still flaky due to
Chrome localStorage persisting across flows in a suite run (a prior flow's
session/chain leaks in). The Android job stays dispatch-only + UNVERIFIED until
per-flow browser-state isolation is added.
Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Added github actions to run maestro tests between dapp and wallet