test_auth_state_gas_in_header_after_failure()¶
Documentation for tests/amsterdam/eip8037_state_creation_gas_cost_increase/test_state_gas_set_code.py::test_auth_state_gas_in_header_after_failure@87aba1a3.
Generate fixtures for these test cases for Amsterdam with:
fill -v tests/amsterdam/eip8037_state_creation_gas_cost_increase/test_state_gas_set_code.py::test_auth_state_gas_in_header_after_failure --fork Amsterdam
Verify the header gas_used when the top-level call fails after the
authorization is applied.
The delegation is applied in the top-frame preparation (before the
execution snapshot), so it persists through every failure mode --
and so does the state gas that paid for it (NEW_ACCOUNT +
AUTH_BASE for a fresh authority, AUTH_BASE for an existing
one), which is folded out of the frame's refillable pools. The
header is max(block_regular, block_state):
- REVERT -- the unused execution budget returns, so the regular
component is
intrinsic_regular + top_frame_regular + execution_regularand the state component is the persisting authorization state gas. - HALT / OOG -- the frame consumes its whole gas limit; the authorization state gas within it is accounted on the state component, and the remainder on the regular component.
Source code in tests/amsterdam/eip8037_state_creation_gas_cost_increase/test_state_gas_set_code.py
1617 1618 1619 1620 1621 1622 1623 1624 1625 1626 1627 1628 1629 1630 1631 1632 1633 1634 1635 1636 1637 1638 1639 1640 1641 1642 1643 1644 1645 1646 1647 1648 1649 1650 1651 1652 1653 1654 1655 1656 1657 1658 1659 1660 1661 1662 1663 1664 1665 1666 1667 1668 1669 1670 1671 1672 1673 1674 1675 1676 1677 1678 1679 1680 1681 1682 1683 1684 1685 1686 1687 1688 1689 1690 1691 1692 1693 1694 1695 1696 1697 1698 1699 1700 1701 1702 1703 1704 1705 1706 1707 1708 1709 1710 1711 1712 1713 1714 1715 1716 1717 1718 1719 1720 1721 1722 1723 1724 | |
Parametrized Test Cases¶
This test generates 6 parametrized test cases across 1 fork.