[Zodb-checkins] SVN: ZODB/branches/3.9/src/ZEO/tests/testZEO.py Updated a test to work with or without Python optimization.

Jim Fulton jim at zope.com
Tue Apr 20 17:46:48 EDT 2010


Log message for revision 111192:
  Updated a test to work with or without Python optimization.
  

Changed:
  U   ZODB/branches/3.9/src/ZEO/tests/testZEO.py

-=-
Modified: ZODB/branches/3.9/src/ZEO/tests/testZEO.py
===================================================================
--- ZODB/branches/3.9/src/ZEO/tests/testZEO.py	2010-04-20 20:09:17 UTC (rev 111191)
+++ ZODB/branches/3.9/src/ZEO/tests/testZEO.py	2010-04-20 21:46:48 UTC (rev 111192)
@@ -486,7 +486,10 @@
         # logged
         self._storage._connection.handle_request('foo',0,'history',(1,2,3,4))
         # test logging
-        level,message,kw = log[1]
+        if __debug__:
+            level,message,kw = log[1]
+        else:
+            level,message,kw = log[0]
         self.assertEqual(level,logging.ERROR)
         self.failUnless(message.endswith(
                 ') history() raised exception: history() takes at'



More information about the Zodb-checkins mailing list