Update messaging for --durations when not in verbose mode.
This commit is contained in:
parent
fc11b81005
commit
47f5c29002
|
@ -1 +1 @@
|
|||
Exclude 0.00 second entries from ``--duration`` output.
|
||||
Exclude 0.00 second entries from ``--duration`` output unless ``-vv`` is passed on the command-line.
|
||||
|
|
|
@ -269,6 +269,7 @@ To get a list of the slowest 10 test durations::
|
|||
|
||||
pytest --durations=10
|
||||
|
||||
By default, pytest will not show test durations that are too small (<0.01s) unless ``-vv`` is passed on the command-line.
|
||||
|
||||
Creating JUnitXML format files
|
||||
----------------------------------------------------
|
||||
|
|
|
@ -51,6 +51,7 @@ def pytest_terminal_summary(terminalreporter):
|
|||
|
||||
for rep in dlist:
|
||||
if verbose < 2 and rep.duration < 0.01:
|
||||
tr.write_line("0.00 durations hidden. Use -vv to show these durations.")
|
||||
break
|
||||
nodeid = rep.nodeid.replace("::()::", "::")
|
||||
tr.write_line("%02.2fs %-8s %s" % (rep.duration, rep.when, nodeid))
|
||||
|
|
Loading…
Reference in New Issue