From 1fcb189fb89ec179011042d84ec7fc6b7d4ee592 Mon Sep 17 00:00:00 2001
From: Richard Lau <riclau@uk.ibm.com>
Date: Fri, 27 Apr 2018 14:17:30 -0400
Subject: [PATCH] tools: fix TypeError from `test.py --time`

Calculated durations are timedelta objects but the FormatTime function
is expecting a number in seconds.
---
 tools/test.py | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/tools/test.py b/tools/test.py
index e652e47092c55b..9dc99eff518705 100755
--- a/tools/test.py
+++ b/tools/test.py
@@ -1749,7 +1749,7 @@ def DoSkip(case):
     timed_tests.sort(lambda a, b: a.CompareTime(b))
     index = 1
     for entry in timed_tests[:20]:
-      t = FormatTime(entry.duration)
+      t = FormatTime(entry.duration.total_seconds())
       sys.stderr.write("%4i (%s) %s\n" % (index, t, entry.GetLabel()))
       index += 1