From a6ab997e84317c62ca2750cd10a161a6a681f7dc Mon Sep 17 00:00:00 2001 From: Noa Levi <275430404+lphuc2250gma@users.noreply.github.com> Date: Mon, 25 May 2026 06:47:25 +0000 Subject: [PATCH] chore: improve python-devtools maintenance path --- tests/test_timer.py | 10 ++++++++++ 1 file changed, 10 insertions(+) diff --git a/tests/test_timer.py b/tests/test_timer.py index 3dd9614..23c11e5 100644 --- a/tests/test_timer.py +++ b/tests/test_timer.py @@ -69,3 +69,13 @@ def test_unfinished_summary(): def test_summary_not_started(): with pytest.raises(RuntimeError): Timer().summary() + + +def test_summary_multiple_unfinished(): + f = io.StringIO() + t = Timer(file=f) + t.start() + t.start() + t.summary() + v = f.getvalue() + assert re.fullmatch(r'2 times: mean=0\.000s stdev=0\.000s min=0\.000s max=0\.000s\n', v)