Skip to content

test_eip_8282()

Documentation for tests/amsterdam/eip8282_builder_execution_requests/test_eip_mainnet.py::test_eip_8282@5fa5938b.

Generate fixtures for these test cases for Amsterdam with:

fill -v tests/amsterdam/eip8282_builder_execution_requests/test_eip_mainnet.py::test_eip_8282 --fork Amsterdam

Test making builder deposit and exit requests.

Source code in tests/amsterdam/eip8282_builder_execution_requests/test_eip_mainnet.py
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
@pytest.mark.parametrize(
    "system_contract_interactions_per_block",
    [
        pytest.param(
            [
                [
                    SystemContractInteractionTransaction(
                        requests=[
                            BuilderDepositRequest(
                                pubkey=0x01,
                                withdrawal_credentials=0x02,
                                amount=MIN_DEPOSIT_GWEI,
                                signature=0x03,
                            )
                        ],
                    ),
                ],
            ],
            id="single_builder_deposit_request",
        ),
        pytest.param(
            [
                [
                    SystemContractInteractionTransaction(
                        requests=[BuilderExitRequest(pubkey=0x01)],
                    ),
                ],
            ],
            id="single_builder_exit_request",
        ),
        pytest.param(
            [
                [
                    SystemContractInteractionTransaction(
                        requests=[
                            BuilderDepositRequest(
                                pubkey=0x01,
                                withdrawal_credentials=0x02,
                                amount=MIN_DEPOSIT_GWEI,
                                signature=0x03,
                            ),
                            BuilderExitRequest(pubkey=0x04),
                        ],
                    ),
                ],
            ],
            id="single_builder_deposit_and_exit_request",
        ),
    ],
)
def test_eip_8282(
    blockchain_test: BlockchainTestFiller,
    pre: Alloc,
    blocks: List[Block],
) -> None:
    """Test making builder deposit and exit requests."""
    blockchain_test(pre=pre, post={}, blocks=blocks)

Parametrized Test Cases

This test generates 3 parametrized test cases across 1 fork.