[CMF-checkins] SVN: CMF/branches/2.1/ - some import and whitespace syncing with trunk

Yvo Schubbe y.2007- at wcm-solutions.de
Thu Jun 28 15:06:19 EDT 2007


Log message for revision 77186:
  - some import and whitespace syncing with trunk

Changed:
  U   CMF/branches/2.1/CMFCalendar/Event.py
  U   CMF/branches/2.1/CMFCalendar/tests/test_Event.py
  U   CMF/branches/2.1/CMFCore/ActionInformation.py
  U   CMF/branches/2.1/CMFCore/ActionProviderBase.py
  U   CMF/branches/2.1/CMFCore/CachingPolicyManager.py
  U   CMF/branches/2.1/CMFCore/FSSTXMethod.py
  U   CMF/branches/2.1/CMFCore/MemberDataTool.py
  U   CMF/branches/2.1/CMFCore/PortalContent.py
  U   CMF/branches/2.1/CMFCore/PortalFolder.py
  U   CMF/branches/2.1/CMFCore/TypesTool.py
  U   CMF/branches/2.1/CMFCore/URLTool.py
  U   CMF/branches/2.1/CMFCore/UndoTool.py
  U   CMF/branches/2.1/CMFCore/exportimport/actions.py
  U   CMF/branches/2.1/CMFCore/fiveactionstool.py
  U   CMF/branches/2.1/CMFCore/interfaces/_content.py
  U   CMF/branches/2.1/CMFCore/tests/base/testcase.py
  U   CMF/branches/2.1/CMFCore/tests/test_CatalogTool.py
  U   CMF/branches/2.1/CMFCore/tests/test_FSSecurity.py
  U   CMF/branches/2.1/CMFCore/tests/test_TypesTool.py
  U   CMF/branches/2.1/CMFCore/tests/test_URLTool.py
  U   CMF/branches/2.1/CMFDefault/DublinCore.py
  U   CMF/branches/2.1/CMFDefault/File.py
  U   CMF/branches/2.1/CMFDefault/Image.py
  U   CMF/branches/2.1/CMFDefault/MembershipTool.py
  U   CMF/branches/2.1/CMFDefault/NewsItem.py
  U   CMF/branches/2.1/CMFDefault/SyndicationTool.py
  U   CMF/branches/2.1/CMFDefault/formlib/widgets.py
  U   CMF/branches/2.1/CMFDefault/skins/zpt_control/portal_config_control.py
  U   CMF/branches/2.1/CMFDefault/tests/test_DefaultWorkflow.py
  U   CMF/branches/2.1/CMFDefault/tests/test_Document.py
  U   CMF/branches/2.1/CMFDefault/tests/test_DublinCore.py
  U   CMF/branches/2.1/CMFDefault/tests/test_File.py
  U   CMF/branches/2.1/CMFDefault/tests/test_Image.py
  U   CMF/branches/2.1/CMFTopic/DateCriteria.py
  U   CMF/branches/2.1/CMFTopic/SimpleStringCriterion.py
  U   CMF/branches/2.1/CMFTopic/SortCriterion.py
  U   CMF/branches/2.1/CMFTopic/skins/zpt_topic/friendlydatec_editform.pt
  U   CMF/branches/2.1/CMFTopic/skins/zpt_topic/listc_edit.pt
  U   CMF/branches/2.1/CMFTopic/skins/zpt_topic/sort_edit.pt
  U   CMF/branches/2.1/CMFTopic/skins/zpt_topic/topic_criteria_form.pt
  U   CMF/branches/2.1/CMFUid/UniqueIdGeneratorTool.py
  U   CMF/branches/2.1/CMFUid/UniqueIdHandlerTool.py
  U   CMF/branches/2.1/CMFUid/interfaces.py
  U   CMF/branches/2.1/DCWorkflow/interfaces.py
  U   CMF/branches/2.1/DCWorkflow/tests/test_DCWorkflow.py
  U   CMF/branches/2.1/functest/creator/scaffolding.py
  U   CMF/branches/2.1/functest/visitor/scaffolding.py

-=-
Modified: CMF/branches/2.1/CMFCalendar/Event.py
===================================================================
--- CMF/branches/2.1/CMFCalendar/Event.py	2007-06-28 17:46:03 UTC (rev 77185)
+++ CMF/branches/2.1/CMFCalendar/Event.py	2007-06-28 19:06:19 UTC (rev 77186)
@@ -292,7 +292,7 @@
         """ Return our end time as a DateTime object
         """
         date = getattr( self, 'end_date', None )
-        return date is None and self.start() or date    
+        return date is None and self.start() or date
 
     security.declarePublic('getStartTimeString')
     def getStartTimeString( self ):

Modified: CMF/branches/2.1/CMFCalendar/tests/test_Event.py
===================================================================
--- CMF/branches/2.1/CMFCalendar/tests/test_Event.py	2007-06-28 17:46:03 UTC (rev 77185)
+++ CMF/branches/2.1/CMFCalendar/tests/test_Event.py	2007-06-28 19:06:19 UTC (rev 77186)
@@ -145,7 +145,7 @@
         self.assertEqual( d.Title(), 'Test Event' )
         self.assertEqual( d.Format(), 'text/html' )
         self.assertEqual( d.Description().strip()
-                        , 'Fundraiser for disabled goldfish' 
+                        , 'Fundraiser for disabled goldfish'
                         )
         self.assertEqual( d.Subject(), ('Foosubject',) )
         self.assertEqual( d.Contributors(), ('Jim',) )

Modified: CMF/branches/2.1/CMFCore/ActionInformation.py
===================================================================
--- CMF/branches/2.1/CMFCore/ActionInformation.py	2007-06-28 17:46:03 UTC (rev 77185)
+++ CMF/branches/2.1/CMFCore/ActionInformation.py	2007-06-28 19:06:19 UTC (rev 77186)
@@ -36,9 +36,9 @@
 from utils import _checkPermission
 from utils import getToolByName
 
-
 _unchanged = [] # marker
 
+
 class ActionCategory(IFAwareObjectManager, OrderedFolder):
 
     """ Group of Action objects.
@@ -493,6 +493,7 @@
 
 
 class oai:
+
     #Provided for backwards compatability
     # Provides information that may be needed when constructing the list of
     # available actions.
@@ -525,4 +526,3 @@
         if hasattr(self, name):
             return getattr(self, name)
         raise KeyError, name
-

Modified: CMF/branches/2.1/CMFCore/ActionProviderBase.py
===================================================================
--- CMF/branches/2.1/CMFCore/ActionProviderBase.py	2007-06-28 17:46:03 UTC (rev 77185)
+++ CMF/branches/2.1/CMFCore/ActionProviderBase.py	2007-06-28 19:06:19 UTC (rev 77186)
@@ -32,6 +32,7 @@
 
 
 class ActionProviderBase:
+
     """ Provide ActionTabs and management methods for ActionProviders
     """
 

Modified: CMF/branches/2.1/CMFCore/CachingPolicyManager.py
===================================================================
--- CMF/branches/2.1/CMFCore/CachingPolicyManager.py	2007-06-28 17:46:03 UTC (rev 77185)
+++ CMF/branches/2.1/CMFCore/CachingPolicyManager.py	2007-06-28 19:06:19 UTC (rev 77186)
@@ -32,13 +32,13 @@
 from zope.app.container.interfaces import IObjectMovedEvent
 from zope.interface import implements
 
-from permissions import ManagePortal
-from permissions import View
 from Expression import Expression
 from interfaces import ICachingPolicy
 from interfaces import ICachingPolicyManager
 from interfaces.CachingPolicyManager \
         import CachingPolicyManager as z2ICachingPolicyManager
+from permissions import ManagePortal
+from permissions import View
 from utils import _dtmldir
 from utils import _setCacheHeaders
 from utils import _ViewEmulator
@@ -130,7 +130,7 @@
             with access to the following top-level names:
 
             'object' -- the object itself
-            
+
             'view' -- the name of the view method
 
             'keywords' -- keywords passed to the request
@@ -182,9 +182,9 @@
              'must_revalidate=1' argument => "must-revalidate" token
 
              'proxy_revalidate=1' argument => "proxy-revalidate" token
-             
+
              'public=1' argument => "public" token
-             
+
              'private=1' argument => "private" token
 
              'no_transform=1' argument => "no-transform" token
@@ -255,7 +255,7 @@
                 pre_check = None
             else:
                 pre_check = int(pre_check)
-            
+
         if post_check is not None:
             if str(post_check).strip() == '':
                 post_check = None
@@ -375,7 +375,7 @@
         """
         """
         return getattr(self, '_post_check', None)
-    
+
     def testPredicate(self, expr_context):
         """ Does this request match our predicate?"""
         return self._predicate(expr_context)
@@ -405,7 +405,7 @@
                 exp_time_str = rfc1123_date(now.timeTime() + self._max_age_secs)
                 headers.append( ( 'Expires', exp_time_str ) )
                 control.append( 'max-age=%d' % self._max_age_secs )
-                
+
             if self.getSMaxAgeSecs() is not None:
                 control.append( 's-maxage=%d' % self._s_max_age_secs )
 
@@ -528,7 +528,7 @@
             s_max_age_secs = None
         else:
             s_max_age_secs = int(s_max_age_secs)
-            
+
         if pre_check is None or str(pre_check).strip() == '':
             pre_check = None
         else:
@@ -599,7 +599,7 @@
             s_max_age_secs = None
         else:
             s_max_age_secs = int(s_max_age_secs)
-            
+
         if pre_check is None or str(pre_check).strip() == '':
             pre_check = None
         else:
@@ -851,7 +851,7 @@
         context = createCPContext( content, view_method, keywords, time=time )
         for policy_id, policy in self.listPolicies():
             if policy.getEnable304s() and policy.testPredicate(context):
-                
+
                 last_modified = policy._mtime_func(context)
                 if type(last_modified) is type(''):
                     last_modified = DateTime(last_modified)
@@ -859,9 +859,9 @@
                 content_etag = None
                 if policy.getETagFunc():
                     content_etag = policy._etag_func(context)
-                    
+
                 return (last_modified, content_etag, policy.getLastModified())
-            
+
         return None
 
     #

Modified: CMF/branches/2.1/CMFCore/FSSTXMethod.py
===================================================================
--- CMF/branches/2.1/CMFCore/FSSTXMethod.py	2007-06-28 17:46:03 UTC (rev 77185)
+++ CMF/branches/2.1/CMFCore/FSSTXMethod.py	2007-06-28 19:06:19 UTC (rev 77186)
@@ -19,7 +19,6 @@
 from AccessControl import ClassSecurityInfo
 from DocumentTemplate.DT_HTML import HTML as DTML_HTML
 from Globals import DTMLFile
-from Globals import HTML as Global_HTML
 from Globals import InitializeClass
 from OFS.DTMLDocument import DTMLDocument
 from StructuredText.StructuredText import HTML as STX_HTML

Modified: CMF/branches/2.1/CMFCore/MemberDataTool.py
===================================================================
--- CMF/branches/2.1/CMFCore/MemberDataTool.py	2007-06-28 17:46:03 UTC (rev 77185)
+++ CMF/branches/2.1/CMFCore/MemberDataTool.py	2007-06-28 19:06:19 UTC (rev 77186)
@@ -39,7 +39,6 @@
 from utils import registerToolInterface
 from utils import UniqueObject
 
-
 _marker = []  # Create a new marker object.
 
 

Modified: CMF/branches/2.1/CMFCore/PortalContent.py
===================================================================
--- CMF/branches/2.1/CMFCore/PortalContent.py	2007-06-28 17:46:03 UTC (rev 77185)
+++ CMF/branches/2.1/CMFCore/PortalContent.py	2007-06-28 19:06:19 UTC (rev 77186)
@@ -15,10 +15,10 @@
 $Id$
 """
 
+from AccessControl import ClassSecurityInfo
+from Acquisition import aq_base
 from Globals import InitializeClass
-from Acquisition import aq_base
 from OFS.SimpleItem import SimpleItem
-from AccessControl import ClassSecurityInfo
 from webdav.WriteLockInterface import WriteLockInterface as z2IWriteLock
 from zope.interface import implements
 

Modified: CMF/branches/2.1/CMFCore/PortalFolder.py
===================================================================
--- CMF/branches/2.1/CMFCore/PortalFolder.py	2007-06-28 17:46:03 UTC (rev 77185)
+++ CMF/branches/2.1/CMFCore/PortalFolder.py	2007-06-28 19:06:19 UTC (rev 77186)
@@ -24,9 +24,8 @@
 from AccessControl import getSecurityManager
 from Acquisition import aq_parent, aq_inner, aq_base
 from Globals import InitializeClass
+from OFS.Folder import Folder
 from OFS.OrderSupport import OrderSupport
-from OFS.Folder import Folder
-
 from zope.component.factory import Factory
 from zope.interface import implements
 
@@ -506,9 +505,10 @@
 
 
 class ContentFilter:
+
+    """Represent a predicate against a content object's metadata.
     """
