test_clz_opcode_scenarios()¶
Documentation for tests/osaka/eip7939_count_leading_zeros/test_count_leading_zeros.py::test_clz_opcode_scenarios@892e6d1e.
Generate fixtures for these test cases for Amsterdam with:
fill -v tests/osaka/eip7939_count_leading_zeros/test_count_leading_zeros.py::test_clz_opcode_scenarios --fork Amsterdam
Test CLZ opcode functionality.
Cases: - Format 0xb000...111: leading zeros followed by ones (2**256 - 1 >> bits) - Format 0xb010...000: single bit set at position (1 << bits)
Test coverage: - Leading zeros pattern: 0b000...111 (0 to 256 leading zeros) - Single bit pattern: 0b010...000 (bit at each possible position) - Edge cases: CLZ(0) = 256, CLZ(2^256-1) = 0
Source code in tests/osaka/eip7939_count_leading_zeros/test_count_leading_zeros.py
83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 | |
Parametrized Test Cases¶
This test generates 522 parametrized test cases across 2 forks.