test_swapn_invalid_immediate_aborts()¶
Documentation for tests/amsterdam/eip8024_dupn_swapn_exchange/test_swapn.py::test_swapn_invalid_immediate_aborts@c74f1a67.
Generate fixtures for these test cases for Amsterdam with:
fill -v tests/amsterdam/eip8024_dupn_swapn_exchange/test_swapn.py::test_swapn_invalid_immediate_aborts --fork Amsterdam
Test SWAPN with invalid immediate values (90 < x < 128) aborts.
Per EIP-8024, immediate values in range [91, 127] (0x5b-0x7f) are invalid because they correspond to JUMPDEST (0x5b) and PUSH opcodes (0x60-0x7f). Attempting to execute SWAPN with these immediates should abort.
Source code in tests/amsterdam/eip8024_dupn_swapn_exchange/test_swapn.py
267 268 269 270 271 272 273 274 275 276 277 278 279 280 281 282 283 284 285 286 287 288 289 290 291 292 293 294 295 296 297 298 299 300 301 302 303 304 305 306 307 308 309 | |
Parametrized Test Cases¶
This test generates 37 parametrized test cases across 1 fork.