-
-
Notifications
You must be signed in to change notification settings - Fork 2k
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.warns(None) usage, deprecated in pytest 7 #6664
Conversation
Deprecated misuse of pytest.warns() https://docs.pytest.org/en/latest/deprecations.html#using-pytest-warns-none
test_session_close_awaitable() does the exact same thing and should throw a deprecation warning already which is caught by the general filter
Codecov Report
@@ Coverage Diff @@
## master #6664 +/- ##
==========================================
- Coverage 93.36% 93.36% -0.01%
==========================================
Files 104 104
Lines 30637 30628 -9
Branches 3080 3077 -3
==========================================
- Hits 28605 28596 -9
Misses 1859 1859
Partials 173 173
Flags with carried forward coverage won't be shown. Click here to find out more.
Continue to review full report at Codecov.
|
Backport to 3.8: 💔 cherry-picking failed — conflicts found❌ Failed to cleanly apply 936e682 on top of patchback/backports/3.8/936e682d1ab6c833b3e5f0cc3596882cb9cb2444/pr-6664 Backporting merged PR #6664 into master
🤖 @patchback |
Backport to 3.9: 💔 cherry-picking failed — conflicts found❌ Failed to cleanly apply 936e682 on top of patchback/backports/3.9/936e682d1ab6c833b3e5f0cc3596882cb9cb2444/pr-6664 Backporting merged PR #6664 into master
🤖 @patchback |
* remove pytest.warns(None) Deprecated misuse of pytest.warns() https://docs.pytest.org/en/latest/deprecations.html#using-pytest-warns-none * Remove duplicate test test_session_close_awaitable() does the exact same thing and should throw a deprecation warning already which is caught by the general filter * PR 6664 metadata * "Fix" spelling. Bots everywhere! * Update 6663.bugfix * Update 6663.bugfix Co-authored-by: Sam Bull <[email protected]> (cherry picked from commit 936e682)
* remove pytest.warns(None) Deprecated misuse of pytest.warns() https://docs.pytest.org/en/latest/deprecations.html#using-pytest-warns-none * Remove duplicate test test_session_close_awaitable() does the exact same thing and should throw a deprecation warning already which is caught by the general filter * PR 6664 metadata * "Fix" spelling. Bots everywhere! * Update 6663.bugfix * Update 6663.bugfix Co-authored-by: Sam Bull <[email protected]> (cherry picked from commit 936e682)
What do these changes do?
Fix a deprecated misuse of pytest.warns()
https://docs.pytest.org/en/latest/deprecations.html#using-pytest-warns-none
Since the test suire errors on any unfiltered warning anyway, these context manageres are not necessary.
Are there changes in behavior for the user?
No. Just the test suite
Related issue number
#6663
Checklist
CONTRIBUTORS.txt
CHANGES
folder<issue_id>.<type>
for example (588.bugfix)issue_id
change it to the pr id after creating the pr.feature
: Signifying a new feature..bugfix
: Signifying a bug fix..doc
: Signifying a documentation improvement..removal
: Signifying a deprecation or removal of public API..misc
: A ticket has been closed, but it is not of interest to users.