Skip to content

Commit 5d8b1b1

Browse files
authored
Merge pull request #265 from last-partizan/patch-1
2 parents 6a36e68 + dec1686 commit 5d8b1b1

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

pytest_sugar.py

+2-2
Original file line numberDiff line numberDiff line change
@@ -23,7 +23,7 @@
2323
from _pytest.main import Session
2424
from _pytest.nodes import Item
2525
from _pytest.reports import BaseReport, CollectReport, TestReport
26-
from _pytest.terminal import TerminalReporter
26+
from _pytest.terminal import TerminalReporter, format_session_duration
2727
from termcolor import colored
2828

2929
__version__ = "0.9.6"
@@ -525,7 +525,7 @@ def count(self, key: str, when: tuple = ("call",)) -> int:
525525
def summary_stats(self) -> None:
526526
session_duration = time.time() - self._sessionstarttime
527527

528-
print(f"\nResults ({round(session_duration, 2):.2f}s):")
528+
print(f"\nResults ({format_session_duration(session_duration)}):")
529529
if self.count("passed") > 0:
530530
self.write_line(
531531
colored(" % 5d passed" % self.count("passed"), THEME.success)

0 commit comments

Comments
 (0)