test_blobhash_gas_cost()¶
Documentation for tests/cancun/eip4844_blobs/test_blobhash_opcode.py::test_blobhash_gas_cost@verkle@v0.0.6.
Generate fixtures for these test cases for Cancun with:
Cancun only:
fill -v tests/cancun/eip4844_blobs/test_blobhash_opcode.py::test_blobhash_gas_cost --fork=Cancun --evm-bin=/path/to/evm-tool-dev-version
For all forks up to and including Cancun:
fill -v tests/cancun/eip4844_blobs/test_blobhash_opcode.py::test_blobhash_gas_cost --until=Cancun
Tests BLOBHASH opcode gas cost using a variety of indexes.
Asserts that the gas consumption of the BLOBHASH opcode is correct by ensuring
it matches HASH_OPCODE_GAS = 3. Includes both valid and invalid random
index sizes from the range [0, 2**256-1], for tx types 2 and 3.
Source code in tests/cancun/eip4844_blobs/test_blobhash_opcode.py
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 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 | |
Parametrized Test Cases¶
The interactive table below is also available as a standalone page.
Skipped Parameters
For more concise readability, the table below does not list the following parameter values:
fork, blockchain_test, state_test, state_test_only, eof_test, eof_state_test.
| Test ID | tx_type | blobhash_index |
|---|---|---|
| tx_type_3-blobhash_index_0 | 3 | 0 |
| tx_type_3-blobhash_index_1 | 3 | 1 |
| tx_type_3-blobhash_index_2 | 3 | 2 |
| tx_type_3-blobhash_index_3 | 3 | 3 |
| tx_type_3-blobhash_index_4 | 3 | 4 |
| tx_type_3-blobhash_index_115792089237316195423570985008687907853269984665640564039457584007913129639935 | 3 | 115792089237316195423570985008687907853269984665640564039457584007913129639935 |
| tx_type_3-blobhash_index_72901072107898194510616918724280211781393090952923809435170590639787343028527 | 3 | 72901072107898194510616918724280211781393090952923809435170590639787343028527 |
| tx_type_3-blobhash_index_0 | 3 | 0 |
| tx_type_3-blobhash_index_1 | 3 | 1 |
| tx_type_3-blobhash_index_2 | 3 | 2 |
| tx_type_3-blobhash_index_3 | 3 | 3 |
| tx_type_3-blobhash_index_4 | 3 | 4 |
| tx_type_3-blobhash_index_115792089237316195423570985008687907853269984665640564039457584007913129639935 | 3 | 115792089237316195423570985008687907853269984665640564039457584007913129639935 |
| tx_type_3-blobhash_index_72901072107898194510616918724280211781393090952923809435170590639787343028527 | 3 | 72901072107898194510616918724280211781393090952923809435170590639787343028527 |
| tx_type_2-blobhash_index_0 | 2 | 0 |
| tx_type_2-blobhash_index_1 | 2 | 1 |
| tx_type_2-blobhash_index_2 | 2 | 2 |
| tx_type_2-blobhash_index_3 | 2 | 3 |
| tx_type_2-blobhash_index_4 | 2 | 4 |
| tx_type_2-blobhash_index_115792089237316195423570985008687907853269984665640564039457584007913129639935 | 2 | 115792089237316195423570985008687907853269984665640564039457584007913129639935 |
| tx_type_2-blobhash_index_72901072107898194510616918724280211781393090952923809435170590639787343028527 | 2 | 72901072107898194510616918724280211781393090952923809435170590639787343028527 |
| tx_type_2-blobhash_index_0 | 2 | 0 |
| tx_type_2-blobhash_index_1 | 2 | 1 |
| tx_type_2-blobhash_index_2 | 2 | 2 |
| tx_type_2-blobhash_index_3 | 2 | 3 |
| tx_type_2-blobhash_index_4 | 2 | 4 |
| tx_type_2-blobhash_index_115792089237316195423570985008687907853269984665640564039457584007913129639935 | 2 | 115792089237316195423570985008687907853269984665640564039457584007913129639935 |
| tx_type_2-blobhash_index_72901072107898194510616918724280211781393090952923809435170590639787343028527 | 2 | 72901072107898194510616918724280211781393090952923809435170590639787343028527 |
| tx_type_1-blobhash_index_0 | 1 | 0 |
| tx_type_1-blobhash_index_1 | 1 | 1 |
| tx_type_1-blobhash_index_2 | 1 | 2 |
| tx_type_1-blobhash_index_3 | 1 | 3 |
| tx_type_1-blobhash_index_4 | 1 | 4 |
| tx_type_1-blobhash_index_115792089237316195423570985008687907853269984665640564039457584007913129639935 | 1 | 115792089237316195423570985008687907853269984665640564039457584007913129639935 |
| tx_type_1-blobhash_index_72901072107898194510616918724280211781393090952923809435170590639787343028527 | 1 | 72901072107898194510616918724280211781393090952923809435170590639787343028527 |
| tx_type_1-blobhash_index_0 | 1 | 0 |
| tx_type_1-blobhash_index_1 | 1 | 1 |
| tx_type_1-blobhash_index_2 | 1 | 2 |
| tx_type_1-blobhash_index_3 | 1 | 3 |
| tx_type_1-blobhash_index_4 | 1 | 4 |
| tx_type_1-blobhash_index_115792089237316195423570985008687907853269984665640564039457584007913129639935 | 1 | 115792089237316195423570985008687907853269984665640564039457584007913129639935 |
| tx_type_1-blobhash_index_72901072107898194510616918724280211781393090952923809435170590639787343028527 | 1 | 72901072107898194510616918724280211781393090952923809435170590639787343028527 |
| tx_type_0-blobhash_index_0 | 0 | 0 |
| tx_type_0-blobhash_index_1 | 0 | 1 |
| tx_type_0-blobhash_index_2 | 0 | 2 |
| tx_type_0-blobhash_index_3 | 0 | 3 |
| tx_type_0-blobhash_index_4 | 0 | 4 |
| tx_type_0-blobhash_index_115792089237316195423570985008687907853269984665640564039457584007913129639935 | 0 | 115792089237316195423570985008687907853269984665640564039457584007913129639935 |
| tx_type_0-blobhash_index_72901072107898194510616918724280211781393090952923809435170590639787343028527 | 0 | 72901072107898194510616918724280211781393090952923809435170590639787343028527 |
| tx_type_0-blobhash_index_0 | 0 | 0 |
| tx_type_0-blobhash_index_1 | 0 | 1 |
| tx_type_0-blobhash_index_2 | 0 | 2 |
| tx_type_0-blobhash_index_3 | 0 | 3 |
| tx_type_0-blobhash_index_4 | 0 | 4 |
| tx_type_0-blobhash_index_115792089237316195423570985008687907853269984665640564039457584007913129639935 | 0 | 115792089237316195423570985008687907853269984665640564039457584007913129639935 |
| tx_type_0-blobhash_index_72901072107898194510616918724280211781393090952923809435170590639787343028527 | 0 | 72901072107898194510616918724280211781393090952923809435170590639787343028527 |