[pypy-commit] pypy py3.3: Call gc.collect() after each test and after having opened many files in CPython's test_bz2.py.
mjacob
noreply at buildbot.pypy.org
Mon Aug 17 15:06:07 CEST 2015
Author: Manuel Jacob <me at manueljacob.de>
Branch: py3.3
Changeset: r79018:abb67a3131df
Date: 2015-08-17 15:06 +0200
http://bitbucket.org/pypy/pypy/changeset/abb67a3131df/
Log: Call gc.collect() after each test and after having opened many files
in CPython's test_bz2.py.
diff --git a/lib-python/3/test/test_bz2.py b/lib-python/3/test/test_bz2.py
--- a/lib-python/3/test/test_bz2.py
+++ b/lib-python/3/test/test_bz2.py
@@ -54,6 +54,7 @@
self.filename = TESTFN
def tearDown(self):
+ support.gc_collect()
if os.path.isfile(self.filename):
os.unlink(self.filename)
@@ -452,6 +453,8 @@
for i in range(10000):
o = BZ2File(self.filename)
del o
+ if i % 100 == 0:
+ support.gc_collect()
def testOpenNonexistent(self):
self.assertRaises(IOError, BZ2File, "/non/existent")
More information about the pypy-commit
mailing list