MCPcopy
hub / github.com/ethereum/research / test_empty_epoch_transition

Function test_empty_epoch_transition

spec_pythonizer/sanity_check.py:222–233  ·  view source on GitHub ↗
(state)

Source from the content-addressed store, hash-verified

220
221# @timeit
222def test_empty_epoch_transition(state):
223 test_state = deepcopy(state)
224 block = construct_empty_block_for_next_slot(test_state)
225 block.slot += spec.SLOTS_PER_EPOCH
226
227 state_transition(test_state, block)
228
229 assert test_state.slot == block.slot
230 for slot in range(state.slot, test_state.slot):
231 assert get_block_root(test_state, slot) == block.previous_block_root
232
233 return state, [block], test_state
234
235
236# @timeit

Callers

nothing calls this directly

Calls 3

state_transitionFunction · 0.90
deepcopyFunction · 0.85

Tested by

no test coverage detected