changeset 19302:a1b8b1b9e2e2

run-tests: always gather runtimes
author Matt Mackall <mpm@selenic.com>
date Fri, 07 Jun 2013 15:56:16 -0500
parents f2dd00f1f6fb
children ef29a552d00d
files tests/run-tests.py
diffstat 1 files changed, 5 insertions(+), 9 deletions(-) [+]
line wrap: on
line diff
--- a/tests/run-tests.py	Wed Jun 05 22:05:29 2013 +0200
+++ b/tests/run-tests.py	Fri Jun 07 15:56:16 2013 -0500
@@ -960,20 +960,16 @@
     env = createenv(options, testtmp, threadtmp, port)
     createhgrc(env['HGRCPATH'], options)
 
-    if options.time:
-        starttime = time.time()
+    starttime = time.time()
     try:
         ret, out = runner(testpath, testtmp, options, replacements, env)
     except KeyboardInterrupt:
-        msg = ''
-        if options.time:
-            endtime = time.time()
-            msg = '(after %d seconds)' % (endtime - starttime)
+        endtime = time.time()
+        msg = '(after %d seconds)' % (endtime - starttime)
         log('INTERRUPTED:', test, msg)
         raise
-    if options.time:
-        endtime = time.time()
-        times.append((test, endtime - starttime))
+    endtime = time.time()
+    times.append((test, endtime - starttime))
     vlog("# Ret was:", ret)
 
     killdaemons(env['DAEMON_PIDS'])