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

refactor: add account generator for unit test #304

Merged
merged 10 commits into from
Jul 31, 2024

Conversation

stanleyyconsensys
Copy link
Collaborator

This PR is to add account generator to replace the use of a constant account to produce a more realistic test case

This PR move mock file snap-provider.mock.ts to ./packages/starknet-snap/test , due to it is more convenient to have mock function manageState and dialog in place. Otherwise the lint will throw error if we try to import an function from a mock file

This PR also adding a demo for onHomePage in index.test.ts to demo how to use the generate account and the mock state function

@stanleyyconsensys stanleyyconsensys requested a review from a team as a code owner July 31, 2024 03:52
@stanleyyconsensys stanleyyconsensys requested review from Akaryatrh, jonesho, khanti42 and a team and removed request for a team July 31, 2024 03:52
Copy link
Collaborator

@khanti42 khanti42 left a comment

Choose a reason for hiding this comment

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

LGTM

@stanleyyconsensys stanleyyconsensys enabled auto-merge (squash) July 31, 2024 06:54
Copy link

Quality Gate Passed Quality Gate passed for 'consensys_starknet-snap-starknet-snap'

Issues
0 New issues
0 Accepted issues

Measures
0 Security Hotspots
0.0% Coverage on New Code
0.0% Duplication on New Code

See analysis details on SonarCloud

Copy link

Quality Gate Passed Quality Gate passed for 'consensys_starknet-snap-wallet-ui'

Issues
0 New issues
0 Accepted issues

Measures
0 Security Hotspots
0.0% Coverage on New Code
0.0% Duplication on New Code

See analysis details on SonarCloud

@stanleyyconsensys stanleyyconsensys merged commit e6f76f8 into main Jul 31, 2024
13 checks passed
@stanleyyconsensys stanleyyconsensys deleted the chore/add-account-generator-for-unit-test branch July 31, 2024 07:05
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants