use of org.kie.workbench.common.stunner.bpmn.definition.IntermediateEscalationEvent in project kie-wb-common by kiegroup.
the class EventCancelActivityViewHandlerTest method testHandleEscalationIsNotCancel.
@Test
@SuppressWarnings("unchecked")
public void testHandleEscalationIsNotCancel() {
final IntermediateEscalationEvent bean = new IntermediateEscalationEvent();
bean.getExecutionSet().getCancelActivity().setValue(false);
tested.handle(bean, view);
verify(prim1).setFillAlpha(eq(0d));
verify(prim1).setStrokeAlpha(eq(1d));
}
use of org.kie.workbench.common.stunner.bpmn.definition.IntermediateEscalationEvent in project kie-wb-common by kiegroup.
the class IntermediateCatchEventConverterTest method createIntermediateEscalationEventCatchingNode.
private Node createIntermediateEscalationEventCatchingNode() {
CancellingEscalationEventExecutionSet executionSet = new CancellingEscalationEventExecutionSet(new CancelActivity(CANCEL_ACTIVITY), slaDueDate, escalationRef);
IntermediateEscalationEvent eventCatching = new IntermediateEscalationEvent(generalSet, mock(BackgroundSet.class), mock(FontSet.class), mock(CircleDimensionSet.class), dataIOSet, advancedData, executionSet);
Node dockNode = mockNode();
Node node = mockDockedNode(dockNode, eventCatching);
return node;
}
use of org.kie.workbench.common.stunner.bpmn.definition.IntermediateEscalationEvent in project kie-wb-common by kiegroup.
the class BPMNDirectDiagramMarshallerTest method testUnmarshallIntermediateEscalationEvents.
@Test
@SuppressWarnings("unchecked")
public void testUnmarshallIntermediateEscalationEvents() throws Exception {
Diagram<Graph, Metadata> diagram = unmarshall(BPMN_INTERMEDIATE_ESCALATION_EVENTS);
assertDiagram(diagram, 3);
assertEquals("IntermediateEscalationEvents", diagram.getMetadata().getTitle());
Node<? extends Definition, ?> catchingEventNode = diagram.getGraph().getNode("_C7F2BA98-1100-4CF8-A994-40E2B65F6E5D");
assertNotNull(catchingEventNode);
IntermediateEscalationEvent intermediateEscalationEvent = (IntermediateEscalationEvent) catchingEventNode.getContent().getDefinition();
assertNotNull(intermediateEscalationEvent.getGeneral());
assertEquals("BoundaryEscalationEventName", intermediateEscalationEvent.getGeneral().getName().getValue());
assertEquals("BoundaryEscalationEventDocumentation", intermediateEscalationEvent.getGeneral().getDocumentation().getValue());
assertNotNull(intermediateEscalationEvent.getExecutionSet());
assertEquals(true, intermediateEscalationEvent.getExecutionSet().getCancelActivity().getValue());
assertEquals("EscalationCode", intermediateEscalationEvent.getExecutionSet().getEscalationRef().getValue());
DataIOSet dataIOSet = intermediateEscalationEvent.getDataIOSet();
AssignmentsInfo assignmentsInfo = dataIOSet.getAssignmentsinfo();
assertEquals("||escalationOutput:String||[dout]escalationOutput->processVar1", assignmentsInfo.getValue());
assertEquals("12/25/1983", intermediateEscalationEvent.getExecutionSet().getSlaDueDate().getValue());
}
use of org.kie.workbench.common.stunner.bpmn.definition.IntermediateEscalationEvent in project kie-wb-common by kiegroup.
the class BoundaryCatchingIntermediateEscalationEventTest method testUnmarshallTopLevelEventWithEdgesEmptyProperties.
@Test
@Override
public void testUnmarshallTopLevelEventWithEdgesEmptyProperties() {
Diagram<Graph, Metadata> diagram = getDiagram();
assertDiagram(diagram, AMOUNT_OF_NODES_IN_DIAGRAM);
IntermediateEscalationEvent emptyEvent = getCatchingIntermediateNodeById(diagram, EMPTY_WITH_EDGES_TOP_LEVEL_EVENT_ID, HAS_NO_INCOME_EDGE, TWO_OUTGOING_EDGES);
assertGeneralSet(emptyEvent.getGeneral(), EMPTY_VALUE, EMPTY_VALUE);
assertEscalationEventExecutionSet(emptyEvent.getExecutionSet(), EMPTY_VALUE, NON_CANCELLING, EMPTY_VALUE);
assertDataIOSet(emptyEvent.getDataIOSet(), EMPTY_VALUE);
}
use of org.kie.workbench.common.stunner.bpmn.definition.IntermediateEscalationEvent in project kie-wb-common by kiegroup.
the class BoundaryCatchingIntermediateEscalationEventTest method testUnmarshallSubprocessLevelEventWithEdgesEmptyProperties.
@Test
@Override
public void testUnmarshallSubprocessLevelEventWithEdgesEmptyProperties() {
Diagram<Graph, Metadata> diagram = getDiagram();
assertDiagram(diagram, AMOUNT_OF_NODES_IN_DIAGRAM);
IntermediateEscalationEvent emptySubprocessEvent = getCatchingIntermediateNodeById(diagram, EMPTY_WITH_EDGES_SUBPROCESS_LEVEL_EVENT_ID, HAS_NO_INCOME_EDGE, TWO_OUTGOING_EDGES);
assertGeneralSet(emptySubprocessEvent.getGeneral(), EMPTY_VALUE, EMPTY_VALUE);
assertEscalationEventExecutionSet(emptySubprocessEvent.getExecutionSet(), EMPTY_VALUE, NON_CANCELLING, EMPTY_VALUE);
assertDataIOSet(emptySubprocessEvent.getDataIOSet(), EMPTY_VALUE);
}
Aggregations