Skip to content

refactor(tests): replace runtime skip in EIP-7778 calldata test#2852

Merged
marioevz merged 1 commit into
ethereum:forks/amsterdamfrom
danceratopz:7778-no-skip
May 13, 2026
Merged

refactor(tests): replace runtime skip in EIP-7778 calldata test#2852
marioevz merged 1 commit into
ethereum:forks/amsterdamfrom
danceratopz:7778-no-skip

Conversation

@danceratopz
Copy link
Copy Markdown
Member

@danceratopz danceratopz commented May 13, 2026

🗒️ Description

This PR just refactors test_varying_calldata_costs to avoid runtime pytest.skip() and avoid console noise by using the filter_combinations marker from #2543.

The STORAGE_CLEAR refund is zero on revert, so the (post, pre) interval that DATA_FLOOR_BETWEEN_TX_GAS_BEFORE_AND_AFTER requires is empty; the two infeasible cells per fork are now deselected at collection time instead of at runtime.

The with_all_refund_types() covariant marker is retained so future refund types auto-participate.

Fixtures are identical to the pre-refactor branch, verified by uv run hasher compare.

🔗 Related Issues or PRs

Follow-up review nit on #2840. Uses the filter_combinations marker added by #2543.

✅ Checklist

  • All: Ran fast static checks to avoid unnecessary CI fails, see also Code Standards and Enabling Pre-commit Checks:
    just static
  • All: PR title adheres to the repo standard - it will be used as the squash commit message and should start type(scope):.
  • All: Considered updating the online docs in the ./docs/ directory.
  • All: Set appropriate labels for the changes (only maintainers can apply labels).

@danceratopz danceratopz added C-refactor Category: refactor A-tests Area: Consensus tests. labels May 13, 2026
@danceratopz danceratopz requested a review from marioevz May 13, 2026 20:25
@danceratopz danceratopz changed the base branch from eips/amsterdam/eip-7778 to forks/amsterdam May 13, 2026 20:27
@danceratopz danceratopz changed the title refactor(tests): Replace runtime skip in EIP-7778 calldata test refactor(tests): replace runtime skip in EIP-7778 calldata test May 13, 2026
…cell in `test_varying_calldata_costs`

`STORAGE_CLEAR` refund is zero on revert, so `gas_used_pre_refund == gas_used_post_refund` and the `(post, pre)` interval that `DATA_FLOOR_BETWEEN_TX_GAS_BEFORE_AND_AFTER` requires is empty. Replace the runtime `pytest.skip()` with the `filter_combinations` marker introduced in ethereum#2543, which runs in `pytest_collection_modifyitems` and can express predicates across covariant-marker-injected and inline parametrize axes uniformly.

Keeps `with_all_refund_types()` so new refund types added to the fork in future automatically participate, preserves the original three-decorator parametrize stack, and produces byte-identical fixture IDs and content vs the pre-refactor branch (verified via `diff` on `varying_calldata_costs.json` keys and bodies). The two infeasible items per fork are now deselected at collection time rather than skipped at runtime.
@codecov
Copy link
Copy Markdown

codecov Bot commented May 13, 2026

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 86.94%. Comparing base (cd8c981) to head (83732f2).
⚠️ Report is 1 commits behind head on forks/amsterdam.

Additional details and impacted files
@@               Coverage Diff                @@
##           forks/amsterdam    #2852   +/-   ##
================================================
  Coverage            86.94%   86.94%           
================================================
  Files                  586      586           
  Lines                35767    35767           
  Branches              3362     3362           
================================================
  Hits                 31098    31098           
  Misses                4010     4010           
  Partials               659      659           
Flag Coverage Δ
unittests 86.94% <ø> (ø)

Flags with carried forward coverage won't be shown. Click here to find out more.

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.

Copy link
Copy Markdown
Member

@marioevz marioevz left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM, thanks!

@marioevz marioevz merged commit cc8022a into ethereum:forks/amsterdam May 13, 2026
18 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

A-tests Area: Consensus tests. C-refactor Category: refactor

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants