[Zope3-checkins] CVS: Packages3/workflow/stateful/tests - test_instance.py:1.11 test_xmlimportexport.py:1.3

Ulrich Eck ueck@net-labs.de
Thu, 8 May 2003 12:03:19 -0400


Update of /cvs-repository/Packages3/workflow/stateful/tests
In directory cvs.zope.org:/tmp/cvs-serv29001/stateful/tests

Modified Files:
	test_instance.py test_xmlimportexport.py 
Log Message:
last steps before merging workflow-package into zope3-head



=== Packages3/workflow/stateful/tests/test_instance.py 1.10 => 1.11 ===
--- Packages3/workflow/stateful/tests/test_instance.py:1.10	Fri Mar 28 13:16:37 2003
+++ Packages3/workflow/stateful/tests/test_instance.py	Thu May  8 12:03:19 2003
@@ -28,6 +28,7 @@
 from zope.app.security.registries.permissionregistry \
      import permissionRegistry
 from zope.app.services.servicenames import Permissions
+from zope.security.checker import CheckerPublic
 from zope.security.management import newSecurityManager
 from zope.security.management import system_user
 
@@ -164,6 +165,10 @@
         pi.fireTransition('retract_pending')
         self.assertEqual(pi.status, 'private')
 
+
+
+
+
 class ConditionProcessInstanceTests(WorkflowSetup, unittest.TestCase):
 
     def setUp(self):
@@ -249,6 +254,10 @@
                          ['state2_initial', 'state2_state1'])
 
 
+
+
+
+
 def transition_script1(contexts):
     return contexts['data'].text == "some text"
 
@@ -362,17 +371,17 @@
         pd.states.setObject('state2', State())
         
         pd.transitions.setObject('initial_state1',
-                                 Transition('INITIAL', 'state1', permission='zope.Public'))
+                                 Transition('INITIAL', 'state1', permission=CheckerPublic))
         pd.transitions.setObject('initial_state2',
                                  Transition('INITIAL', 'state2', permission='deny'))
         pd.transitions.setObject('state1_state2',
-                                 Transition('state1', 'state2', permission='zope.Public'))
+                                 Transition('state1', 'state2', permission=CheckerPublic))
         pd.transitions.setObject('state2_state1',
                                  Transition('state2', 'state1'))
         pd.transitions.setObject('state1_initial',
                                  Transition('state1', 'INITIAL', permission='deny'))
         pd.transitions.setObject('state2_initial',
-                                 Transition('state2', 'INITIAL', permission='zope.Public'))
+                                 Transition('state2', 'INITIAL', permission=CheckerPublic))
 
         self.default.setObject('pd1', pd )
 


=== Packages3/workflow/stateful/tests/test_xmlimportexport.py 1.2 => 1.3 ===
--- Packages3/workflow/stateful/tests/test_xmlimportexport.py:1.2	Wed Apr  9 14:35:31 2003
+++ Packages3/workflow/stateful/tests/test_xmlimportexport.py	Thu May  8 12:03:19 2003
@@ -21,6 +21,8 @@
 from zope.component.adapter import provideAdapter
 from zope.component import getAdapter
 
+from zope.security.checker import CheckerPublic
+
 from zope.app.dublincore.annotatableadapter \
      import ZDCAnnotatableAdapter
 from zope.app.attributeannotations import AttributeAnnotations
@@ -145,7 +147,7 @@
         self.assertEqual(tr.destinationState, 'state1')
         self.assertEqual(tr.condition, None)
         self.assertEqual(tr.script, None)
-        self.assertEqual(tr.permission, 'zope.Public')
+        self.assertEqual(tr.permission, CheckerPublic)
         self.assertEqual(tr.triggerMode, 'Automatic')
         
         tr = testpd.transitions['state1_state2']
@@ -155,7 +157,7 @@
         self.assertEqual(tr.destinationState, 'state2')
         self.assertEqual(tr.condition, 'python: 1==1')
         self.assertEqual(tr.script, None)
-        self.assertEqual(tr.permission, 'zope.Public')
+        self.assertEqual(tr.permission, CheckerPublic)
         self.assertEqual(tr.triggerMode, 'Manual')
         
         tr = testpd.transitions['state2_initial']