[Zope3-checkins] CVS: Zope3/src/zope/app/browser/security/grants/tests - permissionservice.py:1.4.18.1 rolepermissionmanager.py:1.4.12.1 roleservice.py:1.4.18.1 test_principalpermissionview.py:1.7.18.1 test_principalroleview.py:1.8.12.1

Grégoire Weber zope@i-con.ch
Sun, 22 Jun 2003 10:24:13 -0400


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

Modified Files:
      Tag: cw-mail-branch
	permissionservice.py rolepermissionmanager.py roleservice.py 
	test_principalpermissionview.py test_principalroleview.py 
Log Message:
Synced up with HEAD

=== Zope3/src/zope/app/browser/security/grants/tests/permissionservice.py 1.4 => 1.4.18.1 ===
--- Zope3/src/zope/app/browser/security/grants/tests/permissionservice.py:1.4	Tue Mar 11 11:10:48 2003
+++ Zope3/src/zope/app/browser/security/grants/tests/permissionservice.py	Sun Jun 22 10:22:42 2003
@@ -19,10 +19,11 @@
 from zope.app.interfaces.security import IPermissionService
 from zope.app.interfaces.security import IPermission
 from zope.app.interfaces.services.service import ISimpleService
+from zope.interface import implements
 
 class Permission:
 
-    __implements__ = IPermission
+    implements(IPermission)
 
     def __init__(self, id, title): self._id, self._title = id, title
     def getId(self): return self._id
@@ -31,7 +32,7 @@
 
 class PermissionService:
 
-    __implements__ = IPermissionService, ISimpleService
+    implements(IPermissionService, ISimpleService)
 
     def __init__(self, **kw):
         self._permissions = r = {}


=== Zope3/src/zope/app/browser/security/grants/tests/rolepermissionmanager.py 1.4 => 1.4.12.1 ===
--- Zope3/src/zope/app/browser/security/grants/tests/rolepermissionmanager.py:1.4	Wed Apr 30 19:37:55 2003
+++ Zope3/src/zope/app/browser/security/grants/tests/rolepermissionmanager.py	Sun Jun 22 10:22:42 2003
@@ -20,13 +20,14 @@
 from zope.app.interfaces.security import IRolePermissionMap
 from zope.app.security.grants.securitymap import SecurityMap
 from zope.app.security.settings import Allow, Deny, Unset
+from zope.interface import implements
 
 class RolePermissionManager:
     """
     provide adapter that manages role permission data in an object attribute
     """
 
-    __implements__ = IRolePermissionManager, IRolePermissionMap
+    implements(IRolePermissionManager, IRolePermissionMap)
 
     def __init__(self):
         self._rp = SecurityMap()


=== Zope3/src/zope/app/browser/security/grants/tests/roleservice.py 1.4 => 1.4.18.1 ===
--- Zope3/src/zope/app/browser/security/grants/tests/roleservice.py:1.4	Tue Mar 11 11:10:48 2003
+++ Zope3/src/zope/app/browser/security/grants/tests/roleservice.py	Sun Jun 22 10:22:42 2003
@@ -19,10 +19,11 @@
 from zope.app.interfaces.security import IRoleService
 from zope.app.interfaces.security import IRole
 from zope.app.interfaces.services.service import ISimpleService
+from zope.interface import implements
 
 class Role:
 
-    __implements__ = IRole
+    implements(IRole)
 
     def __init__(self, id, title): self._id, self._title = id, title
     def getId(self): return self._id
@@ -31,7 +32,7 @@
 
 class RoleService:
 
-    __implements__ = IRoleService, ISimpleService
+    implements(IRoleService, ISimpleService)
 
     def __init__(self, **kw):
         self._roles = r = {}


=== Zope3/src/zope/app/browser/security/grants/tests/test_principalpermissionview.py 1.7 => 1.7.18.1 ===
--- Zope3/src/zope/app/browser/security/grants/tests/test_principalpermissionview.py:1.7	Tue Mar 11 11:10:48 2003
+++ Zope3/src/zope/app/browser/security/grants/tests/test_principalpermissionview.py	Sun Jun 22 10:22:42 2003
@@ -33,15 +33,16 @@
 from zope.app.services.tests.placefulsetup \
      import PlacefulSetup
 from zope.app.interfaces.services.service import ISimpleService
+from zope.interface import implements
 
 class DummyContext:
 
-    __implements__ = IAttributeAnnotatable
+    implements(IAttributeAnnotatable)
 #IPrincipalPermissionManager, IPrincipalPermissionMap
 
 class DummyPermissionService:
 
-    __implements__ = IPermissionService, ISimpleService
+    implements(IPermissionService, ISimpleService)
 
     def __init__(self, perm_objs):
         perms = {}
@@ -58,7 +59,7 @@
 
 
 class DummyAuthenticationService:
-    __implements__ = IAuthenticationService, ISimpleService
+    implements(IAuthenticationService, ISimpleService)
 
     def __init__(self, principals):
         pr = {}
@@ -71,7 +72,7 @@
 
 class DummyAdapter:
 
-    __implements__ = IPrincipalPermissionManager, IPrincipalPermissionMap
+    implements(IPrincipalPermissionManager, IPrincipalPermissionMap)
 
     def __init__(self, context):
         self._context = context


=== Zope3/src/zope/app/browser/security/grants/tests/test_principalroleview.py 1.8 => 1.8.12.1 ===
--- Zope3/src/zope/app/browser/security/grants/tests/test_principalroleview.py:1.8	Wed Apr 30 19:37:55 2003
+++ Zope3/src/zope/app/browser/security/grants/tests/test_principalroleview.py	Sun Jun 22 10:22:42 2003
@@ -29,6 +29,7 @@
 from zope.app.interfaces.security import IPrincipalRoleManager
 from zope.publisher.browser import TestRequest
 from zope.app.interfaces.services.service import ISimpleService
+from zope.interface import implements
 
 class DummySetting:
     def __init__(self, name):
@@ -38,14 +39,14 @@
 
 class DummyManager:
 
-    __implements__ = IPrincipalRoleManager
+    implements(IPrincipalRoleManager)
 
     def getSetting(self, role, principal):
         return DummySetting('%r:%r' % (role, principal))
 
 class DummyRoleService:
 
-    __implements__ = IRoleService, ISimpleService
+    implements(IRoleService, ISimpleService)
 
     def __init__(self, roles):
         self._roles = roles
@@ -66,7 +67,7 @@
 
 class DummyAuthenticationService:
 
-    __implements__ = IAuthenticationService, ISimpleService
+    implements(IAuthenticationService, ISimpleService)
 
     def __init__(self, principals):
         self._principals = principals