-        Represent a predicate against a content object's metadata.
-    """
+
     MARKER = []
     filterSubject = []
     def __init__( self

Modified: CMF/branches/2.1/CMFCore/TypesTool.py
===================================================================
--- CMF/branches/2.1/CMFCore/TypesTool.py	2007-06-28 17:46:03 UTC (rev 77185)
+++ CMF/branches/2.1/CMFCore/TypesTool.py	2007-06-28 19:06:19 UTC (rev 77186)
@@ -52,10 +52,8 @@
 from utils import SimpleItemWithProperties
 from utils import UniqueObject
 
-
 logger = logging.getLogger('CMFCore.TypesTool')
 
-
 _marker = []  # Create a new marker.
 
 
@@ -753,4 +751,3 @@
         return rval
 
 InitializeClass(TypesTool)
-

Modified: CMF/branches/2.1/CMFCore/URLTool.py
===================================================================
--- CMF/branches/2.1/CMFCore/URLTool.py	2007-06-28 17:46:03 UTC (rev 77185)
+++ CMF/branches/2.1/CMFCore/URLTool.py	2007-06-28 19:06:19 UTC (rev 77186)
@@ -21,7 +21,6 @@
 from Globals import DTMLFile
 from Globals import InitializeClass
 from OFS.SimpleItem import SimpleItem
-
 from zope.interface import implements
 
 from ActionProviderBase import ActionProviderBase

Modified: CMF/branches/2.1/CMFCore/UndoTool.py
===================================================================
--- CMF/branches/2.1/CMFCore/UndoTool.py	2007-06-28 17:46:03 UTC (rev 77185)
+++ CMF/branches/2.1/CMFCore/UndoTool.py	2007-06-28 19:06:19 UTC (rev 77186)
@@ -19,9 +19,9 @@
 from Globals import DTMLFile
 from Globals import InitializeClass
 from OFS.SimpleItem import SimpleItem
+from zope.component import queryUtility
 from zope.interface import implements
 
-from zope.component import queryUtility
 from exceptions import AccessControl_Unauthorized
 from interfaces import ISiteRoot
 from interfaces import IUndoTool
@@ -119,4 +119,3 @@
 
 InitializeClass(UndoTool)
 registerToolInterface('portal_undo', IUndoTool)
-

Modified: CMF/branches/2.1/CMFCore/exportimport/actions.py
===================================================================
--- CMF/branches/2.1/CMFCore/exportimport/actions.py	2007-06-28 17:46:03 UTC (rev 77185)
+++ CMF/branches/2.1/CMFCore/exportimport/actions.py	2007-06-28 19:06:19 UTC (rev 77186)
@@ -15,6 +15,8 @@
 $Id$
 """
 
+from zope.component import adapts
+
 from Products.GenericSetup.interfaces import ISetupEnviron
 from Products.GenericSetup.utils import exportObjects
 from Products.GenericSetup.utils import I18NURI
@@ -32,8 +34,6 @@
         import ActionProvider as z2IActionProvider
 from Products.CMFCore.utils import getToolByName
 
-from zope.component import adapts
-
 _SPECIAL_PROVIDERS = ('portal_actions', 'portal_types', 'portal_workflow')
 
 
@@ -145,8 +145,8 @@
     def _extractOldstyleActions(self, provider_id):
         # BBB: for CMF 1.6 profiles
         fragment = self._doc.createDocumentFragment()
+
         provider = getToolByName(self.context, provider_id)
-
         if not (IActionProvider.providedBy(provider) or
                 z2IActionProvider.isImplementedBy(provider)):
             return fragment

Modified: CMF/branches/2.1/CMFCore/fiveactionstool.py
===================================================================
--- CMF/branches/2.1/CMFCore/fiveactionstool.py	2007-06-28 17:46:03 UTC (rev 77185)
+++ CMF/branches/2.1/CMFCore/fiveactionstool.py	2007-06-28 19:06:19 UTC (rev 77186)
@@ -18,9 +18,8 @@
 from AccessControl import ClassSecurityInfo
 from Globals import InitializeClass
 from OFS.SimpleItem import SimpleItem
-from Products.Five import security
-from zope.app.publisher.interfaces.browser import IBrowserMenu
 from zope.app.publisher.browser.menu import getMenu
+from zope.app.publisher.interfaces.browser import IBrowserMenu
 from zope.component import getUtilitiesFor
 
 from Products.CMFCore.ActionInformation import ActionInformation
@@ -50,7 +49,7 @@
     security.declarePrivate('listActions')
     def listActions(self, info=None, object=None):
         """ List all the actions defined by a provider.
-        """       
+        """
         if object is None:
             if  info is None:
                 # There is no support for global actions
@@ -69,7 +68,7 @@
                     act_id = 'action_%s' % action
                 else:
                     act_id = 'action_%s_%s' % (object.getId(), action)
-                    
+
                 if entry.get('filter') is None:
                     filter = None
                 else:
@@ -91,7 +90,7 @@
                     category=str(menu_id),
                     visible=1)
                 actions.append(act)
-                
+
         return tuple(actions)
 
 InitializeClass( FiveActionsTool )

Modified: CMF/branches/2.1/CMFCore/interfaces/_content.py
===================================================================
--- CMF/branches/2.1/CMFCore/interfaces/_content.py	2007-06-28 17:46:03 UTC (rev 77185)
+++ CMF/branches/2.1/CMFCore/interfaces/_content.py	2007-06-28 19:06:19 UTC (rev 77186)
@@ -16,7 +16,6 @@
 """
 
 from zope.interface import Interface
-from zope.interface import Attribute
 
 
 #

Modified: CMF/branches/2.1/CMFCore/tests/base/testcase.py
===================================================================
--- CMF/branches/2.1/CMFCore/tests/base/testcase.py	2007-06-28 17:46:03 UTC (rev 77185)
+++ CMF/branches/2.1/CMFCore/tests/base/testcase.py	2007-06-28 19:06:19 UTC (rev 77186)
@@ -65,7 +65,6 @@
         if self._old_stderr is not None:
             return
 
-        import sys
         from StringIO import StringIO
 
         self._old_stderr = sys.stderr
@@ -76,7 +75,6 @@
         if self._old_stderr is None:
             return
 
-        import sys
         sys.stderr = self._old_stderr
 
 

Modified: CMF/branches/2.1/CMFCore/tests/test_CatalogTool.py
===================================================================
--- CMF/branches/2.1/CMFCore/tests/test_CatalogTool.py	2007-06-28 17:46:03 UTC (rev 77185)
+++ CMF/branches/2.1/CMFCore/tests/test_CatalogTool.py	2007-06-28 19:06:19 UTC (rev 77186)
@@ -19,7 +19,6 @@
 import Testing
 
 from AccessControl.SecurityManagement import newSecurityManager
-from AccessControl.SecurityManagement import noSecurityManager
 from DateTime import DateTime
 
 from Products.CMFCore.tests.base.dummy import DummyContent

