use of org.kie.workbench.common.stunner.core.graph.processing.index.map.MapIndex in project kie-wb-common by kiegroup.
the class AbstractCommandTest method setup.
@SuppressWarnings("unchecked")
public void setup() {
MockitoAnnotations.initMocks(this);
this.graph = new GraphImpl<>("graph", new GraphNodeStoreImpl());
this.index = new MapIndex(graph, new HashMap<>(), new HashMap<>());
when(canvasHandler.getDiagram()).thenReturn(diagram);
when(canvasHandler.getCanvas()).thenReturn(canvas);
when(canvasHandler.getGraphExecutionContext()).thenReturn(context);
when(context.getGraphIndex()).thenReturn(index);
when(canvasHandler.getGraphIndex()).thenReturn(index);
when(diagram.getMetadata()).thenReturn(metadata);
when(diagram.getGraph()).thenReturn(graph);
when(metadata.getDefinitionSetId()).thenReturn(DEF_SET_ID);
when(metadata.getShapeSetId()).thenReturn(SHAPE_SET_ID);
when(metadata.getCanvasRootUUID()).thenReturn(CANVAS_ROOT_UUID);
}
Aggregations