[Checkins] SVN: gocept.selenium/branches/wosc-zodb-isolation/src/gocept/selenium/zope2/__init__.py Update SandboxPatch to be compatible both with Zope2-2.10 and Zope2-2.12

Wolfgang Schnerring wosc at wosc.de
Sun Dec 26 08:48:28 EST 2010


Log message for revision 119128:
  Update SandboxPatch to be compatible both with Zope2-2.10 and Zope2-2.12
  

Changed:
  U   gocept.selenium/branches/wosc-zodb-isolation/src/gocept/selenium/zope2/__init__.py

-=-
Modified: gocept.selenium/branches/wosc-zodb-isolation/src/gocept/selenium/zope2/__init__.py
===================================================================
--- gocept.selenium/branches/wosc-zodb-isolation/src/gocept/selenium/zope2/__init__.py	2010-12-26 13:43:32 UTC (rev 119127)
+++ gocept.selenium/branches/wosc-zodb-isolation/src/gocept/selenium/zope2/__init__.py	2010-12-26 13:48:27 UTC (rev 119128)
@@ -76,9 +76,9 @@
 
     def _app(self):
         Zope2.startup()
-        db, aname, version = Zope2.bobo_application._stuff
+        stuff = Zope2.bobo_application._stuff
         db = Testing.ZopeTestCase.ZopeLite.sandbox()
-        Zope2.bobo_application._stuff = db, aname, version
+        Zope2.bobo_application._stuff = (db,) + stuff[1:]
         app = Zope2.bobo_application()
         app = Testing.ZopeTestCase.utils.makerequest(app)
         Testing.ZopeTestCase.connections.register(app)
@@ -87,8 +87,7 @@
 
 def get_current_db():
     """helper for gocept.selenium.tests.isolation"""
-    db, aname, version = Zope2.bobo_application._stuff
-    return db
+    return Zope2.bobo_application._stuff[0]
 
 
 class TestCase(gocept.selenium.base.TestCase,



More information about the checkins mailing list