Skip to content

test_rjump_into_self_data_portion()

Documentation for tests/osaka/eip7692_eof_v1/eip4200_relative_jumps/test_rjump.py::test_rjump_into_self_data_portion@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_into_self_data_portion --fork Osaka

EOF1I4200_0008 (Invalid) EOF code containing RJUMP with target self RJUMP immediate.

Source code in tests/osaka/eip7692_eof_v1/eip4200_relative_jumps/test_rjump.py
227
228
229
230
231
232
233
234
235
236
@pytest.mark.parametrize("offset", range(1, Op.RJUMP.data_portion_length + 1))
def test_rjump_into_self_data_portion(
    eof_test: EOFTestFiller,
    offset: int,
):
    """EOF1I4200_0008 (Invalid) EOF code containing RJUMP with target self RJUMP immediate."""
    eof_test(
        container=Container.Code(Op.RJUMP[-offset] + Op.STOP),
        expect_exception=EOFException.INVALID_RJUMP_DESTINATION,
    )

Parametrized Test Cases

The interactive table below is also available as a standalone page.

Test ID (Abbreviated) offset
...fork_Osaka-eof_test-offset_1 1
...fork_Osaka-eof_test-offset_2 2