diff options
Diffstat (limited to 'Lib/test/test_httpservers.py')
| -rw-r--r-- | Lib/test/test_httpservers.py | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/Lib/test/test_httpservers.py b/Lib/test/test_httpservers.py index 31321c3..49474f6 100644 --- a/Lib/test/test_httpservers.py +++ b/Lib/test/test_httpservers.py @@ -341,13 +341,17 @@ class CGIHTTPServerTestCase(BaseTestCase): def test_main(verbose=None): + cwd = os.getcwd() + env = os.environ.copy() try: - cwd = os.getcwd() test_support.run_unittest(BaseHTTPServerTestCase, SimpleHTTPServerTestCase, CGIHTTPServerTestCase ) finally: + test_support.reap_children() + os.environ.clear() + os.environ.update(env) os.chdir(cwd) if __name__ == '__main__': |
