STG-26
Do rename per conversation, continue to look for ways to implement looping in a way that is re-entrant
This commit is contained in:
parent
1844c93919
commit
479f6d9647
|
@ -7,8 +7,8 @@
|
|||
<bpmn:userTask id="GetNames" name="Get Names" camunda:formKey="GetNamesForm">
|
||||
<bpmn:extensionElements>
|
||||
<camunda:formData>
|
||||
<camunda:formField id="GetNames_MICurrentVar.Name" type="string" />
|
||||
<camunda:formField id="GetNames_MICurrentVar.Nickname" type="string" />
|
||||
<camunda:formField id="GetNames_CurrentVar.Name" type="string" />
|
||||
<camunda:formField id="GetNames_CurrentVar.Nickname" type="string" />
|
||||
</camunda:formData>
|
||||
</bpmn:extensionElements>
|
||||
<bpmn:incoming>Flow_0vlor2k</bpmn:incoming>
|
||||
|
|
|
@ -31,21 +31,21 @@ class TestWorkflowProcessorLoopingTask(BaseTest):
|
|||
|
||||
self.assertEqual(task.multi_instance_type, 'looping')
|
||||
self.assertEqual(1, task.multi_instance_index)
|
||||
self.complete_form(workflow,task,{'GetNames_MICurrentVar':{'Name': 'Peter Norvig', 'Nickname': 'Pete'}})
|
||||
self.complete_form(workflow,task,{'GetNames_CurrentVar':{'Name': 'Peter Norvig', 'Nickname': 'Pete'}})
|
||||
task = self.get_workflow_api(workflow).next_task
|
||||
|
||||
self.assertEqual(task.multi_instance_type,'looping')
|
||||
self.assertEqual(2, task.multi_instance_index)
|
||||
self.complete_form(workflow,
|
||||
task,
|
||||
{'GetNames_MICurrentVar':{'Name': 'Stuart Russell', 'Nickname': 'Stu'}},
|
||||
{'GetNames_CurrentVar':{'Name': 'Stuart Russell', 'Nickname': 'Stu'}},
|
||||
terminate_loop=True)
|
||||
|
||||
task = self.get_workflow_api(workflow).next_task
|
||||
self.assertEqual(task.name,'Event_End')
|
||||
self.assertEqual(workflow.completed_tasks,workflow.total_tasks)
|
||||
self.assertEqual(task.data, {'GetNames_MICurrentVar': 2,
|
||||
'GetNames_MIData': {'1': {'Name': 'Peter Norvig',
|
||||
self.assertEqual(task.data, {'GetNames_CurrentVar': 2,
|
||||
'GetNames': {'1': {'Name': 'Peter Norvig',
|
||||
'Nickname': 'Pete'},
|
||||
'2': {'Name': 'Stuart Russell',
|
||||
'Nickname': 'Stu'}}})
|
||||
|
|
Loading…
Reference in New Issue