[Zope3-checkins] CVS: Zope3/src/zope/app/security/tests - test_zopepolicy.py:1.15.2.1

Jim Fulton cvs-admin at zope.org
Tue Nov 18 17:27:05 EST 2003


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

Modified Files:
      Tag: adaptergeddon-branch
	test_zopepolicy.py 
Log Message:
Implemented local presentation services.


=== Zope3/src/zope/app/security/tests/test_zopepolicy.py 1.15 => 1.15.2.1 ===
--- Zope3/src/zope/app/security/tests/test_zopepolicy.py:1.15	Mon Oct  6 15:29:49 2003
+++ Zope3/src/zope/app/security/tests/test_zopepolicy.py	Tue Nov 18 17:26:34 2003
@@ -19,6 +19,7 @@
 
 import unittest
 
+from zope.app.tests import ztapi
 from zope.component.service import serviceManager as services
 from zope.interface import implements
 
@@ -80,9 +81,9 @@
 
 
 
-        getService(None,Adapters).provideAdapter(
-                       IAttributeAnnotatable, IAnnotations,
-                       AttributeAnnotations)
+        ztapi.provideAdapter(
+            IAttributeAnnotatable, IAnnotations,
+            AttributeAnnotations)
 
         # set up some principals
         self.jim = principalRegistry.definePrincipal('jim', 'Jim', 'Jim Fulton',
@@ -199,7 +200,7 @@
             self.write, None, Context(self.jim)))
 
     def testPlayfulPrincipalRole(self):
-        getService(None,Adapters).provideAdapter(
+        ztapi.provideAdapter(
             ITest,
             IPrincipalRoleManager, AnnotationPrincipalRoleManager)
 
@@ -221,7 +222,7 @@
     def testPlayfulRolePermissions(self):
 
         ARPM = AnnotationRolePermissionManager
-        getService(None,Adapters).provideAdapter(ITest,
+        ztapi.provideAdapter(ITest,
                             IRolePermissionManager, ARPM)
         test = permissionRegistry.definePermission('test', 'Test', '')
         test = test.getId()
@@ -275,7 +276,7 @@
 
     def testPlayfulPrinciplePermissions(self):
         APPM = AnnotationPrincipalPermissionManager
-        getService(None,Adapters).provideAdapter(ITest,
+        ztapi.provideAdapter(ITest,
                        IPrincipalPermissionManager, APPM)
 
         ob1 = TestClass()




More information about the Zope3-Checkins mailing list