summaryrefslogtreecommitdiffstats
path: root/Lib/test/test_asyncio
diff options
context:
space:
mode:
authorXiang Zhang <angwerzx@126.com>2017-05-15 05:17:01 (GMT)
committerGitHub <noreply@github.com>2017-05-15 05:17:01 (GMT)
commit0ce1f7e02d4102e8a459d1855d689c8e4613a327 (patch)
tree3650f7be9d3d4d3d81051edbb98332a07729a6a0 /Lib/test/test_asyncio
parent61b6e5cf929a80bb44500fb1a212facf66d7f45c (diff)
downloadcpython-0ce1f7e02d4102e8a459d1855d689c8e4613a327.zip
cpython-0ce1f7e02d4102e8a459d1855d689c8e4613a327.tar.gz
cpython-0ce1f7e02d4102e8a459d1855d689c8e4613a327.tar.bz2
bpo-30110: fix resource leak in test_asyncio.test_events (#1413) (#1584)
Diffstat (limited to 'Lib/test/test_asyncio')
-rw-r--r--Lib/test/test_asyncio/test_events.py4
1 files changed, 3 insertions, 1 deletions
diff --git a/Lib/test/test_asyncio/test_events.py b/Lib/test/test_asyncio/test_events.py
index 802763b..492a84a 100644
--- a/Lib/test/test_asyncio/test_events.py
+++ b/Lib/test/test_asyncio/test_events.py
@@ -2194,8 +2194,10 @@ else:
def test_get_event_loop_new_process(self):
async def main():
pool = concurrent.futures.ProcessPoolExecutor()
- return await self.loop.run_in_executor(
+ result = await self.loop.run_in_executor(
pool, _test_get_event_loop_new_process__sub_proc)
+ pool.shutdown()
+ return result
self.unpatch_get_running_loop()