Skip to content

test_rjumpi_backwards_min_stack_wrong()

Documentation for tests/osaka/eip7692_eof_v1/eip4200_relative_jumps/test_rjumpi.py::test_rjumpi_backwards_min_stack_wrong@83970623.

Generate fixtures for these test cases for Osaka with:

fill -v tests/osaka/eip7692_eof_v1/eip4200_relative_jumps/test_rjumpi.py::test_rjumpi_backwards_min_stack_wrong --fork Osaka

Backwards rjumpi where min_stack does not match.

Source code in tests/osaka/eip7692_eof_v1/eip4200_relative_jumps/test_rjumpi.py
890
891
892
893
894
895
896
897
898
899
900
901
902
903
904
905
906
907
908
909
def test_rjumpi_backwards_min_stack_wrong(
    eof_test: EOFTestFiller,
):
    """Backwards rjumpi where min_stack does not match."""
    container = Container.Code(
        code=(
            Op.PUSH0  # (0, 0)
            + Op.PUSH1(0)  # (1, 1)
            + Op.RJUMPI[1]  # (2, 2) To PUSH1
            + Op.PUSH0  # (1, 1)
            + Op.PUSH1(4)  # (1, 2)
            + Op.RJUMPI[-9]  # (2, 3) To first RJUMPI with (1, 2)
            + Op.STOP  # (1, 2)
        ),
        max_stack_height=3,
    )
    eof_test(
        container=container,
        expect_exception=EOFException.STACK_HEIGHT_MISMATCH,
    )

Parametrized Test Cases

This test case is only parametrized by fork.

Test ID (Abbreviated)
...fork_Osaka-eof_test