[Zope3-checkins] CVS: Zope3/src/zope/app/component/tests - test_directives.py:1.14.10.1

Jim Fulton jim at zope.com
Mon Sep 15 16:48:50 EDT 2003


Update of /cvs-repository/Zope3/src/zope/app/component/tests
In directory cvs.zope.org:/tmp/cvs-serv10942/src/zope/app/component/tests

Modified Files:
      Tag: parentgeddon-branch
	test_directives.py 
Log Message:
Woo hoo. The tests all pass. Zope even runs. :)


=== Zope3/src/zope/app/component/tests/test_directives.py 1.14 => 1.14.10.1 ===
--- Zope3/src/zope/app/component/tests/test_directives.py:1.14	Sun Aug  3 13:50:15 2003
+++ Zope3/src/zope/app/component/tests/test_directives.py	Mon Sep 15 16:48:19 2003
@@ -35,6 +35,7 @@
 from zope.component.tests.views import IV, IC, V1, VZMI, R1, RZMI
 from zope.component.tests.request import Request
 from zope.interface import implements
+from zope.security.checker import ProxyFactory
 
 
 template = """<configure
@@ -121,7 +122,7 @@
             """
             )))
 
-        adapter = getAdapter(Content(), IApp)
+        adapter = ProxyFactory(getAdapter(Content(), IApp))
         items = [item[0] for item in getTestProxyItems(adapter)]
         self.assertEqual(items, ['a', 'f'])
         self.assertEqual(getProxiedObject(adapter).__class__, Comp)
@@ -214,7 +215,7 @@
             """
             )))
 
-        utility = getUtility(None, IApp)
+        utility = ProxyFactory(getUtility(None, IApp))
         items = [item[0] for item in getTestProxyItems(utility)]
         self.assertEqual(items, ['a', 'f'])
         self.assertEqual(getProxiedObject(utility), comp)
@@ -263,7 +264,7 @@
             """
             ))
 
-        v = getView(Ob(), 'test', Request(IV))
+        v = ProxyFactory(getView(Ob(), 'test', Request(IV)))
         self.assertEqual(v.index(), 'V1 here')
         self.assertRaises(Exception, getattr, v, 'action')
 
@@ -280,7 +281,7 @@
             """
             ))
 
-        v = getView(Ob(), 'test', Request(IV))
+        v = ProxyFactory(getView(Ob(), 'test', Request(IV)))
         self.assertEqual(v.action(), 'done')
         self.assertRaises(Exception, getattr, v, 'index')
 




More information about the Zope3-Checkins mailing list