-
Notifications
You must be signed in to change notification settings - Fork 926
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #3227 from ethereum/more-capella-tests
More capella tests
- Loading branch information
Showing
8 changed files
with
246 additions
and
8 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Empty file.
54 changes: 54 additions & 0 deletions
54
tests/core/pyspec/eth2spec/test/eip4844/transition/test_operations.py
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,54 @@ | ||
from eth2spec.test.context import ( | ||
ForkMeta, | ||
always_bls, | ||
with_fork_metas, | ||
) | ||
from eth2spec.test.helpers.constants import ( | ||
AFTER_DENEB_PRE_POST_FORKS, | ||
) | ||
from eth2spec.test.helpers.fork_transition import ( | ||
OperationType, | ||
run_transition_with_operation, | ||
) | ||
|
||
|
||
# | ||
# BLSToExecutionChange | ||
# | ||
|
||
@with_fork_metas([ForkMeta(pre_fork_name=pre, post_fork_name=post, fork_epoch=2) | ||
for pre, post in AFTER_DENEB_PRE_POST_FORKS]) | ||
@always_bls | ||
def test_transition_with_btec_right_after_fork(state, fork_epoch, spec, post_spec, pre_tag, post_tag): | ||
""" | ||
Create a BLS_TO_EXECUTION_CHANGE right *after* the transition | ||
""" | ||
yield from run_transition_with_operation( | ||
state, | ||
fork_epoch, | ||
spec, | ||
post_spec, | ||
pre_tag, | ||
post_tag, | ||
operation_type=OperationType.BLS_TO_EXECUTION_CHANGE, | ||
operation_at_slot=fork_epoch * spec.SLOTS_PER_EPOCH, | ||
) | ||
|
||
|
||
@with_fork_metas([ForkMeta(pre_fork_name=pre, post_fork_name=post, fork_epoch=2) | ||
for pre, post in AFTER_DENEB_PRE_POST_FORKS]) | ||
@always_bls | ||
def test_transition_with_btec_right_before_fork(state, fork_epoch, spec, post_spec, pre_tag, post_tag): | ||
""" | ||
Create a BLS_TO_EXECUTION_CHANGE right *before* the transition | ||
""" | ||
yield from run_transition_with_operation( | ||
state, | ||
fork_epoch, | ||
spec, | ||
post_spec, | ||
pre_tag, | ||
post_tag, | ||
operation_type=OperationType.BLS_TO_EXECUTION_CHANGE, | ||
operation_at_slot=fork_epoch * spec.SLOTS_PER_EPOCH - 1, | ||
) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters