[Python-checkins] cpython (3.4): Issue #22685: Fix test_pause_reading() of asyncio test_subprocess

victor.stinner python-checkins at python.org
Thu Dec 4 23:09:42 CET 2014


https://hg.python.org/cpython/rev/2c18dd99829c
changeset: 93722:2c18dd99829c
branch: 3.4
user: Victor Stinner <victor.stinner at gmail.com>
date: Thu Dec 04 23:06:13 2014 +0100
summary:
 Issue #22685: Fix test_pause_reading() of asyncio test_subprocess
* mock also resume_reading()
* ensure that resume_reading() is called
files:
 Lib/test/test_asyncio/test_subprocess.py | 2 ++
 1 files changed, 2 insertions(+), 0 deletions(-)
diff --git a/Lib/test/test_asyncio/test_subprocess.py b/Lib/test/test_asyncio/test_subprocess.py
--- a/Lib/test/test_asyncio/test_subprocess.py
+++ b/Lib/test/test_asyncio/test_subprocess.py
@@ -181,6 +181,7 @@
 loop=self.loop)
 stdout_transport = proc._transport.get_pipe_transport(1)
 stdout_transport.pause_reading = mock.Mock()
+ stdout_transport.resume_reading = mock.Mock()
 
 stdout, stderr = yield from proc.communicate()
 
@@ -195,6 +196,7 @@
 
 self.assertEqual(stdout, b'x' * size)
 self.assertTrue(transport.pause_reading.called)
+ self.assertTrue(transport.resume_reading.called)
 
 
 if sys.platform != 'win32':
-- 
Repository URL: https://hg.python.org/cpython


More information about the Python-checkins mailing list

AltStyle によって変換されたページ (->オリジナル) /