summaryrefslogtreecommitdiff
path: root/src/_pytest/deprecated.py
diff options
context:
space:
mode:
authorRan Benita <ran@unusedvar.com>2020-10-31 22:44:10 +0200
committerRan Benita <ran@unusedvar.com>2020-11-07 17:06:40 +0200
commit4c0513bc18f52b24b69d60c0b1b5e9666e084c06 (patch)
tree1adeaee44cb3f5d7a9d046aa5d1778d04856276c /src/_pytest/deprecated.py
parent3bcd316f076b185bcc89c41a41345861f752aff7 (diff)
downloadpytest-4c0513bc18f52b24b69d60c0b1b5e9666e084c06.tar.gz
fixtures: deprecate pytest.yield_fixture()
Diffstat (limited to 'src/_pytest/deprecated.py')
-rw-r--r--src/_pytest/deprecated.py4
1 files changed, 4 insertions, 0 deletions
diff --git a/src/_pytest/deprecated.py b/src/_pytest/deprecated.py
index a9a162f41..2e9154e83 100644
--- a/src/_pytest/deprecated.py
+++ b/src/_pytest/deprecated.py
@@ -32,6 +32,10 @@ PYTEST_COLLECT_MODULE = UnformattedWarning(
"Please update to the new name.",
)
+YIELD_FIXTURE = PytestDeprecationWarning(
+ "@pytest.yield_fixture is deprecated.\n"
+ "Use @pytest.fixture instead; they are the same."
+)
MINUS_K_DASH = PytestDeprecationWarning(
"The `-k '-expr'` syntax to -k is deprecated.\nUse `-k 'not expr'` instead."