ScenarioGridWidget extends ResizeComposite { @Override public void onResize() { final Widget parent = getParent(); if (parent != null) { final double w = parent.getOffsetWidth(); final double h = parent.getOffsetHeight(); setPixelSize((int) w, (int) h); } scenarioGridPanel.onResize(); }  void setScenarioGridPanel(ScenarioGridPanel scenarioGridPanel); void setContent(AbstractScesimModel abstractScesimModel, ScenarioSimulationModel.Type type); ScenarioGridPanel getScenarioGridPanel(); ScenarioSimulationContext getScenarioSimulationContext(); void refreshContent(AbstractScesimModel abstractScesimModel); void unregister(); void clearSelections(); void resetErrors(); AbstractScesimGridModel getModel(); void selectAndFocus(); void deselectAndUnFocus(); boolean isSelected(); @Override void onResize();  }
@Test public void onResize() { scenarioGridWidget.onResize(); verify(scenarioGridWidget, times(1)).setPixelSize(eq(WIDTH), eq(HEIGHT)); verify(scenarioGridPanelMock, times(1)).onResize(); }