Modified: CMF/branches/2.1/CMFCore/tests/test_FSSecurity.py
===================================================================
--- CMF/branches/2.1/CMFCore/tests/test_FSSecurity.py	2007-06-28 17:46:03 UTC (rev 77185)
+++ CMF/branches/2.1/CMFCore/tests/test_FSSecurity.py	2007-06-28 19:06:19 UTC (rev 77186)
@@ -49,8 +49,8 @@
                 self.assertEqual((acquire, expected), (acquired, got))
                 happy = 1
         if not happy:
-            raise ValueError("'%s' not found in permissions: %s"
-                             % (permissionname, all_names))
+            raise ValueError("'%s' not found in inherited permissions."
+                             % permissionname)
 
     def setUp( self ):
         # initialise skins

Modified: CMF/branches/2.1/CMFCore/tests/test_TypesTool.py
===================================================================
--- CMF/branches/2.1/CMFCore/tests/test_TypesTool.py	2007-06-28 17:46:03 UTC (rev 77185)
+++ CMF/branches/2.1/CMFCore/tests/test_TypesTool.py	2007-06-28 19:06:19 UTC (rev 77186)
@@ -37,7 +37,6 @@
 from Products.CMFCore.tests.base.dummy import DummyFactoryDispatcher
 from Products.CMFCore.tests.base.dummy import DummyContent
 from Products.CMFCore.tests.base.dummy import DummyFolder
-from Products.CMFCore.tests.base.dummy import DummyObject
 from Products.CMFCore.tests.base.dummy import DummySite
 from Products.CMFCore.tests.base.dummy import DummyUserFolder
 from Products.CMFCore.tests.base.security import OmnipotentUser

Modified: CMF/branches/2.1/CMFCore/tests/test_URLTool.py
===================================================================
--- CMF/branches/2.1/CMFCore/tests/test_URLTool.py	2007-06-28 17:46:03 UTC (rev 77185)
+++ CMF/branches/2.1/CMFCore/tests/test_URLTool.py	2007-06-28 19:06:19 UTC (rev 77186)
@@ -19,6 +19,7 @@
 import Testing
 
 from zope.component import getSiteManager
+from zope.testing.cleanup import cleanUp
 
 from Products.CMFCore.interfaces import ISiteRoot
 from Products.CMFCore.tests.base.dummy import DummyContent
@@ -33,6 +34,9 @@
         sm = getSiteManager()
         sm.registerUtility(self.site, ISiteRoot)
 
+    def tearDown(self):
+        cleanUp()
+
     def _makeOne(self, *args, **kw):
         from Products.CMFCore.URLTool import URLTool
 

Modified: CMF/branches/2.1/CMFDefault/DublinCore.py
===================================================================
--- CMF/branches/2.1/CMFDefault/DublinCore.py	2007-06-28 17:46:03 UTC (rev 77185)
+++ CMF/branches/2.1/CMFDefault/DublinCore.py	2007-06-28 19:06:19 UTC (rev 77186)
@@ -36,9 +36,9 @@
 
 from permissions import ModifyPortalContent
 from permissions import View
-from utils import tuplize
 from utils import _dtmldir
 from utils import semi_split
+from utils import tuplize
 
 _marker=[]
 

Modified: CMF/branches/2.1/CMFDefault/File.py
===================================================================
--- CMF/branches/2.1/CMFDefault/File.py	2007-06-28 17:46:03 UTC (rev 77185)
+++ CMF/branches/2.1/CMFDefault/File.py	2007-06-28 19:06:19 UTC (rev 77186)
@@ -20,15 +20,15 @@
 import OFS.Image
 from AccessControl import ClassSecurityInfo
 from Globals import InitializeClass
+from OFS.Cache import Cacheable
 from zope.component.factory import Factory
 from zope.interface import implements
-from OFS.Cache import Cacheable
 
 from Products.CMFCore.PortalContent import PortalContent
+from Products.CMFCore.utils import _checkConditionalGET
 from Products.CMFCore.utils import _OldCacheHeaders
 from Products.CMFCore.utils import _setCacheHeaders
 from Products.CMFCore.utils import _ViewEmulator
-from Products.CMFCore.utils import _checkConditionalGET
 from Products.GenericSetup.interfaces import IDAVAware
 
 from DublinCore import DefaultDublinCoreImpl
@@ -67,7 +67,7 @@
                , description, contributors, effective_date, expiration_date
                , format, language, rights
                )
-    
+
     # Add the File instance to self
     self._setObject(id, fobj)
 
@@ -216,10 +216,10 @@
     security.declareProtected(View, 'download')
     def download(self, REQUEST, RESPONSE):
         """Download this item.
-        
+
         Calls OFS.Image.File.index_html to perform the actual transfer after
         first setting Content-Disposition to suggest a filename.
-        
+
         This method is deprecated, use the URL of this object itself. Because
         the default view of a File object is to download, rather than view,
         this method is obsolete. Also note that certain browsers do not deal

Modified: CMF/branches/2.1/CMFDefault/Image.py
===================================================================
--- CMF/branches/2.1/CMFDefault/Image.py	2007-06-28 17:46:03 UTC (rev 77185)
+++ CMF/branches/2.1/CMFDefault/Image.py	2007-06-28 19:06:19 UTC (rev 77186)
@@ -19,15 +19,15 @@
 import OFS.Image
 from AccessControl import ClassSecurityInfo
 from Globals import InitializeClass
+from OFS.Cache import Cacheable
 from zope.component.factory import Factory
 from zope.interface import implements
-from OFS.Cache import Cacheable
 
 from Products.CMFCore.PortalContent import PortalContent
+from Products.CMFCore.utils import _checkConditionalGET
 from Products.CMFCore.utils import _OldCacheHeaders
 from Products.CMFCore.utils import _setCacheHeaders
 from Products.CMFCore.utils import _ViewEmulator
-from Products.CMFCore.utils import _checkConditionalGET
 from Products.GenericSetup.interfaces import IDAVAware
 
 from DublinCore import DefaultDublinCoreImpl
@@ -66,7 +66,7 @@
                 , description, contributors, effective_date, expiration_date
                 , format, language, rights
                 )
-    
+
     # Add the Image instance to self
     self._setObject(id, iobj)
 

Modified: CMF/branches/2.1/CMFDefault/MembershipTool.py
===================================================================
--- CMF/branches/2.1/CMFDefault/MembershipTool.py	2007-06-28 17:46:03 UTC (rev 77185)
+++ CMF/branches/2.1/CMFDefault/MembershipTool.py	2007-06-28 19:06:19 UTC (rev 77186)
@@ -37,7 +37,6 @@
 from permissions import View
 from utils import _dtmldir
 
-
 DEFAULT_MEMBER_CONTENT = """\
 Default page for %s
 
@@ -49,7 +48,7 @@
 """
 
 
-class MembershipTool( BaseTool ):
+class MembershipTool(BaseTool):
 
     """ Implement 'portal_membership' interface using "stock" policies.
     """
@@ -214,4 +213,3 @@
             return None
 
 InitializeClass(MembershipTool)
-

Modified: CMF/branches/2.1/CMFDefault/NewsItem.py
===================================================================
--- CMF/branches/2.1/CMFDefault/NewsItem.py	2007-06-28 17:46:03 UTC (rev 77185)
+++ CMF/branches/2.1/CMFDefault/NewsItem.py	2007-06-28 19:06:19 UTC (rev 77186)
@@ -24,7 +24,6 @@
 from interfaces import IMutableNewsItem
 from interfaces import INewsItem
 from permissions import ModifyPortalContent
-from permissions import View
 
 
 def addNewsItem( self

Modified: CMF/branches/2.1/CMFDefault/SyndicationTool.py
===================================================================
--- CMF/branches/2.1/CMFDefault/SyndicationTool.py	2007-06-28 17:46:03 UTC (rev 77185)
+++ CMF/branches/2.1/CMFDefault/SyndicationTool.py	2007-06-28 19:06:19 UTC (rev 77186)
@@ -23,7 +23,6 @@
 from Globals import HTMLFile
 from Globals import InitializeClass
 from OFS.SimpleItem import SimpleItem
-
 from zope.interface import implements
 
 from Products.CMFCore.interfaces import ISyndicationTool
@@ -389,4 +388,3 @@
 
 InitializeClass(SyndicationTool)
 registerToolInterface('portal_syndication', ISyndicationTool)
-

Modified: CMF/branches/2.1/CMFDefault/formlib/widgets.py
===================================================================
--- CMF/branches/2.1/CMFDefault/formlib/widgets.py	2007-06-28 17:46:03 UTC (rev 77185)
+++ CMF/branches/2.1/CMFDefault/formlib/widgets.py	2007-06-28 19:06:19 UTC (rev 77186)
@@ -32,7 +32,6 @@
 from zope.schema import Tuple
 from zope.schema.interfaces import ISet
 from zope.schema.interfaces import ITuple
-from zope.schema.interfaces import ITextLine
 
 from Products.CMFCore.interfaces import IMetadataTool
 from Products.CMFDefault.exceptions import IllegalHTML

Modified: CMF/branches/2.1/CMFDefault/skins/zpt_control/portal_config_control.py
===================================================================
--- CMF/branches/2.1/CMFDefault/skins/zpt_control/portal_config_control.py	2007-06-28 17:46:03 UTC (rev 77185)
+++ CMF/branches/2.1/CMFDefault/skins/zpt_control/portal_config_control.py	2007-06-28 19:06:19 UTC (rev 77186)
@@ -1,9 +1,9 @@
 ##parameters=**kw
 ##
-from Products.CMFCore.utils import getToolByName
+from Products.CMFCore.utils import getToolByInterfaceName
 from Products.CMFDefault.utils import Message as _
 
-ptool = getToolByName(script, 'portal_properties')
+ptool = getToolByInterfaceName('Products.CMFCore.interfaces.IPropertiesTool')
 
 if not ptool.hasProperty('default_charset'):
     ptool.manage_addProperty('default_charset', '', 'string')

Modified: CMF/branches/2.1/CMFDefault/tests/test_DefaultWorkflow.py
===================================================================
--- CMF/branches/2.1/CMFDefault/tests/test_DefaultWorkflow.py	2007-06-28 17:46:03 UTC (rev 77185)
+++ CMF/branches/2.1/CMFDefault/tests/test_DefaultWorkflow.py	2007-06-28 19:06:19 UTC (rev 77186)
@@ -22,7 +22,6 @@
 from Products.CMFCore.tests.base.dummy import DummySite
 from Products.CMFCore.tests.base.dummy import DummyTool
 from Products.CMFCore.tests.base.dummy import DummyUserFolder
-
 from Products.CMFCore.WorkflowTool import WorkflowTool
 
 

Modified: CMF/branches/2.1/CMFDefault/tests/test_Document.py
===================================================================
--- CMF/branches/2.1/CMFDefault/tests/test_Document.py	2007-06-28 17:46:03 UTC (rev 77185)
+++ CMF/branches/2.1/CMFDefault/tests/test_Document.py	2007-06-28 19:06:19 UTC (rev 77186)
@@ -24,8 +24,8 @@
 from re import compile
 from StringIO import StringIO
 
+from DocumentTemplate.DT_Util import html_quote
 from Products.PageTemplates.ZopePageTemplate import ZopePageTemplate
-from DocumentTemplate.DT_Util import html_quote
 
 from Products.CMFCore.testing import ConformsToContent
 from Products.CMFCore.tests.base.content import BASIC_HTML

Modified: CMF/branches/2.1/CMFDefault/tests/test_DublinCore.py
===================================================================
--- CMF/branches/2.1/CMFDefault/tests/test_DublinCore.py	2007-06-28 17:46:03 UTC (rev 77185)
+++ CMF/branches/2.1/CMFDefault/tests/test_DublinCore.py	2007-06-28 19:06:19 UTC (rev 77186)
@@ -21,7 +21,6 @@
 from AccessControl.SecurityManagement import newSecurityManager
 from Acquisition import Implicit
 from DateTime.DateTime import DateTime
-
 from zope.testing.cleanup import cleanUp
 
 from Products.CMFCore.tests.base.dummy import DummySite

Modified: CMF/branches/2.1/CMFDefault/tests/test_File.py
===================================================================
--- CMF/branches/2.1/CMFDefault/tests/test_File.py	2007-06-28 17:46:03 UTC (rev 77185)
+++ CMF/branches/2.1/CMFDefault/tests/test_File.py	2007-06-28 19:06:19 UTC (rev 77186)
@@ -23,9 +23,9 @@
 from zope.testing.cleanup import cleanUp
 
 from Products.CMFCore.testing import ConformsToContent
+from Products.CMFCore.tests.base.dummy import DummyCachingManager
 from Products.CMFCore.tests.base.dummy import DummyCachingManagerWithPolicy
-from Products.CMFCore.tests.base.dummy import DummyCachingManager
-from Products.CMFCore.tests.base.testcase import RequestTest 
+from Products.CMFCore.tests.base.testcase import RequestTest
 from Products.CMFDefault import tests
 
 TESTS_HOME = tests.__path__[0]
@@ -116,7 +116,7 @@
 
         from webdav.common import rfc1123_date
         from Products.CMFCore.tests.base.dummy import FAKE_ETAG
-        
+
         file = self._makeOne( 'test_file', 'test_file.swf', file=ref )
         file = file.__of__( self.root )
 
@@ -137,7 +137,7 @@
         path, ref = self._extractFile()
 
         from webdav.common import rfc1123_date
-        
+
         file = self._makeOne( 'test_file', 'test_file.swf', file=ref )
         file = file.__of__( self.root )
 

Modified: CMF/branches/2.1/CMFDefault/tests/test_Image.py
===================================================================
--- CMF/branches/2.1/CMFDefault/tests/test_Image.py	2007-06-28 17:46:03 UTC (rev 77185)
+++ CMF/branches/2.1/CMFDefault/tests/test_Image.py	2007-06-28 19:06:19 UTC (rev 77186)
@@ -21,12 +21,11 @@
 from os.path import join as path_join
 from cStringIO import StringIO
 
-from zope.app.component.hooks import setSite
-from zope.testing.cleanup import cleanUp
-
 import transaction
 from AccessControl.SecurityManagement import newSecurityManager
 from AccessControl.User import UnrestrictedUser
+from zope.app.component.hooks import setSite
+from zope.testing.cleanup import cleanUp
 
 from Products.CMFCore.testing import ConformsToContent
 from Products.CMFCore.tests.base.dummy import DummyCachingManager

Modified: CMF/branches/2.1/CMFTopic/DateCriteria.py
===================================================================
--- CMF/branches/2.1/CMFTopic/DateCriteria.py	2007-06-28 17:46:03 UTC (rev 77185)
+++ CMF/branches/2.1/CMFTopic/DateCriteria.py	2007-06-28 19:06:19 UTC (rev 77186)
@@ -150,7 +150,7 @@
                                           } ), )
                     else:
                         return ( ( field, { 'query': date.earliestTime()
-                                          , 'range': operation 
+                                          , 'range': operation
                                           } ), )
                 else:
                     # Value 0 means "Now", so get everything from now on

Modified: CMF/branches/2.1/CMFTopic/SimpleStringCriterion.py
===================================================================
--- CMF/branches/2.1/CMFTopic/SimpleStringCriterion.py	2007-06-28 17:46:03 UTC (rev 77185)
+++ CMF/branches/2.1/CMFTopic/SimpleStringCriterion.py	2007-06-28 19:06:19 UTC (rev 77186)
@@ -45,21 +45,21 @@
         self.id = id
         self.field = field
         self.value = ''
-        
+
     security.declareProtected( ChangeTopics, 'getEditForm' )
     def getEditForm( self ):
         """
             Return the skinned name of the edit form.
         """
         return 'ssc_edit'
-    
+
     security.declareProtected( ChangeTopics, 'edit' )
     def edit( self, value ):
         """
             Update the value we are to match up against.
         """
         self.value = str( value )
-    
+
     security.declareProtected(View, 'getCriteriaItems')
     def getCriteriaItems( self ):
         """
