Skip to content

Commit

Permalink
docs: add a warning about using timeout_func_only = true in INI alo…
Browse files Browse the repository at this point in the history
…ngside with `pytest.mark` on a test (#160)
  • Loading branch information
olk-m committed Dec 27, 2023
1 parent d91e6d8 commit 4f07f15
Showing 1 changed file with 11 additions and 0 deletions.
11 changes: 11 additions & 0 deletions README.rst
Original file line number Diff line number Diff line change
Expand Up @@ -227,6 +227,17 @@ this really isn't an option a ``timeout_func_only`` boolean setting
exists which can be set in the pytest ini configuration file, as
documented in ``pytest --help``.

For the decorated function, a decorator will override
``timeout_func_only = true`` in the pytest ini file to the default
value. If you need to keep this option for a decorated test, you
must specify the option explicitly again:

.. code:: python
@pytest.mark.timeout(60, func_only=True)
def test_foo():
pass
Debugger Detection
==================
Expand Down

0 comments on commit 4f07f15

Please sign in to comment.