Search in sources :

Example 1 with FunctionSupplementaryGrid

use of org.kie.workbench.common.dmn.client.editors.expressions.types.function.supplementary.FunctionSupplementaryGrid in project kie-wb-common by kiegroup.

the class JavaFunctionEditorDefinitionTest method testEditor.

@Test
public void testEditor() {
    final Optional<Context> expression = definition.getModelClass();
    final Optional<BaseExpressionGrid> oEditor = definition.getEditor(parent, Optional.empty(), hasExpression, expression, hasName, 0);
    assertTrue(oEditor.isPresent());
    final GridWidget editor = oEditor.get();
    assertTrue(editor instanceof FunctionSupplementaryGrid);
}
Also used : Context(org.kie.workbench.common.dmn.api.definition.v1_1.Context) FunctionSupplementaryGrid(org.kie.workbench.common.dmn.client.editors.expressions.types.function.supplementary.FunctionSupplementaryGrid) GridWidget(org.uberfire.ext.wires.core.grids.client.widget.grid.GridWidget) BaseExpressionGrid(org.kie.workbench.common.dmn.client.widgets.grid.BaseExpressionGrid) Test(org.junit.Test)

Example 2 with FunctionSupplementaryGrid

use of org.kie.workbench.common.dmn.client.editors.expressions.types.function.supplementary.FunctionSupplementaryGrid in project kie-wb-common by kiegroup.

the class PMMLFunctionEditorDefinitionTest method testEditor.

@Test
public void testEditor() {
    final Optional<Context> expression = definition.getModelClass();
    final Optional<BaseExpressionGrid> oEditor = definition.getEditor(parent, Optional.empty(), hasExpression, expression, hasName, 0);
    assertTrue(oEditor.isPresent());
    final GridWidget editor = oEditor.get();
    assertTrue(editor instanceof FunctionSupplementaryGrid);
}
Also used : Context(org.kie.workbench.common.dmn.api.definition.v1_1.Context) FunctionSupplementaryGrid(org.kie.workbench.common.dmn.client.editors.expressions.types.function.supplementary.FunctionSupplementaryGrid) GridWidget(org.uberfire.ext.wires.core.grids.client.widget.grid.GridWidget) BaseExpressionGrid(org.kie.workbench.common.dmn.client.widgets.grid.BaseExpressionGrid) Test(org.junit.Test)

Aggregations

Test (org.junit.Test)2 Context (org.kie.workbench.common.dmn.api.definition.v1_1.Context)2 FunctionSupplementaryGrid (org.kie.workbench.common.dmn.client.editors.expressions.types.function.supplementary.FunctionSupplementaryGrid)2 BaseExpressionGrid (org.kie.workbench.common.dmn.client.widgets.grid.BaseExpressionGrid)2 GridWidget (org.uberfire.ext.wires.core.grids.client.widget.grid.GridWidget)2