[Zodb-checkins] CVS: StandaloneZODB/ZODB/tests - MTStorage.py:1.3

Jeremy Hylton jeremy@zope.com
Tue, 6 Aug 2002 11:05:25 -0400


Update of /cvs-repository/StandaloneZODB/ZODB/tests
In directory cvs.zope.org:/tmp/cvs-serv518/ZODB/tests

Modified Files:
	MTStorage.py 
Log Message:
Make tests robust against threads that never give up.


=== StandaloneZODB/ZODB/tests/MTStorage.py 1.2 => 1.3 ===
 
     def __init__(self, db, test, commits=10, delay=SHORT_DELAY):
         self.__super_init()
+        self.setDaemon(1)
         self.db = db
         self.test = test
         self.commits = commits
@@ -169,7 +170,9 @@
         for t in threads:
             t.start()
         for t in threads:
-            t.join()
+            t.join(10)
+        for t in threads:
+            self.failIf(t.isAlive())
     
     def check2ZODBThreads(self):
         db = ZODB.DB(self._storage)