Commit a2599069 authored by iv's avatar iv

ERP5Workflow: remove useless tests on worklists

parent 8abe46e4
......@@ -483,28 +483,14 @@ class TestWorklist(testWorkflowMixin):
self.removeWorklist('validation_workflow', ['region_worklist'])
self.commit()
def test_05_guard_setters(self):
def test_05_guard_expression_setters(self):
worklist_id = 'guarded_worklist'
workflow_id = 'validation_workflow'
workflow_value = self.getWorkflowTool()[workflow_id]
self.createWorklist(workflow_id, worklist_id,
action_name='guarded_test')
worklist_value = getattr(workflow_value, 'worklist_%s' % worklist_id)
# roles
worklist_value.setGuardRoleList([])
self.assertEqual(worklist_value.guard_role, ())
worklist_value.setGuardRoleList(['Assignor', 'Assignee'])
self.assertEqual(worklist_value.guard_role, ('Assignor', 'Assignee'))
# permissions
worklist_value.setGuardPermissionList([])
self.assertEqual(worklist_value.guard_permission, ())
worklist_value.setGuardPermissionList(['Modify portal content'])
self.assertEqual(worklist_value.guard_permission, ('Modify portal content',))
# groups
worklist_value.setGuardGroupList([])
self.assertEqual(worklist_value.guard_group, ())
worklist_value.setGuardGroupList(['Group1', 'Group2'])
self.assertEqual(worklist_value.guard_group, ('Group1', 'Group2'))
# expression
worklist_value.setGuardExpression('python: "Hello, world"')
self.assertEqual(worklist_value.guard_expression.text, 'python: "Hello, world"')
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment