use of org.kie.workbench.common.stunner.lienzo.toolbox.grid.FixedLayoutGrid in project kie-wb-common by kiegroup.
the class MorphActionsToolboxViewTest method assertConfigureButtonGridItem.
private void assertConfigureButtonGridItem() {
final ArgumentCaptor<Point2DGrid> gridCaptor = ArgumentCaptor.forClass(Point2DGrid.class);
verify(buttonGridItem, times(1)).grid(gridCaptor.capture());
final FixedLayoutGrid grid = (FixedLayoutGrid) gridCaptor.getValue();
assertEquals(1, grid.getRows());
assertEquals(2, grid.getCols());
assertEquals(AbstractActionsToolboxView.BUTTON_SIZE, grid.getIconSize(), 0);
assertEquals(AbstractActionsToolboxView.BUTTON_PADDING, grid.getPadding(), 0);
verify(buttonGridItem, times(1)).decorate(eq(buttonDecorator));
verify(buttonGridItem, times(1)).decorateGrid(eq(buttonDecorator));
verify(toolboxView, times(1)).add(eq(buttonGridItem));
}
use of org.kie.workbench.common.stunner.lienzo.toolbox.grid.FixedLayoutGrid in project kie-wb-common by kiegroup.
the class MorphActionsToolboxViewTest method assertConfigureToolbox.
private void assertConfigureToolbox() {
verify(toolboxView, times(1)).at(eq(MorphActionsToolboxView.TOOLBOX_AT));
final ArgumentCaptor<Point2DGrid> gridCaptor = ArgumentCaptor.forClass(Point2DGrid.class);
verify(toolboxView, times(1)).grid(gridCaptor.capture());
final FixedLayoutGrid grid = (FixedLayoutGrid) gridCaptor.getValue();
assertEquals(1, grid.getRows());
assertEquals(1, grid.getCols());
assertEquals(AbstractActionsToolboxView.BUTTON_SIZE, grid.getIconSize(), 0);
assertEquals(AbstractActionsToolboxView.BUTTON_PADDING, grid.getPadding(), 0);
}
Aggregations