test(bpmn-rules): verify CallActivity can connect with MessageFlow

Closes #1467
This commit is contained in:
Maciej Barelkowski 2021-06-25 10:24:49 +02:00 committed by Nico Rehwaldt
parent 1d77bc75de
commit b7fa6b934a
2 changed files with 87 additions and 72 deletions

View File

@ -1,5 +1,5 @@
<?xml version="1.0" encoding="UTF-8"?>
<bpmn2:definitions xmlns:bpmn2="http://www.omg.org/spec/BPMN/20100524/MODEL" xmlns:bpmndi="http://www.omg.org/spec/BPMN/20100524/DI" xmlns:dc="http://www.omg.org/spec/DD/20100524/DC" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:di="http://www.omg.org/spec/DD/20100524/DI" id="_biH3sOTeEeS2YerRfpjPrw" targetNamespace="http://camunda.org/schema/1.0/bpmn" exporter="Camunda Modeler" exporterVersion="1.14.0" xsi:schemaLocation="http://www.omg.org/spec/BPMN/20100524/MODEL BPMN20.xsd">
<bpmn2:definitions xmlns:bpmn2="http://www.omg.org/spec/BPMN/20100524/MODEL" xmlns:bpmndi="http://www.omg.org/spec/BPMN/20100524/DI" xmlns:dc="http://www.omg.org/spec/DD/20100524/DC" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:di="http://www.omg.org/spec/DD/20100524/DI" id="_biH3sOTeEeS2YerRfpjPrw" targetNamespace="http://camunda.org/schema/1.0/bpmn" exporter="Camunda Modeler" exporterVersion="4.8.1" xsi:schemaLocation="http://www.omg.org/spec/BPMN/20100524/MODEL BPMN20.xsd">
<bpmn2:collaboration id="Collaboration">
<bpmn2:participant id="Participant" name="Pool" processRef="Process" />
<bpmn2:participant id="OtherParticipant" name="Pool" processRef="OtherProcess" />
@ -51,129 +51,133 @@
</bpmn2:dataOutputAssociation>
</bpmn2:task>
<bpmn2:dataStoreReference id="DataStoreReference" />
<bpmn2:callActivity id="CallActivity" />
<bpmn2:textAnnotation id="TextAnnotation_OtherParticipant" />
</bpmn2:process>
<bpmn2:process id="Process_18q5tmq" isExecutable="false" />
<bpmndi:BPMNDiagram id="BPMNDiagram_1">
<bpmndi:BPMNPlane id="BPMNPlane_1" bpmnElement="Collaboration">
<bpmndi:BPMNShape id="_BPMNShape_Participant_3" bpmnElement="Participant" isHorizontal="true">
<dc:Bounds x="72" y="48" width="706" height="266" />
</bpmndi:BPMNShape>
<bpmndi:BPMNShape id="_BPMNShape_SubProcess_3" bpmnElement="SubProcess" isExpanded="true">
<dc:Bounds x="510" y="72" width="248" height="205" />
</bpmndi:BPMNShape>
<bpmndi:BPMNShape id="_BPMNShape_Task_3" bpmnElement="Task_in_SubProcess">
<dc:Bounds x="535" y="95" width="100" height="80" />
</bpmndi:BPMNShape>
<bpmndi:BPMNShape id="_BPMNShape_Participant_4" bpmnElement="OtherParticipant" isHorizontal="true">
<dc:Bounds x="72" y="432" width="697" height="157" />
</bpmndi:BPMNShape>
<bpmndi:BPMNShape id="_BPMNShape_Task_7" bpmnElement="Task_in_OtherParticipant">
<dc:Bounds x="408" y="465" width="100" height="80" />
</bpmndi:BPMNShape>
<bpmndi:BPMNShape id="_BPMNShape_IntermediateCatchEvent_2" bpmnElement="IntermediateThrowEvent_Message">
<dc:Bounds x="239" y="157" width="36" height="36" />
<bpmndi:BPMNLabel>
<dc:Bounds x="212" y="198" width="90" height="0" />
</bpmndi:BPMNLabel>
</bpmndi:BPMNShape>
<bpmndi:BPMNShape id="_BPMNShape_TextAnnotation_3" bpmnElement="TextAnnotation_OtherParticipant">
<dc:Bounds x="162" y="465" width="103" height="88" />
</bpmndi:BPMNShape>
<bpmndi:BPMNShape id="_BPMNShape_TextAnnotation_4" bpmnElement="TextAnnotation_Global">
<dc:Bounds x="922" y="128" width="96" height="88" />
<dc:Bounds x="152" y="48" width="706" height="266" />
</bpmndi:BPMNShape>
<bpmndi:BPMNEdge id="SequenceFlow_di" bpmnElement="SequenceFlow">
<di:waypoint x="355" y="252" />
<di:waypoint x="497" y="252" />
</bpmndi:BPMNEdge>
<bpmndi:BPMNShape id="StartEvent_None_di" bpmnElement="StartEvent_None">
<dc:Bounds x="144" y="234" width="36" height="36" />
<dc:Bounds x="224" y="234" width="36" height="36" />
<bpmndi:BPMNLabel>
<dc:Bounds x="117" y="270" width="90" height="20" />
</bpmndi:BPMNLabel>
</bpmndi:BPMNShape>
<bpmndi:BPMNShape id="IntermediateThrowEvent_None_di" bpmnElement="IntermediateThrowEvent_None">
<dc:Bounds x="239" y="234" width="36" height="36" />
<bpmndi:BPMNLabel>
<dc:Bounds x="212" y="270" width="90" height="20" />
</bpmndi:BPMNLabel>
</bpmndi:BPMNShape>
<bpmndi:BPMNShape id="StartEvent_Message_di" bpmnElement="StartEvent_Message">
<dc:Bounds x="144" y="157" width="36" height="36" />
<dc:Bounds x="224" y="157" width="36" height="36" />
<bpmndi:BPMNLabel>
<dc:Bounds x="117" y="193" width="90" height="20" />
</bpmndi:BPMNLabel>
</bpmndi:BPMNShape>
<bpmndi:BPMNShape id="StartEvent_Timer_di" bpmnElement="StartEvent_Timer">
<dc:Bounds x="224" y="78" width="36" height="36" />
<bpmndi:BPMNLabel>
<dc:Bounds x="117" y="114" width="90" height="20" />
</bpmndi:BPMNLabel>
</bpmndi:BPMNShape>
<bpmndi:BPMNShape id="_BPMNShape_SubProcess_3" bpmnElement="SubProcess" isExpanded="true">
<dc:Bounds x="590" y="72" width="248" height="205" />
</bpmndi:BPMNShape>
<bpmndi:BPMNShape id="_BPMNShape_Task_3" bpmnElement="Task_in_SubProcess">
<dc:Bounds x="615" y="95" width="100" height="80" />
</bpmndi:BPMNShape>
<bpmndi:BPMNShape id="EndEvent_None_in_SubProcess_di" bpmnElement="EndEvent_None_in_SubProcess">
<dc:Bounds x="769" y="117" width="36" height="36" />
<bpmndi:BPMNLabel>
<dc:Bounds x="662" y="153" width="90" height="20" />
</bpmndi:BPMNLabel>
</bpmndi:BPMNShape>
<bpmndi:BPMNShape id="EndEvent_Message_di" bpmnElement="EndEvent_Message">
<dc:Bounds x="417" y="157" width="36" height="36" />
<dc:Bounds x="497" y="157" width="36" height="36" />
<bpmndi:BPMNLabel>
<dc:Bounds x="390" y="193" width="90" height="20" />
</bpmndi:BPMNLabel>
</bpmndi:BPMNShape>
<bpmndi:BPMNShape id="EndEvent_None_di" bpmnElement="EndEvent_None">
<dc:Bounds x="417" y="234" width="36" height="36" />
<dc:Bounds x="497" y="234" width="36" height="36" />
<bpmndi:BPMNLabel>
<dc:Bounds x="390" y="270" width="90" height="20" />
</bpmndi:BPMNLabel>
</bpmndi:BPMNShape>
<bpmndi:BPMNShape id="EndEvent_None_in_SubProcess_di" bpmnElement="EndEvent_None_in_SubProcess">
<dc:Bounds x="689" y="117" width="36" height="36" />
<bpmndi:BPMNLabel>
<dc:Bounds x="662" y="153" width="90" height="20" />
</bpmndi:BPMNLabel>
</bpmndi:BPMNShape>
<bpmndi:BPMNShape id="StartEvent_Timer_di" bpmnElement="StartEvent_Timer">
<dc:Bounds x="144" y="78" width="36" height="36" />
<bpmndi:BPMNLabel>
<dc:Bounds x="117" y="114" width="90" height="20" />
</bpmndi:BPMNLabel>
</bpmndi:BPMNShape>
<bpmndi:BPMNShape id="IntermediateCatchEvent_Escalation_di" bpmnElement="IntermediateCatchEvent_Escalation">
<dc:Bounds x="239" y="78" width="36" height="36" />
<dc:Bounds x="319" y="78" width="36" height="36" />
<bpmndi:BPMNLabel>
<dc:Bounds x="212" y="114" width="90" height="20" />
</bpmndi:BPMNLabel>
</bpmndi:BPMNShape>
<bpmndi:BPMNShape id="EndEvent_Cancel_di" bpmnElement="EndEvent_Cancel">
<dc:Bounds x="417" y="78" width="36" height="36" />
<bpmndi:BPMNShape id="_BPMNShape_IntermediateCatchEvent_2" bpmnElement="IntermediateThrowEvent_Message">
<dc:Bounds x="319" y="157" width="36" height="36" />
<bpmndi:BPMNLabel>
<dc:Bounds x="390" y="114" width="90" height="20" />
<dc:Bounds x="212" y="198" width="90" height="0" />
</bpmndi:BPMNLabel>
</bpmndi:BPMNShape>
<bpmndi:BPMNShape id="IntermediateThrowEvent_None_di" bpmnElement="IntermediateThrowEvent_None">
<dc:Bounds x="319" y="234" width="36" height="36" />
<bpmndi:BPMNLabel>
<dc:Bounds x="212" y="270" width="90" height="20" />
</bpmndi:BPMNLabel>
</bpmndi:BPMNShape>
<bpmndi:BPMNShape id="IntermediateThrowEvent_Signal_di" bpmnElement="IntermediateThrowEvent_Signal">
<dc:Bounds x="326" y="78" width="36" height="36" />
<dc:Bounds x="406" y="78" width="36" height="36" />
<bpmndi:BPMNLabel>
<dc:Bounds x="299" y="114" width="90" height="20" />
</bpmndi:BPMNLabel>
</bpmndi:BPMNShape>
<bpmndi:BPMNShape id="Participant_09perow_di" bpmnElement="CollapsedParticipant">
<dc:Bounds x="125" y="704" width="594" height="117" />
<bpmndi:BPMNShape id="EndEvent_Cancel_di" bpmnElement="EndEvent_Cancel">
<dc:Bounds x="497" y="78" width="36" height="36" />
<bpmndi:BPMNLabel>
<dc:Bounds x="390" y="114" width="90" height="20" />
</bpmndi:BPMNLabel>
</bpmndi:BPMNShape>
<bpmndi:BPMNShape id="_BPMNShape_Participant_4" bpmnElement="OtherParticipant" isHorizontal="true">
<dc:Bounds x="152" y="432" width="697" height="157" />
</bpmndi:BPMNShape>
<bpmndi:BPMNShape id="_BPMNShape_Task_7" bpmnElement="Task_in_OtherParticipant">
<dc:Bounds x="488" y="465" width="100" height="80" />
</bpmndi:BPMNShape>
<bpmndi:BPMNShape id="DataStoreReference_09caypn_di" bpmnElement="DataStoreReference">
<dc:Bounds x="671.8233151183972" y="480" width="50" height="50" />
<dc:Bounds x="752" y="480" width="50" height="50" />
<bpmndi:BPMNLabel>
<dc:Bounds x="696.8233151183972" y="534" width="0" height="12" />
</bpmndi:BPMNLabel>
</bpmndi:BPMNShape>
<bpmndi:BPMNShape id="_BPMNShape_TextAnnotation_3" bpmnElement="TextAnnotation_OtherParticipant">
<dc:Bounds x="242" y="465" width="103" height="88" />
</bpmndi:BPMNShape>
<bpmndi:BPMNShape id="CallActivity_di" bpmnElement="CallActivity">
<dc:Bounds x="360" y="465" width="100" height="80" />
</bpmndi:BPMNShape>
<bpmndi:BPMNShape id="Participant_09perow_di" bpmnElement="CollapsedParticipant" isHorizontal="true">
<dc:Bounds x="205" y="704" width="594" height="117" />
</bpmndi:BPMNShape>
<bpmndi:BPMNShape id="_BPMNShape_TextAnnotation_4" bpmnElement="TextAnnotation_Global">
<dc:Bounds x="1002" y="128" width="96" height="88" />
</bpmndi:BPMNShape>
<bpmndi:BPMNShape id="Group_di" bpmnElement="Group">
<dc:Bounds x="280" y="200" width="100" height="100" />
</bpmndi:BPMNShape>
<bpmndi:BPMNEdge id="DataOutputAssociation_di" bpmnElement="DataOutputAssociation">
<di:waypoint x="588" y="505" />
<di:waypoint x="752" y="505" />
</bpmndi:BPMNEdge>
<bpmndi:BPMNEdge id="MessageFlow_labeled_di" bpmnElement="MessageFlow_labeled">
<di:waypoint x="425" y="314" />
<di:waypoint x="425" y="432" />
<di:waypoint x="505" y="314" />
<di:waypoint x="505" y="432" />
<bpmndi:BPMNLabel>
<dc:Bounds x="433" y="364" width="35" height="14" />
<dc:Bounds x="513" y="364" width="35" height="14" />
</bpmndi:BPMNLabel>
</bpmndi:BPMNEdge>
<bpmndi:BPMNEdge id="MessageFlow_2_di" bpmnElement="MessageFlow_2">
<di:waypoint x="551" y="432" />
<di:waypoint x="551" y="277" />
<di:waypoint x="631" y="432" />
<di:waypoint x="631" y="277" />
</bpmndi:BPMNEdge>
<bpmndi:BPMNEdge id="DataOutputAssociation_di" bpmnElement="DataOutputAssociation">
<di:waypoint x="508" y="505" />
<di:waypoint x="672" y="505" />
</bpmndi:BPMNEdge>
<bpmndi:BPMNEdge id="SequenceFlow_di" bpmnElement="SequenceFlow">
<di:waypoint x="275" y="252" />
<di:waypoint x="417" y="252" />
</bpmndi:BPMNEdge>
<bpmndi:BPMNShape id="Group_di" bpmnElement="Group">
<dc:Bounds x="200" y="200" width="100" height="100" />
</bpmndi:BPMNShape>
</bpmndi:BPMNPlane>
</bpmndi:BPMNDiagram>
</bpmn2:definitions>

View File

@ -1204,6 +1204,17 @@ describe('features/modeling/rules - BpmnRules', function() {
}));
it('connect CallActivity -> Participant', function() {
expectCanConnect('CallActivity', 'Participant', {
sequenceFlow: false,
messageFlow: true,
association: false,
dataAssociation: false
});
});
it('drop TextAnnotation_Global -> Participant', inject(function() {
expectCanDrop('TextAnnotation_Global', 'Participant', true);
}));