diff -r 07a7aabca5ce -r 5ac75dd311d5 tests/run-tests.py --- a/tests/run-tests.py Fri Jan 04 20:12:31 2013 +0000 +++ b/tests/run-tests.py Mon Jan 07 23:30:00 2013 +0000 @@ -602,10 +602,13 @@ tdir = TESTDIR.replace('\\', '/') proc = Popen4('%s -c "%s/hghave %s"' % (options.shell, tdir, ' '.join(reqs)), wd, 0) - proc.communicate() + stdout, stderr = proc.communicate() ret = proc.wait() if wifexited(ret): ret = os.WEXITSTATUS(ret) + if ret == 2: + print stdout + sys.exit(1) return ret == 0 f = open(test) @@ -746,7 +749,8 @@ Return a tuple (exitcode, output). output is None in debug mode.""" # TODO: Use subprocess.Popen if we're running on Python 2.4 if options.debug: - proc = subprocess.Popen(cmd, shell=True, cwd=wd) + proc = subprocess.Popen(cmd, shell=True, cwd=wd, stdin=subprocess.PIPE) + proc.stdin.close() ret = proc.wait() return (ret, None)