Commit 00cdfaec authored by Tomas Krizek's avatar Tomas Krizek

diffsum: make report duration optional

parent f08eede9
......@@ -28,7 +28,8 @@ def print_global_stats(report: DiffReport) -> None:
if report.total_answers is None or report.total_queries is None:
raise RuntimeError("Report doesn't contain sufficient data to print statistics!")
print('== Global statistics')
print(GLOBAL_STATS_FORMAT.format('duration', '{:d} s'.format(report.duration)))
if report.duration is not None:
print(GLOBAL_STATS_FORMAT.format('duration', '{:d} s'.format(report.duration)))
print(GLOBAL_STATS_FORMAT.format('queries', report.total_queries))
'answers', report.total_answers,
Markdown is supported
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment