summaryrefslogtreecommitdiffstats
path: root/Misc
diff options
context:
space:
mode:
authorMiss Islington (bot) <31488909+miss-islington@users.noreply.github.com>2018-09-13 01:29:08 (GMT)
committerGitHub <noreply@github.com>2018-09-13 01:29:08 (GMT)
commit90f7d455b7f4bd53d3af11cb951347c9c8230399 (patch)
tree0c6ac907f2bd34c8d14319802fa21719a2e6131c /Misc
parentea2fcd3db65b796ad3eda1619a903cefb1aa9363 (diff)
downloadcpython-90f7d455b7f4bd53d3af11cb951347c9c8230399.zip
cpython-90f7d455b7f4bd53d3af11cb951347c9c8230399.tar.gz
cpython-90f7d455b7f4bd53d3af11cb951347c9c8230399.tar.bz2
bpo-34200: Fix non-determinism of test_pkg (GH-9248)
This causes the tearDown code to only unimport the test modules specifically created as part of each test via the self.mkhier method rather than abusing test.support.modules_setup() and the scary test.support.modules_cleanup() code. https://bugs.python.org/issue34200 (cherry picked from commit 4ae8ece5cd4c5853b625381db13429f25512108d) Co-authored-by: Gregory P. Smith <greg@krypto.org>
Diffstat (limited to 'Misc')
-rw-r--r--Misc/NEWS.d/next/Tests/2018-09-12-17-00-34.bpo-34200.dfxYQK.rst3
1 files changed, 3 insertions, 0 deletions
diff --git a/Misc/NEWS.d/next/Tests/2018-09-12-17-00-34.bpo-34200.dfxYQK.rst b/Misc/NEWS.d/next/Tests/2018-09-12-17-00-34.bpo-34200.dfxYQK.rst
new file mode 100644
index 0000000..b53339c
--- /dev/null
+++ b/Misc/NEWS.d/next/Tests/2018-09-12-17-00-34.bpo-34200.dfxYQK.rst
@@ -0,0 +1,3 @@
+Fixed non-deterministic flakiness of test_pkg by not using the scary
+test.support.module_cleanup() logic to save and restore sys.modules contents
+between test cases.