@@ -72,7 +72,6 @@
 
         return tuple( result )
 
-
 InitializeClass( SimpleStringCriterion )
 
 # Register as a criteria type with the Topic class

Modified: CMF/branches/2.1/CMFTopic/SortCriterion.py
===================================================================
--- CMF/branches/2.1/CMFTopic/SortCriterion.py	2007-06-28 17:46:03 UTC (rev 77185)
+++ CMF/branches/2.1/CMFTopic/SortCriterion.py	2007-06-28 19:06:19 UTC (rev 77186)
@@ -49,7 +49,7 @@
         self.id = id
         self.index = index
         self.reversed = 0
-        
+
     # inherit permissions
     def Field( self ):
         """
@@ -64,14 +64,14 @@
             used to edit this kind of criterion.
         """
         return 'sort_edit'
-    
+
     security.declareProtected( ChangeTopics, 'edit' )
     def edit( self, reversed ):
         """
             Update the value we are to match up against.
         """
         self.reversed = bool(reversed)
-    
+
     security.declareProtected(View, 'getCriteriaItems')
     def getCriteriaItems( self ):
         """

Modified: CMF/branches/2.1/CMFTopic/skins/zpt_topic/friendlydatec_editform.pt
===================================================================
--- CMF/branches/2.1/CMFTopic/skins/zpt_topic/friendlydatec_editform.pt	2007-06-28 17:46:03 UTC (rev 77185)
+++ CMF/branches/2.1/CMFTopic/skins/zpt_topic/friendlydatec_editform.pt	2007-06-28 19:06:19 UTC (rev 77186)
@@ -2,7 +2,7 @@
  <tr>
   <td width="20">
    <input type="checkbox" value="" name="criterion_ids:list" id=""
-        tal:attributes="value here/getId; id string:cb_${here/getId}">
+        tal:attributes="value here/getId; id string:cb_${here/getId}" />
   </td>
   <td align="left">
    <label for="" tal:attributes="for string:cb_${here/getId}">

Modified: CMF/branches/2.1/CMFTopic/skins/zpt_topic/listc_edit.pt
===================================================================
--- CMF/branches/2.1/CMFTopic/skins/zpt_topic/listc_edit.pt	2007-06-28 17:46:03 UTC (rev 77185)
+++ CMF/branches/2.1/CMFTopic/skins/zpt_topic/listc_edit.pt	2007-06-28 19:06:19 UTC (rev 77186)
@@ -2,7 +2,7 @@
  <tr>
   <td width="20">
    <input type="checkbox" value="" name="criterion_ids:list" id=""
-          tal:attributes="value here/getId; id string:cb_${here/getId}">
+          tal:attributes="value here/getId; id string:cb_${here/getId}" />
   </td>
   <td align="left">
    <label for="" tal:attributes="for string:cb_${here/getId}">
@@ -10,17 +10,17 @@
     <tt tal:content="here/Field">Field</tt>
    </label>
    <input type="hidden" name="criteria.id:records" value=""
-          tal:attributes="value here/getId">
+          tal:attributes="value here/getId" />
   </td>
  </tr>
  <tr valign="top">
   <td width="20">&nbsp;</td>
   <td valign="top">
-   <strong>Value:</strong><br>
+   <strong>Value:</strong><br />
    <textarea name="criteria.value:lines:records" rows="5" cols="40"
              tal:content="python:modules['string'].join(here.value, '\n')"
-   ></textarea><br>
-   <strong>Operator:</strong><br>
+   ></textarea><br />
+   <strong>Operator:</strong><br />
    <select name="criteria.operator:records">
     <option value=""
             tal:attributes="selected not: here/operator">-- none --</option>

Modified: CMF/branches/2.1/CMFTopic/skins/zpt_topic/sort_edit.pt
===================================================================
--- CMF/branches/2.1/CMFTopic/skins/zpt_topic/sort_edit.pt	2007-06-28 17:46:03 UTC (rev 77185)
+++ CMF/branches/2.1/CMFTopic/skins/zpt_topic/sort_edit.pt	2007-06-28 19:06:19 UTC (rev 77186)
@@ -2,7 +2,7 @@
  <tr>
   <td width="20">
    <input type="checkbox" value="" name="criterion_ids:list" id=""
-          tal:attributes="value here/getId; id string:cb_${here/getId}">
+          tal:attributes="value here/getId; id string:cb_${here/getId}" />
   </td>
   <td align="left">
    <label for=""
@@ -16,7 +16,7 @@
  <tr>
   <td width="20">&nbsp;</td>
   <td><strong>Reversed?</strong>
-  <input type="hidden" name="criteria.reversed::int:default:records" value="0">
+  <input type="hidden" name="criteria.reversed::int:default:records" value="0" />
   <input type="checkbox" name="criteria.reversed:records" value="1"
          tal:attributes="checked here/reversed"/>
   </td>

Modified: CMF/branches/2.1/CMFTopic/skins/zpt_topic/topic_criteria_form.pt
===================================================================
--- CMF/branches/2.1/CMFTopic/skins/zpt_topic/topic_criteria_form.pt	2007-06-28 17:46:03 UTC (rev 77185)
+++ CMF/branches/2.1/CMFTopic/skins/zpt_topic/topic_criteria_form.pt	2007-06-28 19:06:19 UTC (rev 77186)
@@ -12,10 +12,10 @@
     </span>
 </span>
 <input type="submit" name="topic_editCriteria:action"
-       value=" Save changes "> &nbsp;&nbsp;
+       value=" Save changes " /> &nbsp;&nbsp;
 <input type="submit" name="topic_deleteCriteria:action"
-       value=" Delete selected ">
-<input type="hidden" name=":default_action" value="editCriteria">
+       value=" Delete selected " />
+<input type="hidden" name=":default_action" value="editCriteria" />
 </form>
 
 <form action="" method="post" tal:attributes="action string:${context/absolute_url}/topic_addCriterion">
@@ -39,7 +39,7 @@
 </tr>
 <tr>
     <td>&nbsp;</td>
-    <td><input type="submit" value=" Add "></td>
+    <td><input type="submit" value=" Add " /></td>
 </tr>
 </table>
 </form>

Modified: CMF/branches/2.1/CMFUid/UniqueIdGeneratorTool.py
===================================================================
--- CMF/branches/2.1/CMFUid/UniqueIdGeneratorTool.py	2007-06-28 17:46:03 UTC (rev 77185)
+++ CMF/branches/2.1/CMFUid/UniqueIdGeneratorTool.py	2007-06-28 19:06:19 UTC (rev 77186)
@@ -25,13 +25,14 @@
 
 from Products.CMFCore.utils import registerToolInterface
 from Products.CMFCore.utils import UniqueObject
+
 from Products.CMFUid.interfaces import IUniqueIdGenerator
 
 
 class UniqueIdGeneratorTool(UniqueObject, SimpleItem):
 
     """Generator of unique ids.
-    
+
     This is a dead simple implementation using a counter. May cause
     ConflictErrors under high load and the values are predictable.
     """
@@ -75,4 +76,3 @@
 
 InitializeClass(UniqueIdGeneratorTool)
 registerToolInterface('portal_uidgenerator', IUniqueIdGenerator)
-

Modified: CMF/branches/2.1/CMFUid/UniqueIdHandlerTool.py
===================================================================
--- CMF/branches/2.1/CMFUid/UniqueIdHandlerTool.py	2007-06-28 17:46:03 UTC (rev 77185)
+++ CMF/branches/2.1/CMFUid/UniqueIdHandlerTool.py	2007-06-28 19:06:19 UTC (rev 77186)
@@ -27,7 +27,6 @@
 from Globals import package_home
 from OFS.SimpleItem import SimpleItem
 from Products.PageTemplates.PageTemplateFile import PageTemplateFile
-
 from zope.component import getUtility
 from zope.interface import implements
 
@@ -77,6 +76,8 @@
     security = ClassSecurityInfo()
 
     def _reindexObject(self, obj):
+        # XXX: this method violates the rules for tools/utilities:
+        # it depends on a non-utility tool
         # add uid index and colums to catalog if not yet done
         UID_ATTRIBUTE_NAME = self.UID_ATTRIBUTE_NAME
         catalog = getToolByName(obj, 'portal_catalog')
@@ -261,4 +262,3 @@
     manage_queryObject = PageTemplateFile('queryUID.pt', _wwwdir)
 
 InitializeClass(UniqueIdHandlerTool)
-

Modified: CMF/branches/2.1/CMFUid/interfaces.py
===================================================================
--- CMF/branches/2.1/CMFUid/interfaces.py	2007-06-28 17:46:03 UTC (rev 77185)
+++ CMF/branches/2.1/CMFUid/interfaces.py	2007-06-28 19:06:19 UTC (rev 77186)
@@ -20,7 +20,6 @@
 """
 
 from zope.interface import Interface
-from zope.interface import Attribute
 
 from Products.CMFCore.interfaces import ICallableOpaqueItem
 from Products.CMFCore.interfaces import ICallableOpaqueItemEvents

Modified: CMF/branches/2.1/DCWorkflow/interfaces.py
===================================================================
--- CMF/branches/2.1/DCWorkflow/interfaces.py	2007-06-28 17:46:03 UTC (rev 77185)
+++ CMF/branches/2.1/DCWorkflow/interfaces.py	2007-06-28 19:06:19 UTC (rev 77186)
@@ -45,4 +45,4 @@
     
     """An event that's fired after a workflow transition.
     """
-    
+

Modified: CMF/branches/2.1/DCWorkflow/tests/test_DCWorkflow.py
===================================================================
--- CMF/branches/2.1/DCWorkflow/tests/test_DCWorkflow.py	2007-06-28 17:46:03 UTC (rev 77185)
+++ CMF/branches/2.1/DCWorkflow/tests/test_DCWorkflow.py	2007-06-28 19:06:19 UTC (rev 77186)
@@ -26,8 +26,8 @@
 from Products.CMFCore.tests.base.dummy import DummySite
 from Products.CMFCore.tests.base.dummy import DummyTool
 from Products.CMFCore.WorkflowTool import WorkflowTool
+from Products.DCWorkflow.interfaces import IAfterTransitionEvent
 from Products.DCWorkflow.interfaces import IBeforeTransitionEvent
-from Products.DCWorkflow.interfaces import IAfterTransitionEvent
 
 
 class DCWorkflowDefinitionTests(unittest.TestCase):
@@ -100,28 +100,28 @@
         # XXX more
 
     def test_events(self):
-        
+
         events = []
-        
+
         @adapter(IBeforeTransitionEvent)
         def _handleBefore(event):
             events.append(event)
         provideHandler(_handleBefore)
-    
+
         @adapter(IAfterTransitionEvent)
         def _handleAfter(event):
             events.append(event)
         provideHandler(_handleAfter)
-        
+
         wftool = self.site.portal_workflow
         wf = self._getDummyWorkflow()
 
         dummy = self.site._setObject( 'dummy', DummyContent() )
         wftool.notifyCreated(dummy)
         wf.doActionFor(dummy, 'publish', comment='foo', test='bar')
