Skip to content

test_create_tx_deploys_contract()

Documentation for tests/amsterdam/eip8037_state_creation_gas_cost_increase/test_eip_mainnet.py::test_create_tx_deploys_contract@87aba1a3.

Generate fixtures for these test cases for Amsterdam with:

fill -v tests/amsterdam/eip8037_state_creation_gas_cost_increase/test_eip_mainnet.py::test_create_tx_deploys_contract --fork Amsterdam

Test contract creation transaction succeeds with state gas.

Source code in tests/amsterdam/eip8037_state_creation_gas_cost_increase/test_eip_mainnet.py
76
77
78
79
80
81
82
83
84
85
86
87
88
def test_create_tx_deploys_contract(
    state_test: StateTestFiller,
    pre: Alloc,
) -> None:
    """Test contract creation transaction succeeds with state gas."""
    tx = Transaction(
        to=None,
        data=Op.STOP,
        state_gas_reservoir=0,
        sender=pre.fund_eoa(),
    )

    state_test(pre=pre, post={}, tx=tx)

Parametrized Test Cases

This test generates 1 parametrized test case across 1 fork.