diff options
author | Victor Stinner <victor.stinner@gmail.com> | 2014-12-04 22:06:13 (GMT) |
---|---|---|
committer | Victor Stinner <victor.stinner@gmail.com> | 2014-12-04 22:06:13 (GMT) |
commit | dd8224e6a483a45d7cf2e7be0fa7d818a3f04c80 (patch) | |
tree | 8c6dc1d872cdf46769435083d3da038baf0cc111 /Lib | |
parent | fe22e0985adae5ccfe230c815267fd410de59148 (diff) | |
download | cpython-dd8224e6a483a45d7cf2e7be0fa7d818a3f04c80.zip cpython-dd8224e6a483a45d7cf2e7be0fa7d818a3f04c80.tar.gz cpython-dd8224e6a483a45d7cf2e7be0fa7d818a3f04c80.tar.bz2 |
Issue #22685: Fix test_pause_reading() of asyncio test_subprocess
* mock also resume_reading()
* ensure that resume_reading() is called
Diffstat (limited to 'Lib')
-rw-r--r-- | 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 index c84078d..9060b9d 100644 --- a/Lib/test/test_asyncio/test_subprocess.py +++ b/Lib/test/test_asyncio/test_subprocess.py @@ -181,6 +181,7 @@ class SubprocessMixin: 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 @@ class SubprocessMixin: self.assertEqual(stdout, b'x' * size) self.assertTrue(transport.pause_reading.called) + self.assertTrue(transport.resume_reading.called) if sys.platform != 'win32': |