Skip to content

add test coverage for weird case of plugin with multiple impls of same spec#446

Open
wahuneke wants to merge 1 commit into
pytest-dev:mainfrom
wahuneke:multi-impl-testing
Open

add test coverage for weird case of plugin with multiple impls of same spec#446
wahuneke wants to merge 1 commit into
pytest-dev:mainfrom
wahuneke:multi-impl-testing

Conversation

@wahuneke
Copy link
Copy Markdown
Contributor

These tests are attempting to find @RonnyPfannschmidt 's theoretical issue described in issue #431 . Conversation in 431 is ongoing. This PR is here for reference. It is a DRAFT.

NOTE: these tests currently pass. They do not detect any new issues.

Copy link
Copy Markdown
Member

@RonnyPfannschmidt RonnyPfannschmidt left a comment

Choose a reason for hiding this comment

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

well done, those tests verify that my assessment from just/only looking at the code was wrong and now we have a demonstration of the correctness for those cases

@wahuneke wahuneke marked this pull request as ready for review September 23, 2023 00:44
@RonnyPfannschmidt RonnyPfannschmidt force-pushed the multi-impl-testing branch 2 times, most recently from 87cc255 to 479123e Compare May 27, 2026 09:54
@RonnyPfannschmidt
Copy link
Copy Markdown
Member

Rebased onto current main and updated for merge:

  • Dropped the test_hook_multi_impl commit — the behaviour it tested (register/unregister with multi-impl plugins, get_hookcallers return count) is now fully covered by test_unregister_plugin_with_multi_hookimpls and test_get_hookcallers_no_duplicates added in Fix _remove_plugin and get_hookcallers for multi-impl plugins #646, which also fixed the underlying bug (multi hook registration does not unregister #431) that this PR was originally investigating.

  • Kept the tracer tests (test_plugin_tracing, test_dbl_plugin_tracing) — these are new coverage for hook tracing with multi-impl plugins, not covered elsewhere.

  • Fixed List[str]list[str] and added a missing blank line to pass pre-commit (ruff, flake8, mypy).

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