private static final String TEST_PROCESS_ONE_JOB = "org/camunda/bpm/engine/test/db/ProcessInstanceMigrationTest.oneJobProcess.bpmn20.xml";
private static final String TEST_PROCESS_TWO_JOBS = "org/camunda/bpm/engine/test/db/ProcessInstanceMigrationTest.twoJobsProcess.bpmn20.xml";
public void testSetProcessDefinitionVersionEmptyArguments() {
try {
new SetProcessDefinitionVersionCmd(null, 23);
fail("ProcessEngineException expected");
} catch (ProcessEngineException ae) {
assertTextPresent("The process instance id is mandatory: processInstanceId is null", ae.getMessage());
}
try {
new SetProcessDefinitionVersionCmd("", 23);
fail("ProcessEngineException expected");
} catch (ProcessEngineException ae) {
assertTextPresent("The process instance id is mandatory: processInstanceId is empty", ae.getMessage());
}
try {
new SetProcessDefinitionVersionCmd("42", null);
fail("ProcessEngineException expected");
} catch (ProcessEngineException ae) {
assertTextPresent("The process definition version is mandatory: processDefinitionVersion is null", ae.getMessage());
}
try {
new SetProcessDefinitionVersionCmd("42", -1);
fail("ProcessEngineException expected");
} catch (ProcessEngineException ae) {
assertTextPresent("The process definition version must be positive: processDefinitionVersion is not positive", ae.getMessage());
}
}