Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

test: [POM] Migrate vault decryption e2e tests to TS and Page Object Model #28419

Open
wants to merge 25 commits into
base: develop
Choose a base branch
from

Conversation

chloeYue
Copy link
Contributor

@chloeYue chloeYue commented Nov 12, 2024

Description

  • Migrate e2e tests test/e2e/vault-decryption-chrome.spec.js to TS and Page Object Model, this test runs only on develop branch, by migrating to POM, we improve the maintainability.
  • Create page classe functions for vault decryption page, so we can use that in the future when needed
  • Deprecate/remove old functions in helper.js
  • Improved testing logs to make it easier to debug. See testing logs on this branch:

Screenshot 2024-11-13 at 10 11 41

Open in GitHub Codespaces

Related issues

Fixes: #28431

Manual testing steps

Check code readability, make sure tests pass.

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.

@chloeYue chloeYue self-assigned this Nov 12, 2024
@chloeYue chloeYue requested a review from a team as a code owner November 12, 2024 09:06
@chloeYue chloeYue marked this pull request as draft November 12, 2024 09:06
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.

@metamaskbot
Copy link
Collaborator

Builds ready [c1e6432]
Page Load Metrics (1908 ± 95 ms)
PlatformPageMetricMin (ms)Max (ms)Average (ms)StandardDeviation (ms)MarginOfError (ms)
ChromeHomefirstPaint31022951743472226
domContentLoaded16172282188218790
load16502297190819895
domInteractive16184543416
backgroundConnect9101312512
firstReactRender593281286531
getState56416168
initialActions01000
loadScripts11611758139417283
setupStore675172110
uiStartup185729952181274132
Bundle size diffs
  • background: 0 Bytes (0.00%)
  • ui: 0 Bytes (0.00%)
  • common: 0 Bytes (0.00%)

@chloeYue chloeYue changed the title test: Migrate vault decrption tests test: [POM] Migrate vault decrption e2e tests to use Page Object Model Nov 13, 2024
@chloeYue chloeYue changed the title test: [POM] Migrate vault decrption e2e tests to use Page Object Model test: [POM] Migrate vault decryption e2e tests to use Page Object Model Nov 13, 2024
@chloeYue chloeYue changed the title test: [POM] Migrate vault decryption e2e tests to use Page Object Model test: [POM] Migrate vault decryption e2e tests to TS and Page Object Model Nov 13, 2024
@chloeYue chloeYue marked this pull request as ready for review November 13, 2024 08:49
@metamaskbot
Copy link
Collaborator

Builds ready [b18fee1]
Page Load Metrics (2138 ± 186 ms)
PlatformPageMetricMin (ms)Max (ms)Average (ms)StandardDeviation (ms)MarginOfError (ms)
ChromeHomefirstPaint90134432050452217
domContentLoaded173134302106397191
load174034442138388186
domInteractive20169633316
backgroundConnect888282311
firstReactRender742941164421
getState563262311
initialActions00000
loadScripts124028231571362174
setupStore65615168
uiStartup193636802379405194
Bundle size diffs
  • background: 0 Bytes (0.00%)
  • ui: 0 Bytes (0.00%)
  • common: 0 Bytes (0.00%)

*/
async completeRevealSrpQuiz(checkErrorAnswer?: boolean): Promise<void> {
async completeRevealSrpQuiz(
Copy link
Contributor Author

Choose a reason for hiding this comment

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

intended change: we don't need to check all the wrong answer by default

@metamaskbot
Copy link
Collaborator

Builds ready [1fc9eb9]
Page Load Metrics (1672 ± 50 ms)
PlatformPageMetricMin (ms)Max (ms)Average (ms)StandardDeviation (ms)MarginOfError (ms)
ChromeHomefirstPaint15092005169312560
domContentLoaded14951981164510048
load15021985167210550
domInteractive2293522110
backgroundConnect977272010
firstReactRender453071065325
getState4509115
initialActions01000
loadScripts10651574122610048
setupStore57710167
uiStartup16482623188420197
Bundle size diffs
  • background: 0 Bytes (0.00%)
  • ui: 0 Bytes (0.00%)
  • common: 0 Bytes (0.00%)

@DDDDDanica
Copy link
Contributor

LGTM !

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
Status: Needs dev review
Development

Successfully merging this pull request may close these issues.

[POM] Migrate vault decryption e2e tests to TS and Page Object Model
3 participants