Skip to content

docs: Manual scenario for "Import account with private key" feature#26756

Merged
benjisclowder merged 5 commits intodevelopfrom
import-account-with-private-key-scenario
Sep 3, 2024
Merged

docs: Manual scenario for "Import account with private key" feature#26756
benjisclowder merged 5 commits intodevelopfrom
import-account-with-private-key-scenario

Conversation

@benjisclowder
Copy link
Copy Markdown
Contributor

@benjisclowder benjisclowder commented Aug 29, 2024

Description

This PR documents the manual test scenario for the 'Import account with private key' feature. Below is a summary of the validations included in this manual scenario:

  • Validate that the account selector is present at the top of the wallet.
  • Validate that the 'Add account or hardware wallet' option is available at the bottom of the account selector list.
  • Validate that the 'Import account' option is available in the next menu.
  • Validate that the user is directed to the Import page upon selecting 'Import account'.
  • Validate that the user can paste their private key and click 'Import'.
  • Validate that the newly imported account appears in the account selector dropdown with an 'Imported' tag next to it.

Open in GitHub Codespaces

Related issues

Fixes: #22006

Manual testing steps

--> test/manual-scenarios/keyring/import account using private key.md
Rendered view of the manual scenario - https://github.com/MetaMask/metamask-extension/blob/import-account-with-private-key-scenario/test/manual-scenarios/keyring/import%20account%20using%20private%20key.md

@benjisclowder benjisclowder added the team-extension-platform Extension Platform team label Aug 29, 2024
@benjisclowder benjisclowder self-assigned this Aug 29, 2024
@benjisclowder benjisclowder requested a review from a team as a code owner August 29, 2024 14:58
@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.

@metamaskbot metamaskbot added the INVALID-PR-TEMPLATE PR's body doesn't match template label Aug 29, 2024
@codecov
Copy link
Copy Markdown

codecov bot commented Aug 29, 2024

Codecov Report

All modified and coverable lines are covered by tests ✅

Project coverage is 70.13%. Comparing base (594d580) to head (f658f6b).
Report is 2 commits behind head on develop.

Additional details and impacted files
@@           Coverage Diff            @@
##           develop   #26756   +/-   ##
========================================
  Coverage    70.13%   70.13%           
========================================
  Files         1424     1424           
  Lines        49571    49571           
  Branches     13867    13867           
========================================
  Hits         34765    34765           
  Misses       14806    14806           

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

@metamaskbot
Copy link
Copy Markdown
Collaborator

Builds ready [1d3527e]
Page Load Metrics (1872 ± 134 ms)
PlatformPageMetricMin (ms)Max (ms)Average (ms)StandardDeviation (ms)MarginOfError (ms)
ChromeHomefirstPaint23726111794451216
domContentLoaded155724911845261125
load156626221872280134
domInteractive13108362010
Bundle size diffs
  • background: 0 Bytes (0.00%)
  • ui: 0 Bytes (0.00%)
  • common: 0 Bytes (0.00%)

chloeYue
chloeYue previously approved these changes Aug 29, 2024
Copy link
Copy Markdown
Contributor

@chloeYue chloeYue left a comment

Choose a reason for hiding this comment

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

LGTM !

@chloeYue chloeYue changed the title Docs: Manual scenario for "Import account with private key" feature docs: Manual scenario for "Import account with private key" feature Aug 29, 2024
@chloeYue
Copy link
Copy Markdown
Contributor

For information, i changed PR title from Docs to docs to make CI pass

@benjisclowder
Copy link
Copy Markdown
Contributor Author

For information, i changed PR title from Docs to docs to make CI pass

Thank you, Chloe!

@metamaskbot
Copy link
Copy Markdown
Collaborator

Builds ready [1d9770f]
Page Load Metrics (1636 ± 51 ms)
PlatformPageMetricMin (ms)Max (ms)Average (ms)StandardDeviation (ms)MarginOfError (ms)
ChromeHomefirstPaint25020211521408196
domContentLoaded14762011161910852
load14892018163610651
domInteractive13106342311
Bundle size diffs
  • background: 0 Bytes (0.00%)
  • ui: 0 Bytes (0.00%)
  • common: 0 Bytes (0.00%)


Given I am on the 'Import account' menu
When I select 'Import account'
Then I should be directed to the Import page
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Then I should be directed to the import dialog modal.

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

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

@hjetpoluru I have now modified the duplicates and the other mention, although I am not sure we are supposed to provide private keys. I will add and ask @chloeYue for an opinion as well?

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Given I am on the 'Import account' menu
When I select 'Import account'
Then I should be directed to the Import page
And I should see a field to paste my private key
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Could you provide example private key.

@hjetpoluru
Copy link
Copy Markdown
Contributor

@benjisclowder, overall manual scenario is good. I've provided a few minor review comments.


Given I am on the import dialog modal
When I see a field to paste my private key
And I paste my private key (e.g.: 669456835741782c2ceca4e6ded60420ede38db2fb28742a1c9ae5ddf6680fa9) and click 'Import'
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Thanks @benjisclowder for updating. I wanted to provide below sample example, current format is good too.
| field | value |
| private key | 669456835741782c2ceca4e6ded60420ede38db2fb28742a1c9ae5ddf6680fa9 |

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

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

I will leave it in the current format, but I would like to understand how the format you proposed works as well in a scenario, where you would place it, @hjetpoluru.

However, the test is now in a final format and I would appreciate your final review. Thank you!

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

yeah that sounds good, given we will be soon moving to TestRail too which will make editing definitely easy. It would be bottom of the test step itself.

Given I am on the import dialog modal
When I see a field to paste my private key
And I paste my private key and click 'Import'
| field | value |
| private key | 669456835741782c2ceca4e6ded60420ede38db2fb28742a1c9ae5ddf6680fa9 |
Then I should see the newly imported account in the account selector dropdown
And the newly imported account should have an 'Imported' tag next to it

@hjetpoluru hjetpoluru self-requested a review August 31, 2024 01:30
@sonarqubecloud
Copy link
Copy Markdown

sonarqubecloud bot commented Sep 3, 2024

@metamaskbot
Copy link
Copy Markdown
Collaborator

Builds ready [f658f6b]
Page Load Metrics (1714 ± 98 ms)
PlatformPageMetricMin (ms)Max (ms)Average (ms)StandardDeviation (ms)MarginOfError (ms)
ChromeHomefirstPaint22221071563491236
domContentLoaded14122070169419795
load14192105171420598
domInteractive147135157
Bundle size diffs
  • background: 0 Bytes (0.00%)
  • ui: 0 Bytes (0.00%)
  • common: 0 Bytes (0.00%)

@benjisclowder benjisclowder merged commit ce04ae8 into develop Sep 3, 2024
@benjisclowder benjisclowder deleted the import-account-with-private-key-scenario branch September 3, 2024 14:47
@github-actions github-actions bot locked and limited conversation to collaborators Sep 3, 2024
@metamaskbot metamaskbot added the release-12.6.0 Issue or pull request that will be included in release 12.6.0 label Sep 3, 2024
@gauthierpetetin gauthierpetetin added release-12.5.0 Issue or pull request that will be included in release 12.5.0 and removed release-12.6.0 Issue or pull request that will be included in release 12.6.0 labels Sep 11, 2024
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

INVALID-PR-TEMPLATE PR's body doesn't match template release-12.5.0 Issue or pull request that will be included in release 12.5.0 team-extension-platform Extension Platform team

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Import account with private key

5 participants