Skip to content

Docs: clarify multiple arguments in pytest.mark.filterwarnings#14259

Merged
webknjaz merged 1 commit into
pytest-dev:mainfrom
mitre88:patch-4
Mar 6, 2026
Merged

Docs: clarify multiple arguments in pytest.mark.filterwarnings#14259
webknjaz merged 1 commit into
pytest-dev:mainfrom
mitre88:patch-4

Conversation

@mitre88

@mitre88 mitre88 commented Mar 5, 2026

Copy link
Copy Markdown
Contributor

Summary

Follow-up clarification for #12966.

This PR adds a docs example showing that multiple warning filters can be passed to a single @pytest.mark.filterwarnings(...) call, and clarifies that later arguments take precedence (matching warnings.filterwarnings behavior).

Docs-only change; no runtime behavior changes.

Added information on passing multiple filters to pytest.mark.filterwarnings.
@webknjaz webknjaz added type: docs documentation improvement, missing or needing clarification topic: fixtures anything involving fixtures directly or indirectly topic: marks related to marks, either the general marks or builtin skip news used on prs to opt out of the changelog requirement backport 9.0.x labels Mar 6, 2026
@webknjaz webknjaz merged commit ced0a8d into pytest-dev:main Mar 6, 2026
33 checks passed
@patchback

patchback Bot commented Mar 6, 2026

Copy link
Copy Markdown

Backport to 9.0.x: 💚 backport PR created

✅ Backport PR branch: patchback/backports/9.0.x/ced0a8d4a4317f4cb24b4ffb8138deb319dac212/pr-14259

Backported as #14268

🤖 @patchback
I'm built with octomachinery and
my source is open — https://github.com/sanitizers/patchback-github-app.

patchback Bot pushed a commit that referenced this pull request Mar 6, 2026
Docs: clarify multiple arguments in pytest.mark.filterwarnings
(cherry picked from commit ced0a8d)
nicoddemus pushed a commit that referenced this pull request Mar 6, 2026
Docs: clarify multiple arguments in pytest.mark.filterwarnings
(cherry picked from commit ced0a8d)

Co-authored-by: 🇺🇦 Sviatoslav Sydorenko (Святослав Сидоренко) <webknjaz@redhat.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

skip news used on prs to opt out of the changelog requirement topic: fixtures anything involving fixtures directly or indirectly topic: marks related to marks, either the general marks or builtin type: docs documentation improvement, missing or needing clarification

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Clarify docs on specifying multiple filters with pytest.mark.filterwarnings

2 participants