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

new(tests): EIP-2935 - Update tests to recent spec change #585

Merged

Conversation

spencer-tb
Copy link
Collaborator

@spencer-tb spencer-tb commented Jun 1, 2024

🗒️ Description

Aims to update the existing EIP-2935 tests in conjuction with the recent spec change ethereum/EIPs#8577, removing the external contract and instead using a system contract.

The test cases now check for the following:

  • Before the fork, BLOCKHASH behaves as it always has, can retrieve blockhashes. System contract cannot.
  • At the fork block, BLOCKHASH behaves as it always has, can retrieve blockhashes. System contract stores first blockhash during block processing, ready for retrival at the next block, nothing is retrievable yet.
  • After the fork block, BLOCKHASH behaves as it always has. System contract can incrementally retrieve all blockhash that have been stored within the contract.

Remaining Todo's

  • Update or use correct geth t8n to fill tests correctly.
  • Find and rebase solution for filling tests fast for large no. blocks >>8192.
  • Add sanity blockhash gas cost test check (maybe port over blockhash tests from ethereum/tests.
  • Add sanity ring buffer size test (or add to existing tests).

🔗 Related Issues

#570

✅ Checklist

  • All: Set appropriate labels for the changes.
  • All: Considered squashing commits to improve commit history.
  • All: Added an entry to CHANGELOG.md.
  • All: Considered updating the online docs in the ./docs/ directory.
  • Tests: All converted JSON/YML tests from ethereum/tests have been added to converted-ethereum-tests.txt.
  • Tests: Included the type and version of evm t8n tool used to locally execute test cases: e.g., ref with commit hash or geth 1.13.1-stable-3f40e65.
  • Tests: Ran mkdocs serve locally and verified the auto-generated docs for new tests in the Test Case Reference are correctly formatted.

@spencer-tb spencer-tb force-pushed the tests/prague/eip2935/spec-change-updates-1 branch 2 times, most recently from 5a1ae88 to 3888c93 Compare June 1, 2024 08:40
Copy link
Member

@marioevz marioevz left a comment

Choose a reason for hiding this comment

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

Thanks for the tests! Some comments.

@marioevz marioevz force-pushed the tests/prague/eip2935/spec-change-updates-1 branch from 3888c93 to f524a05 Compare June 25, 2024 16:35
@marioevz marioevz marked this pull request as ready for review June 25, 2024 19:22
@marioevz marioevz changed the title feat(tests): update EIP-2935 tests to recent spec change feat(tests): EIP-2935 - Update tests to recent spec change Jun 25, 2024
@marioevz marioevz added scope:tests Scope: Test cases type:test Type: Test labels Jun 25, 2024
@marioevz marioevz changed the title feat(tests): EIP-2935 - Update tests to recent spec change new(tests): EIP-2935 - Update tests to recent spec change Jun 25, 2024
@marioevz marioevz merged commit 4f5a541 into ethereum:main Jun 25, 2024
4 checks passed
spencer-tb added a commit that referenced this pull request Jun 26, 2024
* chore(fw): create contracts folder for bin files.

* feat(fw): remove history storage contract.

* feat(tests): update eip2935 transtion tests to new spec.

* typo

* fix(forks): History contract

* fix(tests): nits

* fix(tests): HISTORY_STORAGE_ADDRESS spec update

* fix(tests): refactor transition tests, helper function, add post fork test

* fix(tests): logic fixes

* fix

* fix: ref spec sha

* feat(fw): Add `storage.canary()`

* new(tests): add invalid block number requests

* changelog

---------

Co-authored-by: Mario Vega <[email protected]>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
scope:tests Scope: Test cases type:test Type: Test
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants