Commit 913e0ba7 authored by Jérome Perrin's avatar Jérome Perrin

SecurityTestCase: minor simplifications

parent 08f88c59
...@@ -115,7 +115,6 @@ class SecurityTestCase(ERP5TypeTestCase): ...@@ -115,7 +115,6 @@ class SecurityTestCase(ERP5TypeTestCase):
"""set up and login as default user""" """set up and login as default user"""
super(SecurityTestCase, self)._setup() super(SecurityTestCase, self)._setup()
self.login() self.login()
self.portal = self.getPortal()
self.workflow_tool = self.portal.portal_workflow self.workflow_tool = self.portal.portal_workflow
def tearDown(self): def tearDown(self):
...@@ -219,7 +218,10 @@ class SecurityTestCase(ERP5TypeTestCase): ...@@ -219,7 +218,10 @@ class SecurityTestCase(ERP5TypeTestCase):
for wf in self.workflow_tool.getWorkflowValueListFor(document) or []: for wf in self.workflow_tool.getWorkflowValueListFor(document) or []:
if wf.getId() == 'edit_workflow': if wf.getId() == 'edit_workflow':
continue continue
if wf.__class__.__name__ in ['InteractionWorkflowDefinition', 'Interaction Workflow'] : if wf.__class__.__name__ in (
'InteractionWorkflowDefinition',
'Interaction Workflow',
):
continue continue
for wf_transition in wf._getWorkflowStateOf(document).getDestinationValueList(): for wf_transition in wf._getWorkflowStateOf(document).getDestinationValueList():
if wf_transition.getTriggerType() == TRIGGER_USER_ACTION: if wf_transition.getTriggerType() == TRIGGER_USER_ACTION:
......
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