D1960: testrunner: make reading of test times work with #testcases

martinvonz (Martin von Zweigbergk) phabricator at mercurial-scm.org
Thu Feb 1 17:43:21 EST 2018


This revision was automatically updated to reflect the committed changes.
Closed by commit rHG568917059243: testrunner: make reading of test times work with #testcases (authored by martinvonz, committed by ).

REPOSITORY
  rHG Mercurial

CHANGES SINCE LAST UPDATE
  https://phab.mercurial-scm.org/D1960?vs=5034&id=5088

REVISION DETAIL
  https://phab.mercurial-scm.org/D1960

AFFECTED FILES
  tests/run-tests.py

CHANGE DETAILS

diff --git a/tests/run-tests.py b/tests/run-tests.py
--- a/tests/run-tests.py
+++ b/tests/run-tests.py
@@ -2019,8 +2019,9 @@
     try:
         with open(os.path.join(outputdir, b'.testtimes-')) as fp:
             for line in fp:
-                ts = line.split()
-                times.append((ts[0], [float(t) for t in ts[1:]]))
+                m = re.match('(.*?) ([0-9. ]+)', line)
+                times.append((m.group(1),
+                              [float(t) for t in m.group(2).split()]))
     except IOError as err:
         if err.errno != errno.ENOENT:
             raise



To: martinvonz, #hg-reviewers, durin42
Cc: mercurial-devel


More information about the Mercurial-devel mailing list