[CMF-checkins] CVS: CMF/CMFCore/tests/base - content.py:1.4.12.1 dummy.py:1.6.4.5 security.py:1.3.4.1 testcase.py:1.5.16.3 utils.py:1.2.44.1

Sidnei da Silva sidnei at awkly.org
Thu Apr 22 13:48:28 EDT 2004


Update of /cvs-repository/CMF/CMFCore/tests/base
In directory cvs.zope.org:/tmp/cvs-serv30596/CMFCore/tests/base

Modified Files:
      Tag: CMF-1_4-branch
	content.py dummy.py security.py testcase.py utils.py 
Log Message:
Fix version.txt to right version. Run reindent.py for removing extra tabs and whitespaces


=== CMF/CMFCore/tests/base/content.py 1.4 => 1.4.12.1 ===
--- CMF/CMFCore/tests/base/content.py:1.4	Wed Feb  5 12:50:57 2003
+++ CMF/CMFCore/tests/base/content.py	Thu Apr 22 13:47:49 2004
@@ -104,7 +104,7 @@
   body body body.
 
    o A list item
-   
+
    o And another thing...
 '''
 
@@ -121,7 +121,7 @@
   body body body.
 
    o A list item
-   
+
    o And another thing...
 '''
 


=== CMF/CMFCore/tests/base/dummy.py 1.6.4.4 => 1.6.4.5 ===
--- CMF/CMFCore/tests/base/dummy.py:1.6.4.4	Wed Jan 14 17:35:29 2004
+++ CMF/CMFCore/tests/base/dummy.py	Thu Apr 22 13:47:49 2004
@@ -15,10 +15,10 @@
     def __init__(self, id='dummy',**kw):
         self._id = id
         self.__dict__.update( kw )
-        
+
     def __str__(self):
         return self._id
-    
+
     def __call__(self):
         return self._id
 
@@ -27,7 +27,7 @@
 
     def getIcon( self, relative=0 ):
         return 'Site: %s' % relative
-    
+
     def getId(self):
         return self._id
 
@@ -60,15 +60,15 @@
         self.before_delete_called = 1
         if self.catalog:
             PortalContent.manage_beforeDelete( self, item, container )
-    
+
     def absolute_url(self):
-       return self.url
+        return self.url
 
     def reset( self ):
         self.after_add_called = self.before_delete_called = 0
 
     # Make sure normal Database export/import stuff doesn't trip us up.
-    def _getCopy( self, container ):        
+    def _getCopy( self, container ):
         return DummyContent( self.id, catalog=self.catalog )
 
     def _safe_get(self,attr):
@@ -94,7 +94,7 @@
 
     def modified( self ):
         return self._safe_get('modified_date')
-    
+
     def Type( self ):
         return 'Dummy Content Title'
 
@@ -152,7 +152,7 @@
 
         if fake_product:
             self.manage_addProduct = { 'FooProduct' : DummyFactory( self ) }
-    
+
     def _setOb(self, id, object):
         setattr(self, id, object)
         return self._getOb(id)
@@ -250,16 +250,16 @@
                )
 
     root = 'DummyTool'
-    
+
     def __init__(self, anon=1):
-        self.anon = anon 
+        self.anon = anon
 
     def isAnonymousUser(self):
-        return self.anon 
+        return self.anon
 
     def getAuthenticatedMember(self):
         return "member"
-  
+
     def __call__( self ):
         return self.root
 


=== CMF/CMFCore/tests/base/security.py 1.3 => 1.3.4.1 ===
--- CMF/CMFCore/tests/base/security.py:1.3	Fri Mar 14 14:11:40 2003
+++ CMF/CMFCore/tests/base/security.py	Thu Apr 22 13:47:49 2004
@@ -17,7 +17,7 @@
                 , *args
                 , **kw):
         return 1
-    
+
     def checkPermission( self, permission, object, context) :
         if permission == 'forbidden permission':
             return 0
@@ -29,7 +29,7 @@
     """
     def getId( self ):
         return 'all_powerful_Oz'
-    
+
     getUserName = getId
 
     def allowed( self, object, object_roles=None ):
@@ -45,7 +45,7 @@
 
     def getId( self ):
         return 'high_roller'
-    
+
     getUserName = getId
 
     def allowed( self, object, object_roles=None ):
@@ -62,7 +62,7 @@
     """
     def getId( self ):
         return 'unit_tester'
-    
+
     getUserName = getId
 
     def has_permission(self, permission, obj):


=== CMF/CMFCore/tests/base/testcase.py 1.5.16.2 => 1.5.16.3 ===
--- CMF/CMFCore/tests/base/testcase.py:1.5.16.2	Thu Apr  8 10:21:12 2004
+++ CMF/CMFCore/tests/base/testcase.py	Thu Apr 22 13:47:49 2004
@@ -23,13 +23,13 @@
         get_transaction().begin()
         self.connection = Zope.DB.open()
         self.root =  self.connection.root()[ 'Application' ]
-    
+
     def tearDown( self ):
         get_transaction().abort()
         self.connection.close()
 
 class RequestTest( TransactionalTest ):
-    
+
     def setUp(self):
         TransactionalTest.setUp(self)
         root = self.root = makerequest(self.root)
@@ -53,7 +53,7 @@
         setSecurityPolicy(self._oldPolicy)
 
 class SecurityRequestTest( SecurityTest ):
-    
+
     def setUp(self):
         SecurityTest.setUp(self)
         self.root = makerequest(self.root)
@@ -84,7 +84,7 @@
         if object is not None:
             ob = self.ob = DummyFolder()
             addDirectoryViews(ob, self._skinname, self.tempname)
-    
+
     def _writeFile(self, filename, stuff):
         # write some stuff to a file on disk
         # make sure the file's modification time has changed
@@ -157,4 +157,3 @@
     def tearDown(self):
         # kill the copy
         rmtree(self.tempname)
-


=== CMF/CMFCore/tests/base/utils.py 1.2 => 1.2.44.1 ===
--- CMF/CMFCore/tests/base/utils.py:1.2	Fri Feb 15 14:45:34 2002
+++ CMF/CMFCore/tests/base/utils.py	Thu Apr 22 13:47:49 2004
@@ -5,12 +5,12 @@
     """
     Utlitity for building a test suite from a package name
     and a list of modules.
-    
+
     If required is false, then ImportErrors will simply result
     in that module's tests not being added to the returned
     suite.
     """
-    
+
     suite = TestSuite()
     try:
         for name in module_names:
@@ -33,4 +33,3 @@
         if catalog.getpath( rid ) == path:
             return 1
     return 0
-




More information about the CMF-checkins mailing list