[Zope-Checkins] CVS: Zope3/lib/python/Zope/App/OFS/tests - testFolder.py:1.1.2.4
Stephan Richter
srichter@cbu.edu
Sat, 19 Jan 2002 09:44:01 -0500
Update of /cvs-repository/Zope3/lib/python/Zope/App/OFS/tests
In directory cvs.zope.org:/tmp/cvs-serv30558/tests
Modified Files:
Tag: Zope-3x-branch
testFolder.py
Log Message:
Stephan and Tres:
changed Folder Test to do import in class method
=== Zope3/lib/python/Zope/App/OFS/tests/testFolder.py 1.1.2.3 => 1.1.2.4 ===
import unittest
-from Zope.App.OFS.Folder import Folder
-
class Test( unittest.TestCase ):
+
+ def _makeFolder(self):
+ """ """
+ from Zope.App.OFS.Folder import Folder
+
+ return Folder()
+
+
+
def testEmpty( self ):
- folder = Folder()
+ folder = self._makeFolder()
self.failIf( folder.objectIds() )
self.failIf( folder.objectValues() )
self.failIf( folder.objectItems() )
@@ -30,7 +37,7 @@
def testOneItem( self ):
- folder = Folder()
+ folder = self._makeFolder()
foo = []
folder.setObject( 'foo', foo )
@@ -75,7 +82,7 @@
def testManyItems( self ):
- folder = Folder()
+ folder = self._makeFolder()
objects = [ [0], [1], [2], [3] ]
folder.setObject( 'foo', objects[0] )
folder.setObject( 'bar', objects[1] )