use of org.kie.workbench.common.stunner.bpmn.definition.IntermediateSignalEventCatching in project kie-wb-common by kiegroup.
the class EventCancelActivityViewHandlerTest method testHandleSignalIsCancel.
@Test
@SuppressWarnings("unchecked")
public void testHandleSignalIsCancel() {
final IntermediateSignalEventCatching bean = new IntermediateSignalEventCatching.IntermediateSignalEventCatchingBuilder().build();
bean.getExecutionSet().getCancelActivity().setValue(true);
tested.handle(bean, view);
verify(prim1).setAlpha(eq(1d));
verify(prim2).setAlpha(eq(0d));
}
use of org.kie.workbench.common.stunner.bpmn.definition.IntermediateSignalEventCatching in project kie-wb-common by kiegroup.
the class BPMNDiagramMarshallerTest method testUnmarshallIntermediateSignalEventCatching.
@Test
@SuppressWarnings("unchecked")
public void testUnmarshallIntermediateSignalEventCatching() throws Exception {
Diagram<Graph, Metadata> diagram = unmarshall(BPMN_INTERMEDIATE_SIGNAL_EVENTCATCHING);
assertDiagram(diagram, 2);
assertEquals("intermediateSignalCatching", diagram.getMetadata().getTitle());
Node<? extends Definition, ?> intermediateEventNode = diagram.getGraph().getNode("_2C9B14A3-F663-476D-9FDF-31590D3A9CC5");
IntermediateSignalEventCatching intermediateSignalEventCatching = (IntermediateSignalEventCatching) intermediateEventNode.getContent().getDefinition();
assertNotNull(intermediateSignalEventCatching.getGeneral());
assertEquals("MySignalCatchingEvent", intermediateSignalEventCatching.getGeneral().getName().getValue());
assertEquals("MySignalCatchingEventDocumentation", intermediateSignalEventCatching.getGeneral().getDocumentation().getValue());
assertNotNull(intermediateSignalEventCatching.getExecutionSet());
assertEquals(true, intermediateSignalEventCatching.getExecutionSet().getCancelActivity().getValue());
assertEquals("MySignal", intermediateSignalEventCatching.getExecutionSet().getSignalRef().getValue());
DataIOSet dataIOSet = intermediateSignalEventCatching.getDataIOSet();
AssignmentsInfo assignmentsInfo = dataIOSet.getAssignmentsinfo();
assertEquals("||output1_:String||[dout]output1_->var1", assignmentsInfo.getValue());
}
Aggregations