Skip to content

test_returncontract_invalid_index_1()

Documentation for tests/osaka/eip7692_eof_v1/eip7620_eof_create/test_returncontract.py::test_returncontract_invalid_index_1@21fb11c8.

Generate fixtures for these test cases for Osaka with:

fill -v tests/osaka/eip7692_eof_v1/eip7620_eof_create/test_returncontract.py::test_returncontract_invalid_index_1 --fork Osaka

Referring to non-existent container section index 1.

Source code in tests/osaka/eip7692_eof_v1/eip7620_eof_create/test_returncontract.py
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
def test_returncontract_invalid_index_1(
    eof_test: EOFTestFiller,
):
    """Referring to non-existent container section index 1."""
    eof_test(
        container_kind=ContainerKind.INITCODE,
        container=Container(
            sections=[
                Section.Code(
                    code=Op.RETURNCONTRACT[1](0, 0),
                ),
                Section.Container(container=Container(sections=[Section.Code(code=Op.INVALID)])),
            ],
        ),
        expect_exception=EOFException.INVALID_CONTAINER_SECTION_INDEX,
    )

Parametrized Test Cases

This test case is only parametrized by fork.

Test ID (Abbreviated)
...fork_Osaka-eof_test