[Zope3-checkins] SVN: Zope3/trunk/src/zope/security/ Removed unused
NonPrivateChecker
Jim Fulton
jim at zope.com
Mon Jun 21 06:58:46 EDT 2004
Log message for revision 25919:
Removed unused NonPrivateChecker
-=-
Modified: Zope3/trunk/src/zope/security/checker.py
===================================================================
--- Zope3/trunk/src/zope/security/checker.py 2004-06-21 10:18:39 UTC (rev 25918)
+++ Zope3/trunk/src/zope/security/checker.py 2004-06-21 10:56:49 UTC (rev 25919)
@@ -451,15 +451,6 @@
return Checker(data.get)
-def NonPrivateChecker(permission_id = CheckerPublic):
-
- def check(name, permission_id=permission_id):
- if name.startswith('_'):
- return None
- return permission_id
-
- return Checker(check)
-
def selectChecker(object):
"""Get a checker for the given object
Modified: Zope3/trunk/src/zope/security/tests/test_checker.py
===================================================================
--- Zope3/trunk/src/zope/security/tests/test_checker.py 2004-06-21 10:18:39 UTC (rev 25918)
+++ Zope3/trunk/src/zope/security/tests/test_checker.py 2004-06-21 10:56:49 UTC (rev 25919)
@@ -289,12 +289,6 @@
self.assertEqual(checker.permission_id('z'), 'p4')
self.assertEqual(checker.permission_id('zzz'), None)
- def testNonPrivateChecker(self):
- from zope.security.checker import NonPrivateChecker
- checker = NonPrivateChecker('p')
- self.assertEqual(checker.permission_id('z'), 'p')
- self.assertEqual(checker.permission_id('_z'), None)
-
def testAlwaysAvailable(self):
from zope.security.checker import NamesChecker
checker = NamesChecker(())
More information about the Zope3-Checkins
mailing list