Skip to content

Commit 1b589da

Browse files
committed
deprecated reference
1 parent 0c832ca commit 1b589da

File tree

1 file changed

+10
-0
lines changed

1 file changed

+10
-0
lines changed

doc/en/deprecations.rst

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -252,6 +252,16 @@ or ``pytest.warns(Warning)``.
252252

253253
See :ref:`warns use cases` for examples.
254254

255+
256+
Returning non-None value in test functions
257+
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
258+
259+
.. deprecated:: 7.0
260+
261+
:class:`pytest.PytestReturnNotNoneWarning` will be warn if a test function return values other than None.
262+
It is to avoid typo of an `assert` statement as `return` passes the test without warning or failing regardless of if the test should fail or not..
263+
264+
255265
The ``--strict`` command-line option
256266
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
257267

0 commit comments

Comments
 (0)