use of org.camunda.bpm.dmn.engine.DmnDecisionResult in project camunda-engine-dmn by camunda.
the class DmnEngineApiTest method shouldEvaluateDecisionLiteralExpression.
@Test
@DecisionResource(resource = DECISION_LITERAL_EXPRESSION_DMN)
public void shouldEvaluateDecisionLiteralExpression() {
DmnDecisionResult results = dmnEngine.evaluateDecision(decision, createVariables().putValue("input", INPUT_VALUE));
assertThat(results.getSingleEntry()).isNotNull().isEqualTo(EXPECTED_OUTPUT_VALUE);
}
use of org.camunda.bpm.dmn.engine.DmnDecisionResult in project camunda-engine-dmn by camunda.
the class DmnEngineApiTest method shouldEvaluateDecisionWithVariableMap.
@Test
@DecisionResource(resource = ONE_RULE_DMN)
public void shouldEvaluateDecisionWithVariableMap() {
DmnDecisionResult results = dmnEngine.evaluateDecision(decision, createVariables().putValue("input", INPUT_VALUE));
assertThat(results.getSingleEntry()).isNotNull().isEqualTo(EXPECTED_OUTPUT_VALUE);
}
use of org.camunda.bpm.dmn.engine.DmnDecisionResult in project camunda-engine-dmn by camunda.
the class ExpressionEvaluationTest method testHasInputVariableNameInVariableContext.
@Test
@DecisionResource(resource = DMN_VARIABLE_CONTEXT_WITH_INPUT_VARIABLE)
public void testHasInputVariableNameInVariableContext() {
DmnDecisionResult decisionResult = dmnEngine.evaluateDecision(decision, Variables.createVariables().putValue("in", 3));
assertThat(decisionResult.getSingleEntry()).isEqualTo(true);
}
use of org.camunda.bpm.dmn.engine.DmnDecisionResult in project camunda-engine-dmn by camunda.
the class ExpressionEvaluationTest method testHasInputVariableName.
@Test
@DecisionResource(resource = DMN_INPUT_VARIABLE)
public void testHasInputVariableName() {
DmnDecisionResult decisionResult = dmnEngine.evaluateDecision(decision, Variables.createVariables().putValue("in", 2));
assertThat(decisionResult.getSingleEntry()).isEqualTo(true);
}
use of org.camunda.bpm.dmn.engine.DmnDecisionResult in project camunda-engine-dmn by camunda.
the class ExpressionEvaluationTest method testOverrideInputVariableName.
@Test
@DecisionResource(resource = DMN_OVERRIDE_INPUT_VARIABLE)
public void testOverrideInputVariableName() {
DmnDecisionResult decisionResult = dmnEngine.evaluateDecision(decision, Variables.createVariables().putValue("in", 2));
assertThat(decisionResult.getSingleEntry()).isEqualTo(true);
}
Aggregations