[z3-checkins] r21750 - in z3/Five/trunk: . site

regebro at codespeak.net regebro at codespeak.net
Fri Jan 6 18:50:24 CET 2006


Author: regebro
Date: Fri Jan  6 18:50:22 2006
New Revision: 21750

Modified:
   z3/Five/trunk/CHANGES.txt
   z3/Five/trunk/site/metaconfigure.py
Log:
* If one class was set to have a localsite hook twice, removing the hook would be
  attempted twice during the cleanup of unit tests, and the tests would fail.




Modified: z3/Five/trunk/CHANGES.txt
==============================================================================
--- z3/Five/trunk/CHANGES.txt	(original)
+++ z3/Five/trunk/CHANGES.txt	Fri Jan  6 18:50:22 2006
@@ -28,6 +28,9 @@
 * Fix functional test for local sites and re-enable it for standard
   test runs.
 
+* If one class was set to have a localsite hook twice, removing the hook would be
+  attempted twice during the cleanup of unit tests, and the tests would fail.
+
 Five 1.3c (2005-12-06)
 ======================
 

Modified: z3/Five/trunk/site/metaconfigure.py
==============================================================================
--- z3/Five/trunk/site/metaconfigure.py	(original)
+++ z3/Five/trunk/site/metaconfigure.py	Fri Jan  6 18:50:22 2006
@@ -25,13 +25,14 @@
 
 from Products.Five.site.localsite import FiveSite
 
+_localsite_monkies = []
 def classSiteHook(class_, site_class):
     setattr(class_, 'getSiteManager',
             site_class.getSiteManager.im_func)
     setattr(class_, 'setSiteManager',
             site_class.setSiteManager.im_func)
+    _localsite_monkies.append(class_)
 
-_localsite_monkies = []
 def installSiteHook(_context, class_, site_class=None):
     if site_class is None:
         if not IPossibleSite.implementedBy(class_):
@@ -53,7 +54,6 @@
             callable = classImplements,
             args=(class_, IPossibleSite)
             )
-    _localsite_monkies.append(class_)
 
 # clean up code
 


More information about the z3-checkins mailing list