tests: unconditionalize _bytes2sys()
authorGregory Szorc <gregory.szorc@gmail.com>
Sun, 20 Feb 2022 13:24:25 -0700
changeset 48863 c76255cde807
parent 48862 2336e79a119c
child 48864 a2f0af520ae5
tests: unconditionalize _bytes2sys() As part of requiring Python 3. Differential Revision: https://phab.mercurial-scm.org/D12241
tests/run-tests.py
--- a/tests/run-tests.py	Sun Feb 20 13:23:21 2022 -0700
+++ b/tests/run-tests.py	Sun Feb 20 13:24:25 2022 -0700
@@ -3790,9 +3790,7 @@
             return self._hgpath
 
         cmd = b'"%s" -c "import mercurial; print (mercurial.__path__[0])"'
-        cmd = cmd % PYTHON
-        if PYTHON3:
-            cmd = _bytes2sys(cmd)
+        cmd = _bytes2sys(cmd % PYTHON)
 
         p = subprocess.Popen(cmd, stdout=subprocess.PIPE, shell=True)
         out, err = p.communicate()