[pypy-commit] pypy default: merge

fijal noreply at buildbot.pypy.org
Wed Apr 3 08:17:38 CEST 2013


Author: Maciej Fijalkowski <fijall at gmail.com>
Branch: 
Changeset: r62935:81f66d14e6f8
Date: 2013-04-03 08:17 +0200
http://bitbucket.org/pypy/pypy/changeset/81f66d14e6f8/

Log:	merge

diff --git a/rpython/rtyper/module/test/test_ll_termios.py b/rpython/rtyper/module/test/test_ll_termios.py
--- a/rpython/rtyper/module/test/test_ll_termios.py
+++ b/rpython/rtyper/module/test/test_ll_termios.py
@@ -18,11 +18,11 @@
 import termios
 print str(termios.tcgetattr(2)[:-1])
 ''')
-    child = pexpect.spawn('python', [str(fname)])
-    child.logfile = sys.stderr
-    x = child.wait()
-    assert x == 0
-    mod.TCGETATTR = child.readlines()[0][:-2]
+    child = pexpect.spawn('python', [str(fname)], logfile=sys.stderr)
+    child.expect(pexpect.EOF)
+    mod.TCGETATTR = child.before[:-2]
+    child.close()
+    assert child.exitstatus == 0
 
 class TestLLTermios(object):
 
@@ -31,7 +31,7 @@
         child = pexpect.spawn(str(arg.builder.executable_name))
         child.expect(re.escape(expected))
         assert child.status is None
-    
+
     def test_tcgetattr(self):
         from rpython.translator.c.test.test_genc import compile
         from rpython.rlib import rtermios
@@ -46,7 +46,7 @@
         from rpython.translator.c.test.test_genc import compile
         from rpython.rlib import rtermios
         import os, errno
-        def runs_tcgetattr(): 
+        def runs_tcgetattr():
             fd = os.open('.', 0, 0777)
             try:
                 rtermios.tcgetattr(fd)
@@ -56,7 +56,7 @@
 
         fn = compile(runs_tcgetattr, [], backendopt=False)
         self.run(fn, "ok")
-        
+
     def test_tcsetattr(self):
         # a test, which doesn't even check anything.
         # I've got no idea how to test it to be honest :-(
@@ -102,4 +102,3 @@
             attr[3] |= termios.ICANON
             rtermios.tcsetattr(2, termios.TCSANOW, attr)
         self.run_test(f)
-


More information about the pypy-commit mailing list