Skip to content

Conversation

@FrederikBolding
Copy link
Member

@FrederikBolding FrederikBolding commented Dec 19, 2025

Add method for getting genesis block to Ethereum provider example Snap. This is useful for properly testing what chain we are connected to in E2E. Also removes some unused methods.


Note

Add getGenesisBlock RPC to the example Snap (with getBlock helper), remove getGasPrice/getVersion, and update tests and UI to support it.

  • Ethereum Provider Snap:
    • Add getGenesisBlock RPC; implement getBlock(number) using eth_getBlockByNumber and wire into onRpcRequest.
    • Remove unused RPCs getGasPrice and getVersion; retain getChainId and existing signing/account methods.
  • Tests:
    • Add genesis block test mocking eth_getBlockByNumber; remove gas price/version tests.
  • Test App UI:
    • Add "Get Genesis Block" button and handler in packages/test-snaps/src/features/snaps/ethereum-provider/EthereumProvider.tsx.

Written by Cursor Bugbot for commit f1b0591. This will update automatically on new commits. Configure here.

@FrederikBolding FrederikBolding requested a review from a team as a code owner December 19, 2025 10:51
@codecov
Copy link

codecov bot commented Dec 19, 2025

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 98.33%. Comparing base (f48a11a) to head (f1b0591).
⚠️ Report is 6 commits behind head on main.

Additional details and impacted files
@@           Coverage Diff           @@
##             main    #3788   +/-   ##
=======================================
  Coverage   98.33%   98.33%           
=======================================
  Files         420      420           
  Lines       12032    12032           
  Branches     1874     1874           
=======================================
  Hits        11832    11832           
  Misses        200      200           

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

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.
  • 📦 JS Bundle Analysis: Save yourself from yourself by tracking and limiting bundle sizes in JS merges.

@FrederikBolding FrederikBolding added this pull request to the merge queue Dec 19, 2025
Merged via the queue into main with commit 5db56bf Dec 19, 2025
127 checks passed
@FrederikBolding FrederikBolding deleted the fb/ethereum-provider-genesis branch December 19, 2025 11:06
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.

3 participants