Skip to content

Conversation

@dawnseeker8
Copy link
Contributor

@dawnseeker8 dawnseeker8 commented Aug 28, 2025

Description

This PR implemented a e2e tests for Ledger forget device features.

Open in GitHub Codespaces

Changelog

CHANGELOG entry:

Related issues

Fixes:

Manual testing steps

  1. Go to this page...

Screenshots/Recordings

Before

After

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.

dawnseeker8 and others added 5 commits August 28, 2025 06:30
…ec.ts

Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
…ec.ts

Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
Remove the unusaed imports in trezor-forget-device.spec.ts
@dawnseeker8 dawnseeker8 requested a review from a team as a code owner August 28, 2025 07:53
@dawnseeker8 dawnseeker8 added team-accounts-framework Accounts Framework team team-hardware-wallets-deprecated DEPRECATED: please use "team-accounts-framework" instead e2e-test End to end test for the MetaMask extension labels Aug 28, 2025
@dawnseeker8 dawnseeker8 marked this pull request as draft August 28, 2025 07:53
@github-actions
Copy link
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.

cursor[bot]

This comment was marked as outdated.

@metamaskbot
Copy link
Collaborator

Builds ready [edea27f]
UI Startup Metrics (1219 ± 64 ms)
PlatformBuildTypePageMetricMean (ms)Min (ms)Max (ms)Std Dev (ms)P 75 (ms)P 95 (ms)
ChromeBrowserifyHomeuiStartup1219107513886412551331
load107394312285511081166
domContentLoaded106694012195510981158
domInteractive18146481739
firstPaint60975122543210681133
backgroundConnect2412272708244256
firstReactRender23174562438
getState14578121630
initialActions40919310
loadScripts83271698655863924
setupStore84294916
WebpackHomeuiStartup20861578268224022042495
load16181213201018417241869
domContentLoaded16121208199918317161856
domInteractive171192141353
firstPaint1586840161174304
backgroundConnect25136192649
firstReactRender1878739492171379
getState3243117511265
initialActions5219258
loadScripts16081206198618217141844
setupStore146295291323
FirefoxBrowserifyHomeuiStartup13411136176612214061528
load1174101613748312281334
domContentLoaded1174101513748312281333
domInteractive1063335248116206
firstPaintNaNNaNNaNNaNNaNNaN
backgroundConnect3318260283266
firstReactRender27225162841
getState7210512518
initialActions30627313
loadScripts1151100113488012041287
setupStore9316918728
WebpackHomeuiStartup15471352200813816141839
load13211154166312413991554
domContentLoaded13201154166212413991553
domInteractive1083639955109256
firstPaintNaNNaNNaNNaNNaNNaN
backgroundConnect28195363236
firstReactRender574610586270
getState722861022
initialActions5110611319
loadScripts12991136164512413781532
setupStore10492101024
Benchmark value 1074 exceeds gate value 1070 for chrome browserify home mean load
Benchmark value 1066 exceeds gate value 1061 for chrome browserify home mean domContentLoaded
Benchmark value 241 exceeds gate value 10 for chrome browserify home mean backgroundConnect
Benchmark value 24 exceeds gate value 23 for chrome browserify home mean firstReactRender
Benchmark value 4 exceeds gate value 1 for chrome browserify home mean initialActions
Benchmark value 833 exceeds gate value 830 for chrome browserify home mean loadScripts
Benchmark value 257 exceeds gate value 18 for chrome browserify home p95 backgroundConnect
Benchmark value 10 exceeds gate value 1.2 for chrome browserify home p95 initialActions
Benchmark value 33 exceeds gate value 29 for chrome webpack home mean getState
Benchmark value 2496 exceeds gate value 2454 for chrome webpack home p95 uiStartup
Benchmark value 379 exceeds gate value 370 for chrome webpack home p95 firstReactRender
Benchmark value 265 exceeds gate value 195 for chrome webpack home p95 getState
Benchmark value 8 exceeds gate value 7 for chrome webpack home p95 initialActions
Benchmark value 33 exceeds gate value 25 for firefox browserify home mean backgroundConnect
Benchmark value 27 exceeds gate value 25 for firefox browserify home mean firstReactRender
Benchmark value 4 exceeds gate value 1 for firefox browserify home mean initialActions
Benchmark value 10 exceeds gate value 9 for firefox browserify home mean setupStore
Benchmark value 206 exceeds gate value 195 for firefox browserify home p95 domInteractive
Benchmark value 13 exceeds gate value 2 for firefox browserify home p95 initialActions
Benchmark value 28 exceeds gate value 27 for firefox browserify home p95 setupStore
Benchmark value 108 exceeds gate value 100 for firefox webpack home mean domInteractive
Benchmark value 29 exceeds gate value 26 for firefox webpack home mean backgroundConnect
Benchmark value 58 exceeds gate value 38 for firefox webpack home mean firstReactRender
Benchmark value 5 exceeds gate value 1 for firefox webpack home mean initialActions
Benchmark value 256 exceeds gate value 156 for firefox webpack home p95 domInteractive
Benchmark value 70 exceeds gate value 50 for firefox webpack home p95 firstReactRender
Benchmark value 19 exceeds gate value 2 for firefox webpack home p95 initialActions
Sum of mean exceeds: 300ms | Sum of p95 exceeds: 529.8ms
Sum of all benchmark exceeds: 829.8ms

Bundle size diffs [🚨 Warning! Bundle size has increased!]
  • background: 232 Bytes (0%)
  • ui: 962 Bytes (0.01%)
  • common: 328 Bytes (0%)

@github-actions github-actions bot added size-S and removed size-M labels Aug 29, 2025
@dawnseeker8 dawnseeker8 marked this pull request as ready for review August 29, 2025 02:32
cursor[bot]

This comment was marked as outdated.

@metamaskbot
Copy link
Collaborator

📊 Page Load Benchmark Results

Current Commit: b050cc5 | Date: 8/29/2025

📄 https://metamask.github.io/test-dapp/

Samples: 100

Summary

  • pageLoadTime-> current mean value: 1.28s (±42ms) 🟡 | historical mean value: 1.31s ⬇️ (historical data)
  • domContentLoaded-> current mean value: 965ms (±22ms) 🟢 | historical mean value: 992ms ⬇️ (historical data)
  • firstContentfulPaint-> current mean value: 87ms (±21ms) 🟢 | historical mean value: 93ms ⬇️ (historical data)
📈 Detailed Results
Metric Mean Std Dev Min Max P95 P99
pageLoadTime 1.28s 42ms 1.25s 1.62s 1.35s 1.62s
domContentLoaded 965ms 22ms 937ms 1.06s 1.02s 1.06s
firstPaint 87ms 21ms 72ms 232ms 132ms 232ms
firstContentfulPaint 87ms 21ms 72ms 232ms 132ms 232ms
largestContentfulPaint 0ms 0ms 0ms 0ms 0ms 0ms

Results generated automatically by MetaMask CI

@metamaskbot
Copy link
Collaborator

Builds ready [622fb3d]
UI Startup Metrics (1192 ± 64 ms)
PlatformBuildTypePageMetricMean (ms)Min (ms)Max (ms)Std Dev (ms)P 75 (ms)P 95 (ms)
ChromeBrowserifyHomeuiStartup1192103313816412301307
load104892812065710751170
domContentLoaded104092211995710671164
domInteractive17134671741
firstPaint71390121841810591150
backgroundConnect2392262617243253
firstReactRender23163842532
getState1058491122
initialActions40679413
loadScripts80970096655835925
setupStore85354814
WebpackHomeuiStartup20751507246522021782411
load16671238197715817581862
domContentLoaded16601234197415617541854
domInteractive171191141451
firstPaint1676246965200277
backgroundConnect2913288282851
firstReactRender109353519297327
getState2643046412270
initialActions7217117710
loadScripts16561232197115517501842
setupStore2663005716252
FirefoxBrowserifyHomeuiStartup13981191183211814641651
load1224105215008912721405
domContentLoaded1224105214998912711405
domInteractive1113332351117230
firstPaintNaNNaNNaNNaNNaNNaN
backgroundConnect3319145193470
firstReactRender28235663046
getState727310517
initialActions30294312
loadScripts1200103414758612461347
setupStore12420823841
WebpackHomeuiStartup15661360208012816371831
load13571169166810914301565
domContentLoaded13571167166810914291565
domInteractive1063332051108271
firstPaintNaNNaNNaNNaNNaNNaN
backgroundConnect30208483346
firstReactRender43325444650
getState62265717
initialActions3025336
loadScripts13351150164611014081542
setupStore114133141128
Benchmark value 239 exceeds gate value 10 for chrome browserify home mean backgroundConnect
Benchmark value 5 exceeds gate value 1 for chrome browserify home mean initialActions
Benchmark value 253 exceeds gate value 18 for chrome browserify home p95 backgroundConnect
Benchmark value 13 exceeds gate value 1.2 for chrome browserify home p95 initialActions
Benchmark value 8 exceeds gate value 7 for chrome webpack home mean initialActions
Benchmark value 270 exceeds gate value 195 for chrome webpack home p95 getState
Benchmark value 10 exceeds gate value 7 for chrome webpack home p95 initialActions
Benchmark value 252 exceeds gate value 65 for chrome webpack home p95 setupStore
Benchmark value 111 exceeds gate value 110 for firefox browserify home mean domInteractive
Benchmark value 33 exceeds gate value 25 for firefox browserify home mean backgroundConnect
Benchmark value 29 exceeds gate value 25 for firefox browserify home mean firstReactRender
Benchmark value 4 exceeds gate value 1 for firefox browserify home mean initialActions
Benchmark value 12 exceeds gate value 9 for firefox browserify home mean setupStore
Benchmark value 230 exceeds gate value 195 for firefox browserify home p95 domInteractive
Benchmark value 12 exceeds gate value 2 for firefox browserify home p95 initialActions
Benchmark value 41 exceeds gate value 27 for firefox browserify home p95 setupStore
Benchmark value 106 exceeds gate value 100 for firefox webpack home mean domInteractive
Benchmark value 30 exceeds gate value 26 for firefox webpack home mean backgroundConnect
Benchmark value 43 exceeds gate value 38 for firefox webpack home mean firstReactRender
Benchmark value 3 exceeds gate value 1 for firefox webpack home mean initialActions
Benchmark value 271 exceeds gate value 156 for firefox webpack home p95 domInteractive
Benchmark value 6 exceeds gate value 2 for firefox webpack home p95 initialActions
Sum of mean exceeds: 270ms | Sum of p95 exceeds: 689.8ms
Sum of all benchmark exceeds: 959.8ms

Bundle size diffs [🚨 Warning! Bundle size has increased!]
  • background: 43 Bytes (0%)
  • ui: 0 Bytes (0%)
  • common: 10 Bytes (0%)

…Page

This commit modifies the `clickContinueButton` method to first wait for the continue button to be visible before clicking it. The updated interaction now ensures that the button is clicked only after it has disappeared, improving the reliability of the user experience.
@metamaskbot
Copy link
Collaborator

✨ Files requiring CODEOWNER review ✨

🧪 @MetaMask/qa (1 files, +2 -1)
  • 📁 test/
    • 📁 e2e/
      • 📁 page-objects/
        • 📁 pages/
          • 📁 hardware-wallet/
            • 📄 connect-hardware-wallet-page.ts +2 -1

@metamaskbot
Copy link
Collaborator

📊 Page Load Benchmark Results

Current Commit: 0d15a19 | Date: 8/29/2025

📄 https://metamask.github.io/test-dapp/

Samples: 100

Summary

  • pageLoadTime-> current mean value: 1.27s (±129ms) 🟡 | historical mean value: 1.31s ⬇️ (historical data)
  • domContentLoaded-> current mean value: 957ms (±65ms) 🟢 | historical mean value: 992ms ⬇️ (historical data)
  • firstContentfulPaint-> current mean value: 84ms (±22ms) 🟢 | historical mean value: 93ms ⬇️ (historical data)
📈 Detailed Results
Metric Mean Std Dev Min Max P95 P99
pageLoadTime 1.27s 129ms 1.24s 2.54s 1.31s 2.54s
domContentLoaded 957ms 65ms 932ms 1.58s 993ms 1.58s
firstPaint 84ms 22ms 68ms 280ms 108ms 280ms
firstContentfulPaint 84ms 22ms 68ms 280ms 108ms 280ms
largestContentfulPaint 0ms 0ms 0ms 0ms 0ms 0ms

Results generated automatically by MetaMask CI

@metamaskbot
Copy link
Collaborator

Builds ready [6b48326]
UI Startup Metrics (1181 ± 60 ms)
PlatformBuildTypePageMetricMean (ms)Min (ms)Max (ms)Std Dev (ms)P 75 (ms)P 95 (ms)
ChromeBrowserifyHomeuiStartup1181105913586012101309
load104092212375810601150
domContentLoaded103391612205810541147
domInteractive17134571640
firstPaint698136122640910501131
backgroundConnect2362232707239251
firstReactRender22164462339
getState1152651420
initialActions30647313
loadScripts80469699157825903
setupStore85172913
WebpackHomeuiStartup20691459253121722112411
load16781204203915317491867
domContentLoaded16721198203215217411864
domInteractive171182131459
firstPaint1666043164189287
backgroundConnect261367102948
firstReactRender103353379087327
getState2642896311264
initialActions62264713
loadScripts16681196202915117351861
setupStore3262986914267
FirefoxBrowserifyHomeuiStartup14141234196112814731667
load1242110315179212991461
domContentLoaded1242110215179212991461
domInteractive1213433553130246
firstPaintNaNNaNNaNNaNNaNNaN
backgroundConnect3117101133362
firstReactRender27225052839
getState7211012519
initialActions5020221211
loadScripts1218108514998912641413
setupStore93518827
WebpackHomeuiStartup15671360197414416531848
load13591160166912214271579
domContentLoaded13591159166912214261579
domInteractive1134238864109276
firstPaintNaNNaNNaNNaNNaNNaN
backgroundConnect3019107103442
firstReactRender41355444448
getState72266724
initialActions31203312
loadScripts13371134164712314081552
setupStore114135141129
Benchmark value 237 exceeds gate value 10 for chrome browserify home mean backgroundConnect
Benchmark value 4 exceeds gate value 1 for chrome browserify home mean initialActions
Benchmark value 252 exceeds gate value 18 for chrome browserify home p95 backgroundConnect
Benchmark value 13 exceeds gate value 1.2 for chrome browserify home p95 initialActions
Benchmark value 60 exceeds gate value 57 for chrome webpack home p95 domInteractive
Benchmark value 264 exceeds gate value 195 for chrome webpack home p95 getState
Benchmark value 13 exceeds gate value 7 for chrome webpack home p95 initialActions
Benchmark value 267 exceeds gate value 65 for chrome webpack home p95 setupStore
Benchmark value 1415 exceeds gate value 1405 for firefox browserify home mean uiStartup
Benchmark value 1242 exceeds gate value 1239 for firefox browserify home mean domContentLoaded
Benchmark value 121 exceeds gate value 110 for firefox browserify home mean domInteractive
Benchmark value 32 exceeds gate value 25 for firefox browserify home mean backgroundConnect
Benchmark value 28 exceeds gate value 25 for firefox browserify home mean firstReactRender
Benchmark value 6 exceeds gate value 1 for firefox browserify home mean initialActions
Benchmark value 1667 exceeds gate value 1660 for firefox browserify home p95 uiStartup
Benchmark value 246 exceeds gate value 195 for firefox browserify home p95 domInteractive
Benchmark value 11 exceeds gate value 2 for firefox browserify home p95 initialActions
Benchmark value 114 exceeds gate value 100 for firefox webpack home mean domInteractive
Benchmark value 30 exceeds gate value 26 for firefox webpack home mean backgroundConnect
Benchmark value 42 exceeds gate value 38 for firefox webpack home mean firstReactRender
Benchmark value 4 exceeds gate value 1 for firefox webpack home mean initialActions
Benchmark value 276 exceeds gate value 156 for firefox webpack home p95 domInteractive
Benchmark value 12 exceeds gate value 2 for firefox webpack home p95 initialActions
Benchmark value 29 exceeds gate value 28 for firefox webpack home p95 setupStore
Sum of mean exceeds: 294ms | Sum of p95 exceeds: 723.8ms
Sum of all benchmark exceeds: 1017.8ms

Bundle size diffs [🚨 Warning! Bundle size has increased!]
  • background: 43 Bytes (0%)
  • ui: 0 Bytes (0%)
  • common: 10 Bytes (0%)

@metamaskbot
Copy link
Collaborator

📊 Page Load Benchmark Results

Current Commit: 84114dd | Date: 8/29/2025

📄 https://metamask.github.io/test-dapp/

Samples: 100

Summary

  • pageLoadTime-> current mean value: 1.28s (±39ms) 🟡 | historical mean value: 1.31s ⬇️ (historical data)
  • domContentLoaded-> current mean value: 960ms (±23ms) 🟢 | historical mean value: 992ms ⬇️ (historical data)
  • firstContentfulPaint-> current mean value: 87ms (±29ms) 🟢 | historical mean value: 93ms ⬇️ (historical data)
📈 Detailed Results
Metric Mean Std Dev Min Max P95 P99
pageLoadTime 1.28s 39ms 1.25s 1.61s 1.33s 1.61s
domContentLoaded 960ms 23ms 940ms 1.12s 1.01s 1.12s
firstPaint 87ms 29ms 64ms 332ms 132ms 332ms
firstContentfulPaint 87ms 29ms 64ms 332ms 132ms 332ms
largestContentfulPaint 0ms 0ms 0ms 0ms 0ms 0ms

Results generated automatically by MetaMask CI

@metamaskbot
Copy link
Collaborator

Builds ready [917bf04]
UI Startup Metrics (1188 ± 61 ms)
PlatformBuildTypePageMetricMean (ms)Min (ms)Max (ms)Std Dev (ms)P 75 (ms)P 95 (ms)
ChromeBrowserifyHomeuiStartup1188106513576112271300
load103889511896510801154
domContentLoaded103188811826510731147
domInteractive18134771642
firstPaint62288119541510491111
backgroundConnect2372242638240255
firstReactRender2416131142338
getState11593101424
initialActions20405210
loadScripts80166795265838919
setupStore85243914
WebpackHomeuiStartup21061516262422522212532
load17041274198416017961942
domContentLoaded16971268197915917861919
domInteractive171294111539
firstPaint1656151172208280
backgroundConnect271485132852
firstReactRender112343399591330
getState3342997413271
initialActions10228732612
loadScripts16931265196615717811907
setupStore217298451626
FirefoxBrowserifyHomeuiStartup13461153181212914151629
load1177103414468212351309
domContentLoaded1177103414468212341309
domInteractive1093428546118202
firstPaintNaNNaNNaNNaNNaNNaN
backgroundConnect3017120163254
firstReactRender26224332833
getState8219520630
initialActions30657312
loadScripts1154101914207912141287
setupStore939012734
WebpackHomeuiStartup16111379211715416771910
load13881179170912314651619
domContentLoaded13871179170912314651619
domInteractive1143131459110306
firstPaintNaNNaNNaNNaNNaNNaN
backgroundConnect31188593543
firstReactRender45369374754
getState82397825
initialActions7124526417
loadScripts13641155169012314431598
setupStore11580111032
Benchmark value 238 exceeds gate value 10 for chrome browserify home mean backgroundConnect
Benchmark value 24 exceeds gate value 23 for chrome browserify home mean firstReactRender
Benchmark value 3 exceeds gate value 1 for chrome browserify home mean initialActions
Benchmark value 42 exceeds gate value 41 for chrome browserify home p95 domInteractive
Benchmark value 256 exceeds gate value 18 for chrome browserify home p95 backgroundConnect
Benchmark value 10 exceeds gate value 1.2 for chrome browserify home p95 initialActions
Benchmark value 34 exceeds gate value 29 for chrome webpack home mean getState
Benchmark value 10 exceeds gate value 7 for chrome webpack home mean initialActions
Benchmark value 2533 exceeds gate value 2454 for chrome webpack home p95 uiStartup
Benchmark value 271 exceeds gate value 195 for chrome webpack home p95 getState
Benchmark value 12 exceeds gate value 7 for chrome webpack home p95 initialActions
Benchmark value 31 exceeds gate value 25 for firefox browserify home mean backgroundConnect
Benchmark value 27 exceeds gate value 25 for firefox browserify home mean firstReactRender
Benchmark value 4 exceeds gate value 1 for firefox browserify home mean initialActions
Benchmark value 202 exceeds gate value 195 for firefox browserify home p95 domInteractive
Benchmark value 30 exceeds gate value 24 for firefox browserify home p95 getState
Benchmark value 12 exceeds gate value 2 for firefox browserify home p95 initialActions
Benchmark value 34 exceeds gate value 27 for firefox browserify home p95 setupStore
Benchmark value 1388 exceeds gate value 1380 for firefox webpack home mean load
Benchmark value 1388 exceeds gate value 1380 for firefox webpack home mean domContentLoaded
Benchmark value 114 exceeds gate value 100 for firefox webpack home mean domInteractive
Benchmark value 31 exceeds gate value 26 for firefox webpack home mean backgroundConnect
Benchmark value 45 exceeds gate value 38 for firefox webpack home mean firstReactRender
Benchmark value 8 exceeds gate value 1 for firefox webpack home mean initialActions
Benchmark value 1365 exceeds gate value 1360 for firefox webpack home mean loadScripts
Benchmark value 306 exceeds gate value 156 for firefox webpack home p95 domInteractive
Benchmark value 54 exceeds gate value 50 for firefox webpack home p95 firstReactRender
Benchmark value 17 exceeds gate value 2 for firefox webpack home p95 initialActions
Benchmark value 32 exceeds gate value 28 for firefox webpack home p95 setupStore
Sum of mean exceeds: 304ms | Sum of p95 exceeds: 610.8ms
Sum of all benchmark exceeds: 914.8ms

Bundle size diffs [🚨 Warning! Bundle size has increased!]
  • background: 43 Bytes (0%)
  • ui: 0 Bytes (0%)
  • common: 10 Bytes (0%)


// if browser is firefox
if (isFirefox) {
await connectHardwareWalletPage.checkFirefoxNotSupportedIsDisplayed();
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Ledger connection screen doesnt support ledger hardware device due to firefox doesnt support HID usb connection.

Copy link
Member

@seaona seaona left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Overall LGTM. I left a non-blocking comment, in case it makes sense and you might carry it over your next work 🙏

await connectHardwareWalletPage.checkPageIsLoaded();
await connectHardwareWalletPage.clickConnectLedgerButton();

// if browser is firefox
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Non blocking: I think a comment explaining why we do this, like the one you added below would be more clarifying:

Ledger connection screen doesnt support ledger hardware device due to firefox doesnt support HID usb connection.

Maybe if you have the chance to add it in another PR, that would be good!

@dawnseeker8 dawnseeker8 added this pull request to the merge queue Sep 2, 2025
@github-merge-queue github-merge-queue bot removed this pull request from the merge queue due to failed status checks Sep 2, 2025
@dawnseeker8 dawnseeker8 added this pull request to the merge queue Sep 2, 2025
Merged via the queue into main with commit b764cd1 Sep 2, 2025
145 checks passed
@dawnseeker8 dawnseeker8 deleted the feat/ledger-e2e-forget-device branch September 2, 2025 10:38
@github-actions github-actions bot locked and limited conversation to collaborators Sep 2, 2025
@metamaskbot metamaskbot added the release-13.4.0 Issue or pull request that will be included in release 13.4.0 label Sep 2, 2025
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

e2e-test End to end test for the MetaMask extension release-13.4.0 Issue or pull request that will be included in release 13.4.0 size-S team-accounts-framework Accounts Framework team team-hardware-wallets-deprecated DEPRECATED: please use "team-accounts-framework" instead

Projects

None yet

Development

Successfully merging this pull request may close these issues.

5 participants