Show More
@@ -759,12 +759,18 b' def main():' | |||||
759 | path = [BINDIR] + os.environ["PATH"].split(os.pathsep) |
|
759 | path = [BINDIR] + os.environ["PATH"].split(os.pathsep) | |
760 | os.environ["PATH"] = os.pathsep.join(path) |
|
760 | os.environ["PATH"] = os.pathsep.join(path) | |
761 |
|
761 | |||
|
762 | # Include TESTDIR in PYTHONPATH so that out-of-tree extensions | |||
|
763 | # can run .../tests/run-tests.py test-foo where test-foo | |||
|
764 | # adds an extension to HGRC | |||
|
765 | pypath = [PYTHONDIR, TESTDIR] | |||
762 | # We have to augment PYTHONPATH, rather than simply replacing |
|
766 | # We have to augment PYTHONPATH, rather than simply replacing | |
763 | # it, in case external libraries are only available via current |
|
767 | # it, in case external libraries are only available via current | |
764 | # PYTHONPATH. (In particular, the Subversion bindings on OS X |
|
768 | # PYTHONPATH. (In particular, the Subversion bindings on OS X | |
765 | # are in /opt/subversion.) |
|
769 | # are in /opt/subversion.) | |
766 | os.environ["PYTHONPATH"] = (PYTHONDIR + os.pathsep + |
|
770 | oldpypath = os.environ.get('PYTHONPATH') | |
767 | os.environ.get("PYTHONPATH", "")) |
|
771 | if oldpypath: | |
|
772 | pypath.append(oldpypath) | |||
|
773 | os.environ['PYTHONPATH'] = os.pathsep.join(pypath) | |||
768 |
|
774 | |||
769 | COVERAGE_FILE = os.path.join(TESTDIR, ".coverage") |
|
775 | COVERAGE_FILE = os.path.join(TESTDIR, ".coverage") | |
770 |
|
776 |
General Comments 0
You need to be logged in to leave comments.
Login now