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

fix test filtering on eth1 voting spec test #2584

Merged
merged 1 commit into from
Sep 2, 2021
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
10 changes: 2 additions & 8 deletions tests/core/pyspec/eth2spec/test/phase0/sanity/test_blocks.py
Original file line number Diff line number Diff line change
Expand Up @@ -974,12 +974,9 @@ def test_historical_batch(spec, state):


@with_all_phases
@with_presets([MINIMAL], reason="suffices to test eth1 data voting without long voting period")
@spec_state_test
def test_eth1_data_votes_consensus(spec, state):
if spec.EPOCHS_PER_ETH1_VOTING_PERIOD > 2:
return dump_skipping_message("Skip test if config with longer `EPOCHS_PER_ETH1_VOTING_PERIOD` for saving time."
" Minimal config suffice to cover the target-of-test.")

voting_period_slots = spec.EPOCHS_PER_ETH1_VOTING_PERIOD * spec.SLOTS_PER_EPOCH

offset_block = build_empty_block(spec, state, slot=voting_period_slots - 1)
Expand Down Expand Up @@ -1018,12 +1015,9 @@ def test_eth1_data_votes_consensus(spec, state):


@with_all_phases
@with_presets([MINIMAL], reason="suffices to test eth1 data voting without long voting period")
@spec_state_test
def test_eth1_data_votes_no_consensus(spec, state):
if spec.EPOCHS_PER_ETH1_VOTING_PERIOD > 2:
return dump_skipping_message("Skip test if config with longer `EPOCHS_PER_ETH1_VOTING_PERIOD` for saving time."
" Minimal config suffice to cover the target-of-test.")

voting_period_slots = spec.EPOCHS_PER_ETH1_VOTING_PERIOD * spec.SLOTS_PER_EPOCH

pre_eth1_hash = state.eth1_data.block_hash
Expand Down