Show More
@@ -444,7 +444,7 b' class Test(unittest.TestCase):' | |||
|
444 | 444 | debug=False, |
|
445 | 445 | timeout=defaults['timeout'], |
|
446 | 446 | startport=defaults['port'], extraconfigopts=None, |
|
447 | py3kwarnings=False, shell=None, | |
|
447 | py3kwarnings=False, shell=None, hgcommand=None, | |
|
448 | 448 | slowtimeout=defaults['slowtimeout']): |
|
449 | 449 | """Create a test from parameters. |
|
450 | 450 | |
@@ -491,6 +491,7 b' class Test(unittest.TestCase):' | |||
|
491 | 491 | self._extraconfigopts = extraconfigopts or [] |
|
492 | 492 | self._py3kwarnings = py3kwarnings |
|
493 | 493 | self._shell = _bytespath(shell) |
|
494 | self._hgcommand = hgcommand or b'hg' | |
|
494 | 495 | |
|
495 | 496 | self._aborted = False |
|
496 | 497 | self._daemonpids = [] |
@@ -989,6 +990,8 b' class TTest(Test):' | |||
|
989 | 990 | |
|
990 | 991 | if self._debug: |
|
991 | 992 | script.append(b'set -x\n') |
|
993 | if self._hgcommand != b'hg': | |
|
994 | script.append(b'alias hg="%s"\n' % self._hgcommand) | |
|
992 | 995 | if os.getenv('MSYSTEM'): |
|
993 | 996 | script.append(b'alias pwd="pwd -W"\n') |
|
994 | 997 | |
@@ -1817,6 +1820,7 b' class TestRunner(object):' | |||
|
1817 | 1820 | self._pythondir = None |
|
1818 | 1821 | self._coveragefile = None |
|
1819 | 1822 | self._createdfiles = [] |
|
1823 | self._hgcommand = None | |
|
1820 | 1824 | self._hgpath = None |
|
1821 | 1825 | self._portoffset = 0 |
|
1822 | 1826 | self._ports = {} |
@@ -1925,6 +1929,7 b' class TestRunner(object):' | |||
|
1925 | 1929 | whg = self.options.with_hg |
|
1926 | 1930 | self._bindir = os.path.dirname(os.path.realpath(whg)) |
|
1927 | 1931 | assert isinstance(self._bindir, bytes) |
|
1932 | self._hgcommand = os.path.basename(whg) | |
|
1928 | 1933 | self._tmpbindir = os.path.join(self._hgtmp, b'install', b'bin') |
|
1929 | 1934 | os.makedirs(self._tmpbindir) |
|
1930 | 1935 | |
@@ -1937,6 +1942,7 b' class TestRunner(object):' | |||
|
1937 | 1942 | else: |
|
1938 | 1943 | self._installdir = os.path.join(self._hgtmp, b"install") |
|
1939 | 1944 | self._bindir = os.path.join(self._installdir, b"bin") |
|
1945 | self._hgcommand = b'hg' | |
|
1940 | 1946 | self._tmpbindir = self._bindir |
|
1941 | 1947 | self._pythondir = os.path.join(self._installdir, b"lib", b"python") |
|
1942 | 1948 | |
@@ -2117,7 +2123,8 b' class TestRunner(object):' | |||
|
2117 | 2123 | startport=self._getport(count), |
|
2118 | 2124 | extraconfigopts=self.options.extra_config_opt, |
|
2119 | 2125 | py3kwarnings=self.options.py3k_warnings, |
|
2120 |
shell=self.options.shell |
|
|
2126 | shell=self.options.shell, | |
|
2127 | hgcommand=self._hgcommand) | |
|
2121 | 2128 | t.should_reload = True |
|
2122 | 2129 | return t |
|
2123 | 2130 |
General Comments 0
You need to be logged in to leave comments.
Login now