use of org.camunda.bpm.engine.runtime.CaseExecutionQuery in project camunda-bpm-platform by camunda.
the class CaseExecutionQueryTest method testQueryByIntegerVariableValueLessThan.
public void testQueryByIntegerVariableValueLessThan() {
caseService.withCaseDefinitionByKey(CASE_DEFINITION_KEY).setVariable("anIntegerValue", 456).create();
CaseExecutionQuery query = caseService.createCaseExecutionQuery();
query.variableValueLessThan("anIntegerValue", 457);
verifyQueryResults(query, 1);
}
use of org.camunda.bpm.engine.runtime.CaseExecutionQuery in project camunda-bpm-platform by camunda.
the class CaseExecutionQueryTest method testQueryByShortCaseInstanceVariableValueGreaterThanOrEqual.
public void testQueryByShortCaseInstanceVariableValueGreaterThanOrEqual() {
caseService.withCaseDefinitionByKey(CASE_DEFINITION_KEY).setVariable("aShortValue", (short) 123).create();
CaseExecutionQuery query = caseService.createCaseExecutionQuery();
query.caseInstanceVariableValueGreaterThanOrEqual("aShortValue", (short) 122);
verifyQueryResults(query, 2);
query = caseService.createCaseExecutionQuery();
query.caseInstanceVariableValueGreaterThanOrEqual("aShortValue", (short) 123);
verifyQueryResults(query, 2);
}
use of org.camunda.bpm.engine.runtime.CaseExecutionQuery in project camunda-bpm-platform by camunda.
the class CaseExecutionQueryTest method testQueryByLongVariableValueGreaterThan.
public void testQueryByLongVariableValueGreaterThan() {
caseService.withCaseDefinitionByKey(CASE_DEFINITION_KEY).setVariable("aLongValue", (long) 789).create();
CaseExecutionQuery query = caseService.createCaseExecutionQuery();
query.variableValueGreaterThan("aLongValue", (long) 788);
verifyQueryResults(query, 1);
}
use of org.camunda.bpm.engine.runtime.CaseExecutionQuery in project camunda-bpm-platform by camunda.
the class CaseExecutionQueryTest method testQueryByInvalidCaseInstanceBusinessKey.
public void testQueryByInvalidCaseInstanceBusinessKey() {
CaseExecutionQuery query = caseService.createCaseExecutionQuery();
query.caseInstanceBusinessKey("invalid");
verifyQueryResults(query, 0);
try {
query.caseInstanceBusinessKey(null);
fail();
} catch (NotValidException e) {
}
}
use of org.camunda.bpm.engine.runtime.CaseExecutionQuery in project camunda-bpm-platform by camunda.
the class CaseExecutionQueryTest method testQueryByIntegerVariableValueEquals.
public void testQueryByIntegerVariableValueEquals() {
caseService.withCaseDefinitionByKey(CASE_DEFINITION_KEY).setVariable("anIntegerValue", 456).create();
CaseExecutionQuery query = caseService.createCaseExecutionQuery();
query.variableValueEquals("anIntegerValue", 456);
verifyQueryResults(query, 1);
}
Aggregations