[Zodb-checkins] CVS: ZODB3/ZEO/tests - ConnectionTests.py:1.31

Jeremy Hylton jeremy at zope.com
Mon Jun 16 15:18:42 EDT 2003


Update of /cvs-repository/ZODB3/ZEO/tests
In directory cvs.zope.org:/tmp/cvs-serv26929

Modified Files:
	ConnectionTests.py 
Log Message:
Be more thorough about deleting ZEC files.


=== ZODB3/ZEO/tests/ConnectionTests.py 1.30 => 1.31 ===
--- ZODB3/ZEO/tests/ConnectionTests.py:1.30	Mon Jun 16 13:37:52 2003
+++ ZODB3/ZEO/tests/ConnectionTests.py	Mon Jun 16 14:18:41 2003
@@ -86,6 +86,7 @@
         self._pids = []
         self._servers = []
         self.conf_paths = []
+        self.caches = []
         self._newAddr()
         self.startServer()
 
@@ -105,13 +106,11 @@
             # Not in Windows Python until 2.3
             for pid in self._pids:
                 os.waitpid(pid, 0)
-        for i in 0, 1:
-            path = "c1-test-%d.zec" % i
-            if os.path.exists(path):
-                try:
+        for c in self.caches:
+            for i in 0, 1:
+                path = "c1-test-%d.zec" % i
+                if os.path.exists(path):
                     os.unlink(path)
-                except os.error:
-                    pass
         self.__super_tearDown()
 
     def _newAddr(self):
@@ -127,6 +126,7 @@
     def openClientStorage(self, cache='', cache_size=200000, wait=1,
                           read_only=0, read_only_fallback=0,
                           username=None, password=None, realm=None):
+        self.caches.append(cache)
         storage = TestClientStorage(self.addr,
                                     client=cache,
                                     cache_size=cache_size,




More information about the Zodb-checkins mailing list