Skip to content

Commit

Permalink
EIP 6780 Tests (#122)
Browse files Browse the repository at this point in the history
* wip: test-case for eip-6780

* more

* wip

* add second test

* move 6780 to cancun

* try thing

* move eip6780 tests into separate folder

* fix test fork to cancun.  correct name on test

* chore: move 6780 tests to a home in the new dir structure

* refactor: port 6780 tests to pytest format and lint/typecheck

* refactor: rewrite code using Opcodes library

* tests/6780: eip enabled/disabled versions

* tests/6780: major refactor

* tests/6780: cleaner eip enabled flag

* tests/6780: add storage check after sendall

* nit: remove comment

* tests/6780: more checks

* tests/6780: extcode checks after selfdestruct

* tests/6780: more refactoring and more tests

* tests/6780: better usage of storage

* tests/6780: check sendall recipient execution

* tests/6780: add self-destructing create tx initcode

* tests/6780: add delegate call tests

* tests/6780: refactor recreate test

* tests/6780: nit

* tests/6780: add post-selfdestruct code check

* tests/6780: selfdestruct code can sendall to calldata address

* tests/6780: sendall to multiple addresses in same tx

* tests/6780: Add sendall to self tests

* tests/6780: All tests accept sendall address list

* tests/6780: Add sendall-to-self to more tests

* fix: tox

* tests/6780: improve readability using pytest.param

* tests/6780: two more test cases to same tx test

* tests/6780: use yul to conditionally destroy the contract

* tests/6780: Fix test cases + always enable in Cancun

* tests/6780: Remove TODO, added issue #227

* tests/6780: Removed TODO comments now clarified

---------

Co-authored-by: danceratopz <danceratopz@gmail.com>
Co-authored-by: Mario Vega <marioevz@gmail.com>
  • Loading branch information
3 people authored Jul 27, 2023
1 parent 7bddb5c commit a1bd1b2
Show file tree
Hide file tree
Showing 3 changed files with 1,313 additions and 0 deletions.
1 change: 1 addition & 0 deletions .wordlist_opcodes.txt
Original file line number Diff line number Diff line change
Expand Up @@ -36,6 +36,7 @@ calldatacopy
codesize
codecopy
gasprice
extcode
extcodesize
extcodecopy
returndatasize
Expand Down
3 changes: 3 additions & 0 deletions tests/cancun/eip6780_selfdestruct/__init__.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
"""
Tests for EIP-6780: SELFDESTRUCT only in same transaction.
"""
Loading

0 comments on commit a1bd1b2

Please sign in to comment.