Skip to content

Commit 246c2d1

Browse files
richardlauMylesBorins
authored andcommitted
tools: fix TypeError from test.py --time
Calculated durations are timedelta objects but the FormatTime function is expecting a number in seconds. PR-URL: #20368 Fixes: #20341 Reviewed-By: Rich Trott <rtrott@gmail.com> Reviewed-By: Trivikram Kamat <trivikr.dev@gmail.com>
1 parent 24a105f commit 246c2d1

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

tools/test.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1745,7 +1745,7 @@ def DoSkip(case):
17451745
timed_tests.sort(lambda a, b: a.CompareTime(b))
17461746
index = 1
17471747
for entry in timed_tests[:20]:
1748-
t = FormatTime(entry.duration)
1748+
t = FormatTime(entry.duration.total_seconds())
17491749
sys.stderr.write("%4i (%s) %s\n" % (index, t, entry.GetLabel()))
17501750
index += 1
17511751

0 commit comments

Comments
 (0)