test_intrinsic_validity_across_amsterdam_transition()¶
Documentation for tests/amsterdam/eip2780_reduce_intrinsic_tx_gas/test_fork_transition.py::test_intrinsic_validity_across_amsterdam_transition@622620d8.
Generate fixtures for these test cases for Amsterdam with:
fill -v tests/amsterdam/eip2780_reduce_intrinsic_tx_gas/test_fork_transition.py::test_intrinsic_validity_across_amsterdam_transition --fork Amsterdam
Pin the intrinsic-validity flip across the Amsterdam boundary.
A zero-value call to an existing EOA needs the flat pre-fork
TX_BASE but only the decomposed TX_BASE + COLD_ACCOUNT_ACCESS
once EIP-2780 activates. A self-transfer drops to the lowered
TX_BASE alone. Either way the post-fork intrinsic is strictly
lower, so one gas limit straddles the boundary. Off-by-one gas
limits around each fork's requirement pin all four behaviors:
- Pre-fork block with the exact post-fork intrinsic is rejected: the new constraint is met, the old one is not.
- Pre-fork block with the exact pre-fork intrinsic is accepted.
- Post-fork block with one gas below the post-fork intrinsic is rejected.
- Post-fork block with the exact post-fork intrinsic, the gas limit rejected before the fork, is accepted.
No EVM bytecode runs, so each accepted transaction consumes exactly its intrinsic, pinned through the sender balance.
Source code in tests/amsterdam/eip2780_reduce_intrinsic_tx_gas/test_fork_transition.py
381 382 383 384 385 386 387 388 389 390 391 392 393 394 395 396 397 398 399 400 401 402 403 404 405 406 407 408 409 410 411 412 413 414 415 416 417 418 419 420 421 422 423 424 425 426 427 428 429 430 431 432 433 434 435 436 437 438 439 440 441 442 443 444 445 446 447 448 449 450 451 452 453 454 455 456 457 458 459 460 461 462 463 464 465 466 467 468 469 470 471 472 473 474 475 476 477 478 479 480 481 482 483 484 485 486 487 488 489 490 | |
Parametrized Test Cases¶
This test generates 2 parametrized test cases across 1 fork.