* Remove PRINT_ITEM(_TO), PRINT_NEWLINE(_TO) opcodes.

* Fix some docstrings and one Print -> print.
* Fix test_{class,code,descrtut,dis,extcall,parser,popen,pkg,subprocess,syntax,traceback}.
  These were the ones that generated code with a print statement.
  In most remaining failing tests there's an issue with the soft space.
This commit is contained in:
Georg Brandl 2007-02-09 21:28:07 +00:00
parent 08c47ba0df
commit 88fc6646d1
31 changed files with 159 additions and 553 deletions

View file

@ -84,7 +84,7 @@ class ProcessTestCase(unittest.TestCase):
def test_stdin_none(self):
# .stdin is None when not redirected
p = subprocess.Popen([sys.executable, "-c", 'print "banana"'],
p = subprocess.Popen([sys.executable, "-c", 'print("banana")'],
stdout=subprocess.PIPE, stderr=subprocess.PIPE)
p.wait()
self.assertEqual(p.stdin, None)
@ -92,16 +92,16 @@ class ProcessTestCase(unittest.TestCase):
def test_stdout_none(self):
# .stdout is None when not redirected
p = subprocess.Popen([sys.executable, "-c",
'print " this bit of output is from a '
'print(" this bit of output is from a '
'test of stdout in a different '
'process ..."'],
'process ...")'],
stdin=subprocess.PIPE, stderr=subprocess.PIPE)
p.wait()
self.assertEqual(p.stdout, None)
def test_stderr_none(self):
# .stderr is None when not redirected
p = subprocess.Popen([sys.executable, "-c", 'print "banana"'],
p = subprocess.Popen([sys.executable, "-c", 'print("banana")'],
stdin=subprocess.PIPE, stdout=subprocess.PIPE)
p.wait()
self.assertEqual(p.stderr, None)