-        
+
         self.assertEquals(4, len(events))
-        
+
         evt = events[0]
         self.failUnless(IBeforeTransitionEvent.providedBy(evt))
         self.assertEquals(dummy, evt.object)
@@ -130,7 +130,7 @@
         self.assertEquals(None, evt.transition)
         self.assertEquals({}, evt.status)
         self.assertEquals(None, evt.kwargs)
-        
+
         evt = events[1]
         self.failUnless(IAfterTransitionEvent.providedBy(evt))
         self.assertEquals(dummy, evt.object)
@@ -139,7 +139,7 @@
         self.assertEquals(None, evt.transition)
         self.assertEquals({}, evt.status)
         self.assertEquals(None, evt.kwargs)
-        
+
         evt = events[2]
         self.failUnless(IBeforeTransitionEvent.providedBy(evt))
         self.assertEquals(dummy, evt.object)
@@ -148,7 +148,7 @@
         self.assertEquals('publish', evt.transition.id)
         self.assertEquals({'state': 'private', 'comments': ''}, evt.status)
         self.assertEquals({'test' : 'bar', 'comment' : 'foo'}, evt.kwargs)
-        
+
         evt = events[3]
         self.failUnless(IAfterTransitionEvent.providedBy(evt))
         self.assertEquals(dummy, evt.object)

Modified: CMF/branches/2.1/functest/creator/scaffolding.py
===================================================================
--- CMF/branches/2.1/functest/creator/scaffolding.py	2007-06-28 17:46:03 UTC (rev 77185)
+++ CMF/branches/2.1/functest/creator/scaffolding.py	2007-06-28 19:06:19 UTC (rev 77186)
@@ -15,7 +15,7 @@
     constructing the functional tests.
 """
 
-from Products.CMFCore.PortalFolder import PortalFolder
+import transaction
 
 def submit_news_setup( app, test_vars, result ):
     """
@@ -45,7 +45,7 @@
     if newsitem_id in folder.objectIds():
         folder.manage_delObjects( ids=[newsitem_id] )
     
-    get_transaction().commit()
+    transaction.commit()
 
     return 1
 
@@ -65,7 +65,7 @@
                                 % ( userid, newsitem_id ) )
     assert wf_tool.getInfoFor( newsitem, 'review_state' ) == 'pending'
     
-    get_transaction().commit()
+    transaction.commit()
 
     return 1
 
@@ -81,4 +81,4 @@
     if newsitem_id in folder.objectIds():
         folder.manage_delObjects( ids=[newsitem_id] )
     
-    get_transaction().commit()
+    transaction.commit()

Modified: CMF/branches/2.1/functest/visitor/scaffolding.py
===================================================================
--- CMF/branches/2.1/functest/visitor/scaffolding.py	2007-06-28 17:46:03 UTC (rev 77185)
+++ CMF/branches/2.1/functest/visitor/scaffolding.py	2007-06-28 19:06:19 UTC (rev 77186)
@@ -18,7 +18,6 @@
 import string
 
 from Products.CMFCore.PortalFolder import PortalFolder
-from Products.CMFDefault.NewsItem import NewsItem
 
 #
 #   Fake out security (blech!)
@@ -26,6 +25,7 @@
 from AccessControl.SecurityManagement import newSecurityManager
 from AccessControl.SecurityManagement import noSecurityManager
 import Acquisition
+import transaction
 
 
 class FTUser( Acquisition.Implicit ):
@@ -276,7 +276,7 @@
         Ensure that we have at least the one expected piece of content.
     """
     _setup_test_news( app, test_vars )
-    get_transaction().commit()
+    transaction.commit()
     return 1
 
 def advanced_search_teardown( app, test_vars, result ):
@@ -284,7 +284,7 @@
         Ensure that we scrub any content we created.
     """
     _teardown_test_news( app, test_vars )
-    get_transaction().commit()
+    transaction.commit()
 
 #
 #   become_member.zft
@@ -297,7 +297,7 @@
     site        = app.unrestrictedTraverse( site_path )
 
     _scrubMember( site, userid, 1 )
-    get_transaction().commit()
+    transaction.commit()
     return 1
 
 def become_member_postcondition( app, test_vars, result ):
@@ -322,7 +322,7 @@
     site        = app.unrestrictedTraverse( site_path )
 
     _scrubMember( site, userid )
-    get_transaction().commit()
+    transaction.commit()
 
 #
 #   browse_news.zft
@@ -332,7 +332,7 @@
         Ensure that we have at least the one expected piece of content.
     """
     _setup_test_news( app, test_vars )
-    get_transaction().commit()
+    transaction.commit()
     return 1
 
 def browse_news_teardown( app, test_vars, result ):
@@ -340,7 +340,7 @@
         Ensure that we scrub any content we created.
     """
     _teardown_test_news( app, test_vars )
-    get_transaction().commit()
+    transaction.commit()
 
 #
 #   browse_topic.zft
@@ -352,14 +352,14 @@
     _setup_test_user( app, test_vars )
     _setup_test_news( app, test_vars )
     _setup_test_topic( app, test_vars )
-    get_transaction().commit()
+    transaction.commit()
     return 1
 
 def browse_topic_teardown( app, test_vars, result ):
     _teardown_test_topic( app, test_vars )
     _teardown_test_news( app, test_vars )
     _teardown_test_user( app, test_vars )
-    get_transaction().commit()
+    transaction.commit()
  
 #
 #   log_in.zft
@@ -368,14 +368,14 @@
     """
     """
     _setup_test_user( app, test_vars )
-    get_transaction().commit()
+    transaction.commit()
     return 1
 
 def log_in_teardown( app, test_vars, result ):
     """
     """
     _teardown_test_user( app, test_vars )
-    get_transaction().commit()
+    transaction.commit()
 #
 #   provide_feeback.zft
 #
@@ -394,7 +394,7 @@
 
     _setup_test_news( app, test_vars )
     _setup_test_user( app, test_vars )
-    get_transaction().commit()
+    transaction.commit()
     return 1
 
 def provide_feedback_postcondition( app, test_vars, result ):
@@ -415,7 +415,7 @@
 
     _teardown_test_user( app, test_vars )
     _teardown_test_news( app, test_vars )
-    get_transaction().commit()
+    transaction.commit()
 #
 #   quick_search.zft
 #
@@ -425,10 +425,10 @@
     # results page, merely that we can execute these requests.
     _setup_test_news( app, test_vars )
     _setup_test_user( app, test_vars )
-    get_transaction().commit()
+    transaction.commit()
     return 1
 
 def quick_search_teardown( app, test_vars, result ):
     _teardown_test_user( app, test_vars )
     _teardown_test_news( app, test_vars )
-    get_transaction().commit()
+    transaction.commit()



More information about the CMF-checkins mailing list