Skip to content

test_rjumpv_full_table()

Documentation for tests/osaka/eip7692_eof_v1/eip4200_relative_jumps/test_rjumpv.py::test_rjumpv_full_table@21fb11c8.

Generate fixtures for these test cases for Osaka with:

fill -v tests/osaka/eip7692_eof_v1/eip4200_relative_jumps/test_rjumpv.py::test_rjumpv_full_table --fork Osaka

EOF1V4200_0012/13/14/15 (Valid) EOF with RJUMPV table size 256 (target parameterized).

Source code in tests/osaka/eip7692_eof_v1/eip4200_relative_jumps/test_rjumpv.py
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
@pytest.mark.parametrize(
    "target",
    [0, 1, 100, 254, 255, 256],
)
def test_rjumpv_full_table(
    eof_state_test: EOFStateTestFiller,
    target: int,
):
    """EOF1V4200_0012/13/14/15 (Valid) EOF with RJUMPV table size 256 (target parameterized)."""
    eof_state_test(
        container=Container(
            sections=[
                Section.Code(
                    code=Op.PUSH2[target]
                    + Op.RJUMPV[range(256)]
                    + Op.NOOP * 256
                    + Op.SSTORE(slot_code_worked, value_code_worked)
                    + Op.STOP,
                )
            ],
        ),
        container_post=Account(storage={slot_code_worked: value_code_worked}),
    )

Parametrized Test Cases

This test case is only parametrized by fork and fixture format.

Test ID (Abbreviated) target
...fork_Osaka-eof_test-target_0 0
...fork_Osaka-eof_test-target_1 1
...fork_Osaka-eof_test-target_100 100
...fork_Osaka-eof_test-target_254 254
...fork_Osaka-eof_test-target_255 255
...fork_Osaka-eof_test-target_256 256
...fork_Osaka-eof_state_test-target_0 0
...fork_Osaka-eof_state_test-target_1 1
...fork_Osaka-eof_state_test-target_100 100
...fork_Osaka-eof_state_test-target_254 254
...fork_Osaka-eof_state_test-target_255 255
...fork_Osaka-eof_state_test-target_256 256
...fork_Osaka-eof_blockchain_test-target_0 0
...fork_Osaka-eof_blockchain_test-target_1 1
...fork_Osaka-eof_blockchain_test-target_100 100
...fork_Osaka-eof_blockchain_test-target_254 254
...fork_Osaka-eof_blockchain_test-target_255 255
...fork_Osaka-eof_blockchain_test-target_256 256