Fix sporadic test_subprocess regression introduced by 834650d63130.

This commit is contained in:
Ross Lagerwall 2012-02-22 06:02:07 +02:00
parent 679be99a85
commit e7ad419058
1 changed files with 2 additions and 2 deletions

View File

@ -688,8 +688,8 @@ class ProcessTestCase(BaseTestCase):
def test_poll(self):
p = subprocess.Popen([sys.executable, "-c",
"import os",
"os.read(1)"], stdin=subprocess.PIPE)
"import os; os.read(0, 1)"],
stdin=subprocess.PIPE)
self.addCleanup(p.stdin.close)
self.assertIsNone(p.poll())
os.write(p.stdin.fileno(), b'A')