Skip to content

test: fix rwa swaps#30181

Draft
vivek-consensys wants to merge 3 commits into
mainfrom
test/rwa-e2e-fix
Draft

test: fix rwa swaps#30181
vivek-consensys wants to merge 3 commits into
mainfrom
test/rwa-e2e-fix

Conversation

@vivek-consensys
Copy link
Copy Markdown
Contributor

Description

Changelog

CHANGELOG entry:

Related issues

Fixes:

Manual testing steps

Feature: my feature name

  Scenario: user [verb for user action]
    Given [describe expected initial app state]

    When user [verb for user action]
    Then [describe expected outcome]

Screenshots/Recordings

Before

After

Pre-merge author checklist

Performance checks (if applicable)

  • I've tested on Android
    • Ideally on a mid-range device; emulator is acceptable
  • I've tested with a power user scenario
    • Use these power-user SRPs to import wallets with many accounts and tokens
  • I've instrumented key operations with Sentry traces for production performance metrics

For performance guidelines and tooling, see the Performance Guide.

Pre-merge reviewer checklist

  • I've manually tested the PR (e.g. pull and build branch, run the app, test code being changed).
  • I confirm that this PR addresses all acceptance criteria described in the ticket it closes and includes the necessary testing evidence such as recordings and or screenshots.

@github-actions
Copy link
Copy Markdown
Contributor

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.

@metamaskbotv2 metamaskbotv2 Bot added the team-be-trade BE Trade team label May 14, 2026
@github-actions github-actions Bot added size-M and removed size-S labels May 14, 2026
@github-actions
Copy link
Copy Markdown
Contributor

🔍 Smart E2E Test Selection

  • Selected E2E tags: SmokeSwap, SmokeConfirmations
  • Selected Performance tags: None (no tests recommended)
  • Risk Level: low
  • AI Confidence: 88%
click to see 🤖 AI reasoning details

E2E Test Selection:
All three changed files are test infrastructure files only — no app source code is modified.

  1. tests/regression/swap/swap-token-rwa.spec.ts: Regression test for USDC→GOOGLON (RWA token) swap. Changes increase the timeout from 120s to 180s and reduce the swap quantity from 1000 to 25 USDC to match updated mock data.

  2. tests/helpers/swap/constants.ts: Updates mock API response data to reflect the current CoW Protocol intent-based swap flow — updated quote amounts, requestId, aggregator lists, and adds new constants for POST_SUBMIT_ORDER and GET_ORDER_STATUS endpoints.

  3. tests/helpers/swap/swap-mocks.ts: Updates mock setup to wire in the new submitOrder POST mock and getOrderStatus GET mock, replacing the old getQuote JSON mock. This reflects the RWA swap now using an intent-based (CoW Protocol) order flow rather than a direct quote.

The swap-mocks.ts helper is also imported by smoke swap tests (swap-action-smoke, gasless-swap, swap-deeplink-smoke, swap-trending-tokens, unified-ui-wallet-actions), but the changes only ADD new mock endpoints without removing or modifying existing ones used by those tests — so they should not be broken.

SmokeSwap is selected as the primary tag since these changes directly affect swap test infrastructure and mock data. SmokeConfirmations is selected per the SmokeSwap tag description (swap flows involve transaction confirmations). No other tags are warranted as the changes are isolated to swap test helpers.

The RegressionTrade: tag (which directly covers these regression swap tests) is not in the available E2E smoke tags list, so SmokeSwap is the best proxy.

Performance Test Selection:
All changes are confined to test infrastructure files (mock data, test spec). No app source code, UI components, state management, or performance-sensitive paths are modified. Performance tests are not warranted.

View GitHub Actions results

@sonarqubecloud
Copy link
Copy Markdown

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants