diff --git a/CHANGELOG.md b/CHANGELOG.md index 1391dff..c9ae31c 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -6,6 +6,7 @@ The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/), ## [Unreleased] ### Fixed - Fix malformed bullet points rendering in GitHub Pages documentation +- Make `STORE_DURATIONS_TEARDOWN_THRESHOLD` controllable through an environment variable. ## [0.11.0] - 2026-02-03 ### Added diff --git a/src/pytest_split/plugin.py b/src/pytest_split/plugin.py index 9140936..dab4814 100644 --- a/src/pytest_split/plugin.py +++ b/src/pytest_split/plugin.py @@ -17,7 +17,9 @@ # Ugly hack for freezegun compatibility: https://github.com/spulec/freezegun/issues/286 -STORE_DURATIONS_SETUP_AND_TEARDOWN_THRESHOLD = 60 * 10 # seconds +STORE_DURATIONS_SETUP_AND_TEARDOWN_THRESHOLD = float( + os.environ.get("PYTEST_SPLIT_SETUP_TEARDOWN_THRESHOLD", 60 * 10) +) # seconds def pytest_addoption(parser: "Parser") -> None: