Skip to content

test_reserve_price_various_base_fee_scenarios()

Documentation for tests/osaka/eip7918_blob_reserve_price/test_blob_base_fee.py::test_reserve_price_various_base_fee_scenarios@20373115.

Generate fixtures for these test cases for Amsterdam with:

fill -v tests/osaka/eip7918_blob_reserve_price/test_blob_base_fee.py::test_reserve_price_various_base_fee_scenarios --fork Amsterdam

Test reserve price mechanism across various block base fee and excess blob gas scenarios.

Source code in tests/osaka/eip7918_blob_reserve_price/test_blob_base_fee.py
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
@pytest.mark.parametrize(
    "block_base_fee_per_gas",
    [1, 7, 15, 16, 17, 100, 1000, 10000],
)
@pytest.mark.parametrize_by_fork(
    "parent_excess_blobs",
    lambda fork: range(0, fork.target_blobs_per_block() + 1),
)
def test_reserve_price_various_base_fee_scenarios(
    blockchain_test: BlockchainTestFiller,
    env: Environment,
    pre: Alloc,
    block: Block,
    post: Dict[Address, Account],
) -> None:
    """
    Test reserve price mechanism across various block base fee and excess blob
    gas scenarios.
    """
    blockchain_test(
        pre=pre,
        post=post,
        blocks=[block],
        genesis_environment=env,
    )

Parametrized Test Cases

This test generates 120 parametrized test cases across 2 forks.