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

cacheprovider: fix file-skipping feature for files in packages #11055

Merged
merged 1 commit into from
May 30, 2023

Conversation

bluetech
Copy link
Member

--lf has a feature where if a certain Module (python file) does not contain any failed tests, it is skipped entirely at the collector level instead of being collected and each item skipped individually. When this happens the collection summary looks like this:

run-last-failure: rerun previous 1 failure (skipped 1 file)

However, this feature didn't work for Modules inside of Packages, only for those directly beneath the Session.

Fix #11054.

`--lf` has a feature where if a certain `Module` (python file) does not
contain any failed tests, it is skipped entirely at the collector level
instead of being collected and each item skipped individually. When this
happens the collection summary looks like this:

    run-last-failure: rerun previous 1 failure (skipped 1 file)

However, this feature didn't work for `Module`s inside of `Package`s,
only for those directly beneath the `Session`.

Fix pytest-dev#11054.
@bluetech
Copy link
Member Author

Actually this only takes care of the issue for a single "level" (Session/Package), but it can still happen between levels. So I'll need to make some further change here. However this part will be needed anyway so it's good to merge.

@bluetech bluetech merged commit 3a6bdcd into pytest-dev:main May 30, 2023
25 checks passed
@bluetech bluetech deleted the lf-skipped-package branch May 30, 2023 17:04
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.

cacheprovider: --lf file-skipping feature doesn't work for files in packages
2 participants