Skip to content

Fix unmocked block tracker warning in GasFeeController tests#5297

Merged
mcmire merged 4 commits into
mainfrom
fix-block-tracker-warning-in-gfc-tests
May 1, 2025
Merged

Fix unmocked block tracker warning in GasFeeController tests#5297
mcmire merged 4 commits into
mainfrom
fix-block-tracker-warning-in-gfc-tests

Conversation

@mcmire
Copy link
Copy Markdown
Contributor

@mcmire mcmire commented Feb 6, 2025

Explanation

When running the tests for GasFeeController, we were seeing many warnings in the test output indicating that a request from the block tracker was not properly mocked. This commit adds that mock so the warning goes away.

References

Manual testing

  • Switch to main and run yarn workspace @metamask/gas-fee-controller run test. See that there are a lot of console.error lines.
  • Switch to this branch and run the same command. See that there are no console.error lines.

Checklist

  • I've updated the test suite for new or updated code as appropriate
  • I've updated documentation (JSDoc, Markdown, etc.) for new or updated code as appropriate
  • I've highlighted breaking changes using the "BREAKING" category above as appropriate
  • I've prepared draft pull requests for clients and consumer packages to resolve any breaking changes

When running the tests for GasFeeController, we were seeing a warning in
the tests that a request from the block tracker was not properly mocked.
This commit adds that mock so the warning goes away.
@mcmire mcmire force-pushed the fix-block-tracker-warning-in-gfc-tests branch from 3cc1a6f to 1d385da Compare February 6, 2025 18:21
@mcmire mcmire marked this pull request as ready for review February 6, 2025 18:27
@mcmire mcmire requested a review from a team as a code owner February 6, 2025 18:27
@mcmire mcmire added the team-wallet-framework Deprecated: Please use `team-core-platform` instead. label Feb 6, 2025
@mcmire
Copy link
Copy Markdown
Contributor Author

mcmire commented Feb 6, 2025

@MetaMask/confirmations Can I get a review on this PR when you get a chance, thanks!

@mcmire mcmire merged commit 92f354b into main May 1, 2025
202 checks passed
@mcmire mcmire deleted the fix-block-tracker-warning-in-gfc-tests branch May 1, 2025 18:05
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

team-wallet-framework Deprecated: Please use `team-core-platform` instead.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants