@Test public void testGetDropDown() throws Exception { final String fact = "Fact"; final String field = "field"; final AsyncPackageDataModelOracle oracle = mock(AsyncPackageDataModelOracle.class); final RuleModeller ruleModeller = mock(RuleModeller.class); doReturn(oracle).when(ruleModeller).getDataModelOracle(); final String variableDefinition = "varName:type:" + fact + "." + field; final DSLSentence dslSentence = mock(DSLSentence.class); final DSLVariableValue dslVariableValue = mock(DSLVariableValue.class); final boolean isMultipleSelect = false; final Callback<DSLDropDown> updateEnumsCallback = mock(Callback.class); testedDropDown = new DSLDropDown(ruleModeller, variableDefinition, dslSentence, dslVariableValue, isMultipleSelect, updateEnumsCallback); reset(oracle); testedDropDown.getDropDownData(); verify(oracle).getEnums(eq(fact), eq(field), anyMap()); }
DropDownData getDropDownData() { DropDownData dropDownData = oracle.getEnums(factType, factField, dslSentence.getEnumFieldValueMap()); return dropDownData; }
DSLDropDown extends Composite implements
        DSLSentenceWidget.DSLVariableEditor { DropDownData getDropDownData() { DropDownData dropDownData = oracle.getEnums(factType, factField, dslSentence.getEnumFieldValueMap()); return dropDownData; } }
DSLDropDown extends Composite implements
        DSLSentenceWidget.DSLVariableEditor { DropDownData getDropDownData() { DropDownData dropDownData = oracle.getEnums(factType, factField, dslSentence.getEnumFieldValueMap()); return dropDownData; } DSLDropDown(final RuleModeller ruleModeller,
                       final String variableDef,
                       final DSLSentence dslSentence,
                       final DSLVariableValue value,
                       final boolean multipleSelect,
                       final Callback<DSLDropDown> updateEnumDropDownsCallback); }
DSLDropDown extends Composite implements
        DSLSentenceWidget.DSLVariableEditor { DropDownData getDropDownData() { DropDownData dropDownData = oracle.getEnums(factType, factField, dslSentence.getEnumFieldValueMap()); return dropDownData; } DSLDropDown(final RuleModeller ruleModeller,
                       final String variableDef,
                       final DSLSentence dslSentence,
                       final DSLVariableValue value,
                       final boolean multipleSelect,
                       final Callback<DSLDropDown> updateEnumDropDownsCallback); DSLVariableValue getSelectedValue(); void refreshDropDownData(); }
DSLDropDown extends Composite implements
        DSLSentenceWidget.DSLVariableEditor { DropDownData getDropDownData() { DropDownData dropDownData = oracle.getEnums(factType, factField, dslSentence.getEnumFieldValueMap()); return dropDownData; } DSLDropDown(final RuleModeller ruleModeller,
                       final String variableDef,
                       final DSLSentence dslSentence,
                       final DSLVariableValue value,
                       final boolean multipleSelect,
                       final Callback<DSLDropDown> updateEnumDropDownsCallback); DSLVariableValue getSelectedValue(); void refreshDropDownData();  }