[Updated] D11047: run-tests: setup "correct" python earlier

marmoute (Pierre-Yves David) phabricator at mercurial-scm.org
Sat Jul 10 17:48:50 UTC 2021


marmoute edited the summary of this revision.
marmoute updated this revision to Diff 29135.

REPOSITORY
  rHG Mercurial

CHANGES SINCE LAST UPDATE
  https://phab.mercurial-scm.org/D11047?vs=29102&id=29135

BRANCH
  default

CHANGES SINCE LAST ACTION
  https://phab.mercurial-scm.org/D11047/new/

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

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
@@ -3432,11 +3432,10 @@
             if self.options.list_tests:
                 result = runner.listtests(suite)
             else:
+                self._usecorrectpython()
                 if self._installdir:
                     self._installhg()
                     self._checkhglib("Testing")
-                else:
-                    self._usecorrectpython()
                 if self.options.chg:
                     assert self._installdir
                     self._installchg()
@@ -3718,8 +3717,6 @@
             sys.exit(1)
         os.chdir(self._testdir)
 
-        self._usecorrectpython()
-
         hgbat = os.path.join(self._bindir, b'hg.bat')
         if os.path.isfile(hgbat):
             # hg.bat expects to be put in bin/scripts while run-tests.py



To: marmoute, #hg-reviewers
Cc: mercurial-patches
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.mercurial-scm.org/pipermail/mercurial-patches/attachments/20210710/6b45e4e9/attachment-0002.html>


More information about the Mercurial-patches mailing list