tests/run-tests.py
changeset 48863 c76255cde807
parent 48862 2336e79a119c
child 48864 a2f0af520ae5
equal deleted inserted replaced
48862:2336e79a119c 48863:c76255cde807
  3788         the current Python interpreter."""
  3788         the current Python interpreter."""
  3789         if self._hgpath is not None:
  3789         if self._hgpath is not None:
  3790             return self._hgpath
  3790             return self._hgpath
  3791 
  3791 
  3792         cmd = b'"%s" -c "import mercurial; print (mercurial.__path__[0])"'
  3792         cmd = b'"%s" -c "import mercurial; print (mercurial.__path__[0])"'
  3793         cmd = cmd % PYTHON
  3793         cmd = _bytes2sys(cmd % PYTHON)
  3794         if PYTHON3:
       
  3795             cmd = _bytes2sys(cmd)
       
  3796 
  3794 
  3797         p = subprocess.Popen(cmd, stdout=subprocess.PIPE, shell=True)
  3795         p = subprocess.Popen(cmd, stdout=subprocess.PIPE, shell=True)
  3798         out, err = p.communicate()
  3796         out, err = p.communicate()
  3799 
  3797 
  3800         self._hgpath = out.strip()
  3798         self._hgpath = out.strip()