Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix pytest_ignore_collect not to block default pytest code #673

Merged
merged 1 commit into from
May 28, 2024

Conversation

mgorny
Copy link
Contributor

@mgorny mgorny commented May 28, 2024

Fix pytest_ignore_collect hook implementation to return None rather than False when the path ought not to be ignored. This is necessary to enable the default pytest implementation of pytest_ignore_collect() to be used. Otherwise, the default rules are never applied and e.g. --ignore does not work.

I've also reported pytest-dev/pytest#12383 about the misleading documentation.

Fix `pytest_ignore_collect` hook implementation to return `None`
rather than `False` when the path ought not to be ignored.  This is
necessary to enable the default pytest implementation of
`pytest_ignore_collect()` to be used.  Otherwise, the default rules
are never applied and e.g. `--ignore` does not work.

I've also reported pytest-dev/pytest#12383
about the misleading documentation.
@aleneum aleneum merged commit ce0e46f into pytransitions:master May 28, 2024
8 checks passed
@coveralls
Copy link

Coverage Status

coverage: 98.526%. remained the same
when pulling 2a8eaf3 on mgorny:pytest-ignore
into dccae40 on pytransitions:master.

@aleneum
Copy link
Member

aleneum commented May 28, 2024

Hi @mgorny,

thanks a lot for that fix! Good to know that pytest_ignore_collect expects True or None as return value.

Cheers!

@mgorny mgorny deleted the pytest-ignore branch May 28, 2024 08:35
@mgorny
Copy link
Contributor Author

mgorny commented May 28, 2024

Thanks!

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.

3 participants