We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent cd1ce97 commit 676ab58Copy full SHA for 676ab58
testing/test_recwarn.py
@@ -404,13 +404,12 @@ def test_match_regex(self) -> None:
404
with pytest.warns(FutureWarning, match=r"must be \d+$"):
405
warnings.warn("value must be 42", UserWarning)
406
407
- def test_keep_ignores():
+ def test_keep_ignores(self) -> None:
408
with warnings.catch_warnings:
409
warnings.filterwarnings("error", category=UserWarning)
410
with pytest.warns(UserWarning, keep_ignores=True):
411
warnings.warn("keep this warning", UserWarning)
412
413
- def test_keep_ignores_():
414
with pytest.raises(pytest.fail.Exception, match="DID NOT WARN"):
415
416
warnings.filterwarnings("ignore", message="ignore this")
0 commit comments