Show More
@@ -1709,8 +1709,15 b' class TestRunner(object):' | |||||
1709 |
|
1709 | |||
1710 | if self.options.with_hg: |
|
1710 | if self.options.with_hg: | |
1711 | self._installdir = None |
|
1711 | self._installdir = None | |
1712 | self._bindir = os.path.dirname(os.path.realpath( |
|
1712 | whg = self.options.with_hg | |
1713 | self.options.with_hg)) |
|
1713 | # If --with-hg is not specified, we have bytes already, | |
|
1714 | # but if it was specified in python3 we get a str, so we | |||
|
1715 | # have to encode it back into a bytes. | |||
|
1716 | if sys.version_info[0] == 3: | |||
|
1717 | if not isinstance(whg, bytes): | |||
|
1718 | whg = whg.encode('utf-8') | |||
|
1719 | self._bindir = os.path.dirname(os.path.realpath(whg)) | |||
|
1720 | assert isinstance(self._bindir, bytes) | |||
1714 | self._tmpbindir = os.path.join(self._hgtmp, b'install', b'bin') |
|
1721 | self._tmpbindir = os.path.join(self._hgtmp, b'install', b'bin') | |
1715 | os.makedirs(self._tmpbindir) |
|
1722 | os.makedirs(self._tmpbindir) | |
1716 |
|
1723 |
General Comments 0
You need to be logged in to leave comments.
Login now