Skip to content

test: remove offramp-token-amount e2e test covered by unit tests#27033

Open
chrisleewilcox wants to merge 1 commit intomainfrom
MMQA-1520-delete-offramp-token-amount-e2e
Open

test: remove offramp-token-amount e2e test covered by unit tests#27033
chrisleewilcox wants to merge 1 commit intomainfrom
MMQA-1520-delete-offramp-token-amount-e2e

Conversation

@chrisleewilcox
Copy link
Contributor

@chrisleewilcox chrisleewilcox commented Mar 5, 2026

Description

Removes offramp-token-amount.spec.ts e2e test. All behaviors tested in this e2e test are already covered by existing unit tests in BuildQuote.test.tsx.

Coverage mapping:

E2E Behavior Unit Test in BuildQuote.test.tsx
Enter amount via keypad updates the amount input
Quick amount buttons (25%, MAX) updates the amount input with quick amount buttons
MAX capped by gas for native token updates the amount input up to the max considering gas for native asset
Percentage capped by gas (75%, 50%) updates the amount input up to the percentage considering gas
Freshly opened keyboard clears amount clears the amount when the keyboard is freshly opened

This is part of the effort to convert ramps e2e tests to unit/component tests (MMQA-1492).

Why not a separate component-view test?

BuildQuote.test.tsx already is a component-view test — it uses renderScreen() which renders the full BuildQuote component inside a real navigation stack with Redux state. It simulates user interactions via fireEvent.press on keypad buttons, asserts displayed text, and tests quick amount buttons (25%, 50%, 75%, MAX) with gas capping. Creating a separate component-view test would duplicate existing coverage.

Changelog

CHANGELOG entry: null

Related issues

Fixes: MMQA-1520

Manual testing steps

Feature: Offramp token amount test removal

  Scenario: Existing unit tests cover all e2e behaviors
    Given the BuildQuote.test.tsx unit tests exist
    And they cover keypad entry, quick amounts, gas capping, and validation

    When the offramp-token-amount.spec.ts e2e test is removed
    Then no test coverage is lost
    And the unit test suite continues to pass

Screenshots/Recordings

Before

N/A — test removal, not a UI change.

After

N/A — test removal, not a UI change.

Pre-merge author checklist

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.

All behaviors tested in the e2e test (keypad entry, quick amount
buttons, MAX gas capping) are already covered by BuildQuote.test.tsx
unit tests. Removing to reduce e2e test maintenance overhead.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
@chrisleewilcox chrisleewilcox requested a review from a team as a code owner March 5, 2026 01:59
@github-actions
Copy link
Contributor

github-actions bot commented Mar 5, 2026

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.

@metamaskbot metamaskbot added the team-qa QA team label Mar 5, 2026
@github-actions github-actions bot added the size-S label Mar 5, 2026
@github-actions
Copy link
Contributor

github-actions bot commented Mar 5, 2026

🔍 Smart E2E Test Selection

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

E2E Test Selection:
The PR deletes a single E2E test file (tests/smoke/ramps/offramp-token-amount.spec.ts) that was testing off-ramp token amount functionality. This is purely a test file deletion with no changes to application code. The deleted test was tagged with SmokeRamps and tested entering token amounts directly and by percentage in the off-ramp flow. Since no application code is modified, there is no functionality change that needs to be validated by running E2E tests. The deletion is clean with no references to this file elsewhere in the codebase. Other ramps tests (onramp-unified-buy.spec.ts, deeplink-to-buy-flow.spec.ts, deeplink-to-sell-flow.spec.ts) remain intact and unaffected.

Performance Test Selection:
No application code changes were made - only a test file was deleted. There are no changes that could impact app performance, UI rendering, data loading, or any user flows.

View GitHub Actions results

@sonarqubecloud
Copy link

sonarqubecloud bot commented Mar 5, 2026

@chrisleewilcox chrisleewilcox added No QA Needed Apply this label when your PR does not need any QA effort. no-changelog no-changelog Indicates no external facing user changes, therefore no changelog documentation needed labels Mar 5, 2026
@chrisleewilcox chrisleewilcox requested a review from a team March 5, 2026 02:45
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

No QA Needed Apply this label when your PR does not need any QA effort. no-changelog no-changelog Indicates no external facing user changes, therefore no changelog documentation needed size-S team-qa QA team

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants