Log message for revision 99217:
  Fix lame test that broke on Python 2.4

Changed:
  U   Zope/trunk/src/Products/Five/tests/test_security.py

-=-
Modified: Zope/trunk/src/Products/Five/tests/test_security.py
===================================================================
--- Zope/trunk/src/Products/Five/tests/test_security.py 2009-04-16 14:41:11 UTC 
(rev 99216)
+++ Zope/trunk/src/Products/Five/tests/test_security.py 2009-04-16 15:12:52 UTC 
(rev 99217)
@@ -406,12 +406,9 @@
     The permission will be made available globally, with default role set
     of ('Manager',).
       
-      >>> from pprint import pprint
-      >>> pprint(self.app.rolesOfPermission('Five: Dummy permission'))
-      [{'name': 'Anonymous', 'selected': ''},
-       {'name': 'Authenticated', 'selected': ''},
-       {'name': 'Manager', 'selected': 'SELECTED'},
-       {'name': 'Owner', 'selected': ''}]
+      >>> roles = self.app.rolesOfPermission('Five: Dummy permission')
+      >>> sorted(r['name'] for r in roles if r['selected'])
+      ['Manager']
 
     Let's also ensure that permissions are not overwritten if they exist
     already:
@@ -434,12 +431,9 @@
       ... '''
       >>> zcml.load_string(configure_zcml)
 
-      >>> from pprint import pprint
-      >>> pprint(self.app.rolesOfPermission('Five: Other dummy'))
-      [{'name': 'Anonymous', 'selected': 'SELECTED'},
-       {'name': 'Authenticated', 'selected': ''},
-       {'name': 'Manager', 'selected': ''},
-       {'name': 'Owner', 'selected': ''}]
+      >>> roles = self.app.rolesOfPermission('Five: Other dummy')
+      >>> sorted(r['name'] for r in roles if r['selected'])
+      ['Anonymous']
 
       >>> tearDown()
     """

_______________________________________________
Zope-Checkins maillist  -  Zope-Checkins@zope.org
http://mail.zope.org/mailman/listinfo/zope-checkins

Reply via email to