Mercurial > hg
comparison tests/run-tests.py @ 17541:3e3dfa7e6864
tests: unset variable HG if it is set
When hg tries to call itself it can call a different hg executable when this
variable is set. Some tests fail when the called hg version is different.
author | Simon Heimberg <simohe@besonet.ch> |
---|---|
date | Sat, 28 Jul 2012 23:28:17 +0200 |
parents | eddfb9a550d0 |
children | 5b08e8b7ab00 |
comparison
equal
deleted
inserted
replaced
17540:f2bcc5975f10 | 17541:3e3dfa7e6864 |
---|---|
1209 for k in os.environ.keys(): | 1209 for k in os.environ.keys(): |
1210 if k.startswith('HG_'): | 1210 if k.startswith('HG_'): |
1211 # can't remove on solaris | 1211 # can't remove on solaris |
1212 os.environ[k] = '' | 1212 os.environ[k] = '' |
1213 del os.environ[k] | 1213 del os.environ[k] |
1214 if 'HG' in os.environ: | |
1215 # can't remove on solaris | |
1216 os.environ['HG'] = '' | |
1217 del os.environ['HG'] | |
1214 | 1218 |
1215 global TESTDIR, HGTMP, INST, BINDIR, PYTHONDIR, COVERAGE_FILE | 1219 global TESTDIR, HGTMP, INST, BINDIR, PYTHONDIR, COVERAGE_FILE |
1216 TESTDIR = os.environ["TESTDIR"] = os.getcwd() | 1220 TESTDIR = os.environ["TESTDIR"] = os.getcwd() |
1217 if options.tmpdir: | 1221 if options.tmpdir: |
1218 options.keep_tmpdir = True | 1222 options.keep_tmpdir = True |