diff options
author | Nick Coghlan <ncoghlan@gmail.com> | 2007-09-11 14:01:18 (GMT) |
---|---|---|
committer | Nick Coghlan <ncoghlan@gmail.com> | 2007-09-11 14:01:18 (GMT) |
commit | 1df42b118ce2dee4529c81afe3c1add43dfe3419 (patch) | |
tree | c5cc709edc887800c14ded337c2c9491efdd99d1 /Lib | |
parent | 93bf9ce9b7e9ee768c93a5b02b3cbb07b8431563 (diff) | |
download | cpython-1df42b118ce2dee4529c81afe3c1add43dfe3419.zip cpython-1df42b118ce2dee4529c81afe3c1add43dfe3419.tar.gz cpython-1df42b118ce2dee4529c81afe3c1add43dfe3419.tar.bz2 |
Always use the -E flag when spawning subprocesses in test_cmd_line (Issue 1056)
Diffstat (limited to 'Lib')
-rw-r--r-- | Lib/test/test_cmd_line.py | 7 |
1 files changed, 2 insertions, 5 deletions
diff --git a/Lib/test/test_cmd_line.py b/Lib/test/test_cmd_line.py index 9fcd219..2232f4d 100644 --- a/Lib/test/test_cmd_line.py +++ b/Lib/test/test_cmd_line.py @@ -4,7 +4,7 @@ import sys import subprocess def _spawn_python(*args): - cmd_line = [sys.executable] + cmd_line = [sys.executable, '-E'] cmd_line.extend(args) return subprocess.Popen(cmd_line, stdin=subprocess.PIPE, stdout=subprocess.PIPE, stderr=subprocess.STDOUT) @@ -24,7 +24,7 @@ class CmdLineTest(unittest.TestCase): return _kill_python(p) def exit_code(self, *args): - cmd_line = [sys.executable] + cmd_line = [sys.executable, '-E'] cmd_line.extend(args) return subprocess.call(cmd_line, stdout=subprocess.PIPE, stderr=subprocess.PIPE) @@ -38,9 +38,6 @@ class CmdLineTest(unittest.TestCase): self.assertTrue(data == '' or data.endswith('\n')) self.assertTrue('Traceback' not in data) - def test_environment(self): - self.verify_valid_flag('-E') - def test_optimize(self): self.verify_valid_flag('-O') self.verify_valid_flag('-OO') |