pyl passes w/ burnettk
This commit is contained in:
parent
e18d13260d
commit
8593d54742
|
@ -218,7 +218,6 @@ def process_instance_resume(
|
|||
try:
|
||||
processor.lock_process_instance("Web")
|
||||
processor.resume()
|
||||
processor.do_engine_steps(save=True)
|
||||
except (ProcessInstanceIsNotEnqueuedError, ProcessInstanceIsAlreadyLockedError) as e:
|
||||
ErrorHandlingService().handle_error(processor, e)
|
||||
raise e
|
||||
|
@ -673,7 +672,6 @@ def process_instance_task_list(
|
|||
TaskDefinitionModel.properties_json.label("task_definition_properties_json"), # type: ignore
|
||||
TaskModel.guid,
|
||||
TaskModel.state,
|
||||
TaskModel.properties_json,
|
||||
TaskModel.end_in_seconds,
|
||||
TaskModel.start_in_seconds,
|
||||
)
|
||||
|
|
|
@ -341,7 +341,6 @@ class TaskService:
|
|||
task_model["state"] = state
|
||||
task_model["start_in_seconds"] = None
|
||||
task_model["end_in_seconds"] = None
|
||||
task_model["properties_json"]["state"] = getattr(TaskState, state)
|
||||
|
||||
@classmethod
|
||||
def reset_task_model(
|
||||
|
|
|
@ -27,7 +27,7 @@
|
|||
</bpmn:intermediateCatchEvent>
|
||||
<bpmn:sequenceFlow id="Flow_0tzaigt" sourceRef="Gateway_0n53kj7" targetRef="Event_0himdx6" />
|
||||
<bpmn:sequenceFlow id="Flow_1vld4r2" sourceRef="Gateway_0n53kj7" targetRef="Event_0e4owa3" />
|
||||
<bpmn:sequenceFlow id="Flow_13ai5vv" sourceRef="Event_0e4owa3" targetRef="Activity_0uum4kq" />
|
||||
<bpmn:sequenceFlow id="Flow_13ai5vv" sourceRef="Event_0e4owa3" targetRef="manual_task_one" />
|
||||
<bpmn:endEvent id="Event_0vmxgb9">
|
||||
<bpmn:incoming>Flow_1q47ol8</bpmn:incoming>
|
||||
</bpmn:endEvent>
|
||||
|
@ -36,7 +36,7 @@
|
|||
<bpmn:endEvent id="Event_174a838">
|
||||
<bpmn:incoming>Flow_1w3n49n</bpmn:incoming>
|
||||
</bpmn:endEvent>
|
||||
<bpmn:sequenceFlow id="Flow_1vwnf3n" sourceRef="Activity_0uum4kq" targetRef="Event_1ixib8a" />
|
||||
<bpmn:sequenceFlow id="Flow_1vwnf3n" sourceRef="manual_task_one" targetRef="Event_1ixib8a" />
|
||||
<bpmn:intermediateCatchEvent id="Event_0e4owa3">
|
||||
<bpmn:incoming>Flow_1vld4r2</bpmn:incoming>
|
||||
<bpmn:outgoing>Flow_13ai5vv</bpmn:outgoing>
|
||||
|
@ -44,7 +44,7 @@
|
|||
<bpmn:timeDuration xsi:type="bpmn:tFormalExpression">"PT1H"</bpmn:timeDuration>
|
||||
</bpmn:timerEventDefinition>
|
||||
</bpmn:intermediateCatchEvent>
|
||||
<bpmn:manualTask id="Activity_0uum4kq" name="Any Task">
|
||||
<bpmn:manualTask id="manual_task_one" name="Any Task">
|
||||
<bpmn:extensionElements>
|
||||
<spiffworkflow:instructionsForEndUser>Click the button.</spiffworkflow:instructionsForEndUser>
|
||||
</bpmn:extensionElements>
|
||||
|
@ -91,7 +91,7 @@
|
|||
<bpmndi:BPMNShape id="Event_0e4owa3_di" bpmnElement="Event_0e4owa3">
|
||||
<dc:Bounds x="392" y="272" width="36" height="36" />
|
||||
</bpmndi:BPMNShape>
|
||||
<bpmndi:BPMNShape id="Activity_104jmxm_di" bpmnElement="Activity_0uum4kq">
|
||||
<bpmndi:BPMNShape id="Activity_104jmxm_di" bpmnElement="manual_task_one">
|
||||
<dc:Bounds x="480" y="250" width="100" height="80" />
|
||||
<bpmndi:BPMNLabel />
|
||||
</bpmndi:BPMNShape>
|
||||
|
|
|
@ -2619,9 +2619,9 @@ class TestProcessApi(BaseTest):
|
|||
headers=self.logged_in_headers(with_super_admin_user),
|
||||
)
|
||||
assert response.status_code == 200
|
||||
end_task = next(task for task in response.json if task["type"] == "End Event")
|
||||
end_task = next(task for task in response.json if task["bpmn_identifier"] == "Event_174a838")
|
||||
response = client.get(
|
||||
f"/v1.0/task-data/{self.modify_process_identifier_for_path_param(process_model_identifier)}/{process_instance_id}/{end_task['task_spiff_step']}",
|
||||
f"/v1.0/task-data/{self.modify_process_identifier_for_path_param(process_model_identifier)}/{process_instance_id}/{end_task['guid']}",
|
||||
headers=self.logged_in_headers(with_super_admin_user),
|
||||
)
|
||||
assert response.status_code == 200
|
||||
|
@ -2688,17 +2688,17 @@ class TestProcessApi(BaseTest):
|
|||
f"/v1.0/process-instances/{self.modify_process_identifier_for_path_param(process_model_identifier)}/{process_instance_id}/task-info",
|
||||
headers=self.logged_in_headers(with_super_admin_user),
|
||||
)
|
||||
assert len(response.json) == 1
|
||||
task = response.json[0]
|
||||
assert len(response.json) == 9
|
||||
human_task = next(task for task in response.json if task["bpmn_identifier"] == "manual_task_one")
|
||||
|
||||
response = client.post(
|
||||
f"/v1.0/task-complete/{self.modify_process_identifier_for_path_param(process_model_identifier)}/{process_instance_id}/{task['id']}",
|
||||
f"/v1.0/task-complete/{self.modify_process_identifier_for_path_param(process_model_identifier)}/{process_instance_id}/{human_task['guid']}",
|
||||
headers=self.logged_in_headers(with_super_admin_user),
|
||||
content_type="application/json",
|
||||
data=json.dumps({"execute": False}),
|
||||
)
|
||||
assert response.json["status"] == "suspended"
|
||||
task_model = TaskModel.query.filter_by(guid=task["id"]).first()
|
||||
task_model = TaskModel.query.filter_by(guid=human_task["guid"]).first()
|
||||
assert task_model is not None
|
||||
assert task_model.state == "COMPLETED"
|
||||
|
||||
|
@ -2707,7 +2707,7 @@ class TestProcessApi(BaseTest):
|
|||
headers=self.logged_in_headers(with_super_admin_user),
|
||||
)
|
||||
assert response.status_code == 200
|
||||
assert len(response.json) == 1
|
||||
assert len(response.json) == 9
|
||||
|
||||
def setup_initial_groups_for_move_tests(self, client: FlaskClient, with_super_admin_user: UserModel) -> None:
|
||||
"""Setup_initial_groups_for_move_tests."""
|
||||
|
|
Loading…
Reference in New Issue