Skip to content

test_rjump_positive_negative()

Documentation for tests/osaka/eip7692_eof_v1/eip4200_relative_jumps/test_rjump.py::test_rjump_positive_negative@21fb11c8.

Generate fixtures for these test cases for Osaka with:

fill -v tests/osaka/eip7692_eof_v1/eip4200_relative_jumps/test_rjump.py::test_rjump_positive_negative --fork Osaka

EOF1V4200_0001 (Valid) EOF code containing RJUMP (Positive, Negative).

Source code in tests/osaka/eip7692_eof_v1/eip4200_relative_jumps/test_rjump.py
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
def test_rjump_positive_negative(
    eof_state_test: EOFStateTestFiller,
):
    """EOF1V4200_0001 (Valid) EOF code containing RJUMP (Positive, Negative)."""
    eof_state_test(
        container=Container.Code(
            Op.PUSH0
            + Op.RJUMPI[3]
            + Op.RJUMP[7]
            + Op.SSTORE(slot_code_worked, value_code_worked)
            + Op.STOP
            + Op.RJUMP[-10],
        ),
        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)
...fork_Osaka-eof_test
...fork_Osaka-eof_state_test
...fork_Osaka-eof_blockchain_test