[Zodb-checkins] SVN: ZODB/branches/jim-gc/src/BTrees/tests/test Fixed test leaks.

Jim Fulton jim at zope.com
Thu Sep 23 18:55:31 EDT 2010


Log message for revision 116783:
  Fixed test leaks.
  

Changed:
  U   ZODB/branches/jim-gc/src/BTrees/tests/testBTrees.py
  U   ZODB/branches/jim-gc/src/BTrees/tests/testConflict.py
  U   ZODB/branches/jim-gc/src/BTrees/tests/test_compare.py

-=-
Modified: ZODB/branches/jim-gc/src/BTrees/tests/testBTrees.py
===================================================================
--- ZODB/branches/jim-gc/src/BTrees/tests/testBTrees.py	2010-09-23 22:39:58 UTC (rev 116782)
+++ ZODB/branches/jim-gc/src/BTrees/tests/testBTrees.py	2010-09-23 22:55:30 UTC (rev 116783)
@@ -188,7 +188,9 @@
         self.assert_(100 in t)
         self.assert_(not read)
 
+        db.close()
 
+
 class MappingBase(Base):
     """ Tests common to mappings (buckets, btrees) """
 

Modified: ZODB/branches/jim-gc/src/BTrees/tests/testConflict.py
===================================================================
--- ZODB/branches/jim-gc/src/BTrees/tests/testConflict.py	2010-09-23 22:39:58 UTC (rev 116782)
+++ ZODB/branches/jim-gc/src/BTrees/tests/testConflict.py	2010-09-23 22:55:30 UTC (rev 116783)
@@ -42,6 +42,7 @@
         if self.storage is not None:
             self.storage.close()
             self.storage.cleanup()
+            self.db.close()
 
     def openDB(self):
         from ZODB.FileStorage import FileStorage

Modified: ZODB/branches/jim-gc/src/BTrees/tests/test_compare.py
===================================================================
--- ZODB/branches/jim-gc/src/BTrees/tests/test_compare.py	2010-09-23 22:39:58 UTC (rev 116782)
+++ ZODB/branches/jim-gc/src/BTrees/tests/test_compare.py	2010-09-23 22:55:30 UTC (rev 116783)
@@ -42,6 +42,7 @@
         self.assert_(self.bucket._p_changed != 2)
         self.assert_(self.set._p_changed != 2)
         transaction.abort()
+        self.db.close()
 
     def assertUE(self, callable, *args):
         self.assertRaises(UnicodeError, callable, *args)



More information about the Zodb-checkins mailing list