@Test public void onRuleClick() { ruleButtonMock.checked = true; scenarioSimulationCreationPopupViewSpy.onRuleClick(clickEventMock); verify(dmnAssetsDivElementMock, times(1)).setAttribute(eq(ConstantHolder.HIDDEN), eq("")); verify(okButtonMock, times(1)).setEnabled(eq(true)); assertEquals(ScenarioSimulationModel.Type.RULE, scenarioSimulationCreationPopupViewSpy.getSelectedType()); }
@EventHandler("rule-button") public void onRuleClick(final ClickEvent event) { if (ruleButton.checked) { selectedType = ScenarioSimulationModel.Type.RULE; dmnAssetsDivElement.setAttribute(ConstantHolder.HIDDEN, ""); okButton.setEnabled(true); } }
ScenarioSimulationKogitoCreationPopupView extends AbstractScenarioPopupView implements ScenarioSimulationKogitoCreationPopup { @EventHandler("rule-button") public void onRuleClick(final ClickEvent event) { if (ruleButton.checked) { selectedType = ScenarioSimulationModel.Type.RULE; dmnAssetsDivElement.setAttribute(ConstantHolder.HIDDEN, ""); okButton.setEnabled(true); } } }
ScenarioSimulationKogitoCreationPopupView extends AbstractScenarioPopupView implements ScenarioSimulationKogitoCreationPopup { @EventHandler("rule-button") public void onRuleClick(final ClickEvent event) { if (ruleButton.checked) { selectedType = ScenarioSimulationModel.Type.RULE; dmnAssetsDivElement.setAttribute(ConstantHolder.HIDDEN, ""); okButton.setEnabled(true); } }  }
ScenarioSimulationKogitoCreationPopupView extends AbstractScenarioPopupView implements ScenarioSimulationKogitoCreationPopup { @EventHandler("rule-button") public void onRuleClick(final ClickEvent event) { if (ruleButton.checked) { selectedType = ScenarioSimulationModel.Type.RULE; dmnAssetsDivElement.setAttribute(ConstantHolder.HIDDEN, ""); okButton.setEnabled(true); } }  @Override void show(String mainTitleText, Command okCommand); @Override ScenarioSimulationModel.Type getSelectedType(); @Override String getSelectedPath(); @EventHandler("dmn-button") void onDmnClick(final ClickEvent event); @EventHandler("rule-button") void onRuleClick(final ClickEvent event); }
ScenarioSimulationKogitoCreationPopupView extends AbstractScenarioPopupView implements ScenarioSimulationKogitoCreationPopup { @EventHandler("rule-button") public void onRuleClick(final ClickEvent event) { if (ruleButton.checked) { selectedType = ScenarioSimulationModel.Type.RULE; dmnAssetsDivElement.setAttribute(ConstantHolder.HIDDEN, ""); okButton.setEnabled(true); } }  @Override void show(String mainTitleText, Command okCommand); @Override ScenarioSimulationModel.Type getSelectedType(); @Override String getSelectedPath(); @EventHandler("dmn-button") void onDmnClick(final ClickEvent event); @EventHandler("rule-button") void onRuleClick(final ClickEvent event);  }