Change the default policy to all

This commit is contained in:
Yusuke Kadowaki
2022-12-25 00:18:38 +09:00
parent b31db4809b
commit 10220d3f31
5 changed files with 28 additions and 11 deletions

View File

@@ -239,7 +239,7 @@ def pytest_addoption(parser: Parser) -> None:
"tmp_path_retention_policy",
help="Controls which directories created by the `tmp_path` fixture are kept around, based on test outcome. "
"(all/failed/none)",
default="failed",
default="all",
)
@@ -267,8 +267,8 @@ def tmp_path(
directory.
By default, a new base temporary directory is created each test session,
and only the base of failed session is kept. Also it only keeps the last 3 bases
at most. This can be configured with :confval:`tmp_path_retention_count` and
and old bases are removed after 3 sessions, to aid in debugging.
This behavior can be configured with :confval:`tmp_path_retention_count` and
:confval:`tmp_path_retention_policy`.
If ``--basetemp`` is used then it is cleared each session. See :ref:`base
temporary directory`.