summaryrefslogtreecommitdiffstats
path: root/Lib/test
diff options
context:
space:
mode:
authorMartin Panter <vadmium+py@gmail.com>2016-08-20 07:38:21 (GMT)
committerMartin Panter <vadmium+py@gmail.com>2016-08-20 07:38:21 (GMT)
commit051b2201a7f222ac1546ecf1673e426cacccb728 (patch)
tree95b67b211c6cc60c4e12a0270f156df5754724fb /Lib/test
parent332dbc7325639d8ea0932d6322ec9f9c5a51c793 (diff)
parent68c1f1ed034bc0084596e19540910623ecbf64de (diff)
downloadcpython-051b2201a7f222ac1546ecf1673e426cacccb728.zip
cpython-051b2201a7f222ac1546ecf1673e426cacccb728.tar.gz
cpython-051b2201a7f222ac1546ecf1673e426cacccb728.tar.bz2
Issue #27787: Merge regrtest fixup from 3.5
Diffstat (limited to 'Lib/test')
-rw-r--r--Lib/test/libregrtest/save_env.py1
1 files changed, 1 insertions, 0 deletions
diff --git a/Lib/test/libregrtest/save_env.py b/Lib/test/libregrtest/save_env.py
index 5bb9e19..261c8f4 100644
--- a/Lib/test/libregrtest/save_env.py
+++ b/Lib/test/libregrtest/save_env.py
@@ -268,6 +268,7 @@ class saved_test_environment:
def __exit__(self, exc_type, exc_val, exc_tb):
saved_values = self.saved_values
del self.saved_values
+ support.gc_collect() # Some resources use weak references
for name, get, restore in self.resource_info():
current = get()
original = saved_values.pop(name)