[Zope-Checkins]
SVN: Zope/branches/2.10/lib/python/OFS/tests/testObjectManager.py
Add simple tests for manage_hasId
Wichert Akkerman
cvs-admin at zope.org
Thu Jun 15 07:22:59 EDT 2006
Log message for revision 68648:
Add simple tests for manage_hasId
Changed:
U Zope/branches/2.10/lib/python/OFS/tests/testObjectManager.py
-=-
Modified: Zope/branches/2.10/lib/python/OFS/tests/testObjectManager.py
===================================================================
--- Zope/branches/2.10/lib/python/OFS/tests/testObjectManager.py 2006-06-15 10:24:55 UTC (rev 68647)
+++ Zope/branches/2.10/lib/python/OFS/tests/testObjectManager.py 2006-06-15 11:22:56 UTC (rev 68648)
@@ -411,6 +411,16 @@
self.failUnless(filename.endswith('.zexp') or
filename.endswith('.xml'))
+ def test_hasId(self):
+ om = self._makeOne()
+ request={'id' : 'test'}
+ self.assertRaises(KeyError, om.manage_hasId, request)
+
+ si = SimpleItem('test')
+ om._setObject('test', si)
+ om.manage_hasId(request)
+
+
def test_suite():
suite = unittest.TestSuite()
suite.addTest( unittest.makeSuite( ObjectManagerTests ) )
More information about the Zope-Checkins
mailing list