[Python-checkins] bpo-31067: test_subprocess calls reap_children() (#2931) (#3073)

Victor Stinner webhook-mailer at python.org
Fri Aug 11 11:14:34 EDT 2017


https://github.com/python/cpython/commit/504939fdf4ebdff47aacfab7876754edeb57bbe1
commit: 504939fdf4ebdff47aacfab7876754edeb57bbe1
branch: 2.7
author: Victor Stinner <victor.stinner at gmail.com>
committer: GitHub <noreply at github.com>
date: 2017-08-11T17:14:31+02:00
summary:

bpo-31067: test_subprocess calls reap_children() (#2931) (#3073)

test_subprocess now also calls reap_children() in tearDown(), not
only on setUp().
(cherry picked from commit cc42c121eb5346f673247f95dac575aadb77d66c)

files:
M Lib/test/test_subprocess.py

diff --git a/Lib/test/test_subprocess.py b/Lib/test/test_subprocess.py
index ce3372354cf..a5a727efd62 100644
--- a/Lib/test/test_subprocess.py
+++ b/Lib/test/test_subprocess.py
@@ -57,6 +57,8 @@ def tearDown(self):
             inst.wait()
         subprocess._cleanup()
         self.assertFalse(subprocess._active, "subprocess._active not empty")
+        self.doCleanups()
+        test_support.reap_children()
 
     def assertStderrEqual(self, stderr, expected, msg=None):
         # In a debug build, stuff like "[6580 refs]" is printed to stderr at



More information about the Python-checkins mailing list