use of org.kie.workbench.common.stunner.bpmn.definition.IntermediateLinkEventThrowing in project kie-wb-common by kiegroup.
the class AbstractDataTypeCacheTest method testExtractIntermediateLinkEventThrowing.
@Test
public void testExtractIntermediateLinkEventThrowing() {
IntermediateLinkEventThrowing intermediateLinkEventThrowing = new IntermediateLinkEventThrowing();
IntermediateLinkEventThrowing intermediateLinkEventThrowing2 = new IntermediateLinkEventThrowing();
when(firstView.getDefinition()).thenReturn(intermediateLinkEventThrowing);
when(lastView.getDefinition()).thenReturn(intermediateLinkEventThrowing2);
dataTypeCache.extractFromItem(firstView);
dataTypeCache.extractFromItem(lastView);
assertTrue(dataTypeCache.allDataTypes.contains("MyType"));
assertTrue(dataTypeCache.allDataTypes.contains("com.myspace.Person"));
}
use of org.kie.workbench.common.stunner.bpmn.definition.IntermediateLinkEventThrowing in project kie-wb-common by kiegroup.
the class IntermediateThrowEventConverter method linkEvent.
protected PropertyWriter linkEvent(Node<View<IntermediateLinkEventThrowing>, ?> n) {
IntermediateThrowEvent event = bpmn2.createIntermediateThrowEvent();
event.setId(n.getUUID());
ThrowEventPropertyWriter p = propertyWriterFactory.of(event);
IntermediateLinkEventThrowing definition = n.getContent().getDefinition();
p.setAbsoluteBounds(n);
BPMNGeneralSet general = definition.getGeneral();
p.setName(general.getName().getValue());
p.setDocumentation(general.getDocumentation().getValue());
p.setMetaData(definition.getAdvancedData().getMetaDataAttributes());
p.setAssignmentsInfo(definition.getDataIOSet().getAssignmentsinfo());
LinkEventExecutionSet executionSet = definition.getExecutionSet();
p.addLink(executionSet.getLinkRef());
return p;
}
use of org.kie.workbench.common.stunner.bpmn.definition.IntermediateLinkEventThrowing in project kie-wb-common by kiegroup.
the class IntermediateThrowEventConverterTest method linkEvent.
@Test
public void linkEvent() {
IntermediateLinkEventThrowing definition = mock(IntermediateLinkEventThrowing.class);
IntermediateThrowEvent intermediateThrowEvent = mockIntermediateThrowEvent(definition);
tested.linkEvent(intermediateThrowEvent);
verifyCommonProperties(definition);
verify(propertyReader).getLinkRef();
verify(definition).setExecutionSet(any(LinkEventExecutionSet.class));
}
use of org.kie.workbench.common.stunner.bpmn.definition.IntermediateLinkEventThrowing in project kie-wb-common by kiegroup.
the class ProcessLinkRefProviderTest method mockIntermediateLinkEventThrowingNode.
private Node mockIntermediateLinkEventThrowingNode(String linkRefValue) {
IntermediateLinkEventThrowing event = new IntermediateLinkEventThrowing();
event.setExecutionSet(new LinkEventExecutionSet(new LinkRef(linkRefValue)));
return mockNode(event);
}
use of org.kie.workbench.common.stunner.bpmn.definition.IntermediateLinkEventThrowing in project kie-wb-common by kiegroup.
the class IntermediateThrowEventConverterTest method createIntermediateLinkEventThrowingNode.
private Node createIntermediateLinkEventThrowingNode() {
LinkEventExecutionSet executionSet = new LinkEventExecutionSet(linkRef);
IntermediateLinkEventThrowing eventThrowing = new IntermediateLinkEventThrowing(generalSet, mock(BackgroundSet.class), mock(FontSet.class), mock(CircleDimensionSet.class), dataIOSet, advancedData, executionSet);
Node dockNode = mockNode();
Node node = mockDockedNode(dockNode, eventThrowing);
return node;
}
Aggregations