Skip to content

Conversation

marioevz
Copy link
Member

🗒️ Description

Refactor Validity Marker Logic in src/pytest_plugins/forks/forks.py

Add Fork Adapters to ethereum_test_forks.helpers

Adds pydantic adapters to Fork and ForkSet.

This allows to add click parameters that automatically parse a comma-separated string of fork names into the appropriate fork type.

Add get_selected_fork_set to ethereum_test_forks.helpers

Extracts the --fork, --until and --from selector logic from the forks pytest plugin into ethereum_test_forks, in order to reuse this logic in other tools (e.g. #2045).

Refactor ValidityMarker Logic in Forks Pytest Plugin

Refactors the logic to select the forks a test should run in given a list of validity markers.

🔗 Related Issues or PRs

N/A.

✅ Checklist

  • All: Ran fast tox checks to avoid unnecessary CI fails, see also Code Standards and Enabling Pre-commit Checks:
    uvx --with=tox-uv tox -e lint,typecheck,spellcheck,markdownlint
  • All: PR title adheres to the repo standard - it will be used as the squash commit message and should start type(scope):.
  • All: Considered adding an entry to CHANGELOG.md.
  • All: Considered updating the online docs in the ./docs/ directory.

Copy link
Contributor

@spencer-tb spencer-tb left a comment

Choose a reason for hiding this comment

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

PR looks good to me!

Tested locally. --from/--fork/--until all work as expected now.

@spencer-tb spencer-tb changed the title refactor(forks): Refactor extract fork until from logic, add BPO forks by default refactor(forks): refactor extract fork until from logic Aug 20, 2025
@spencer-tb spencer-tb merged commit 510e3b8 into main Aug 20, 2025
15 checks passed
@spencer-tb spencer-tb deleted the refactor-extract-fork-until-from-logic branch August 20, 2025 19:24
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants