Patchwork D1961: testrunner: fix updating of .testtimes file

login
register
mail settings
Submitter phabricator
Date Feb. 1, 2018, 5:19 p.m.
Message ID <differential-rev-PHID-DREV-q5lklsvoxe4kxzwsbhpf-req@phab.mercurial-scm.org>
Download mbox | patch
Permalink /patch/27104/
State Superseded
Headers show

Comments

phabricator - Feb. 1, 2018, 5:19 p.m.
martinvonz created this revision.
Herald added a subscriber: mercurial-devel.
Herald added a reviewer: hg-reviewers.

REVISION SUMMARY
  We attempt to write the 5 most recent test timings to a file called
  .testtimes, but we read previous results from a file called
  .testtimes- (including the hyphen), so we ended up no more than a
  single time per test.

REPOSITORY
  rHG Mercurial

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

AFFECTED FILES
  tests/run-tests.py

CHANGE DETAILS




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

Patch

diff --git a/tests/run-tests.py b/tests/run-tests.py
--- a/tests/run-tests.py
+++ b/tests/run-tests.py
@@ -2012,7 +2012,7 @@ 
 def loadtimes(outputdir):
     times = []
     try:
-        with open(os.path.join(outputdir, b'.testtimes-')) as fp:
+        with open(os.path.join(outputdir, b'.testtimes')) as fp:
             for line in fp:
                 m = re.match('(.*?) ([0-9. ]+)', line)
                 times.append((m.group(1),