use of org.camunda.bpm.qa.upgrade.Times in project camunda-bpm-platform by camunda.
the class DeployUserWithoutSaltForPasswordHashingScenario method initUser.
@DescribesScenario("initUser")
@Times(1)
public static ScenarioSetup initUser() {
return new ScenarioSetup() {
public void execute(ProcessEngine engine, String scenarioName) {
// given
IdentityService identityService = engine.getIdentityService();
User user = identityService.newUser(USER_NAME);
user.setPassword(USER_PWD);
// when
identityService.saveUser(user);
}
};
}
use of org.camunda.bpm.qa.upgrade.Times in project camunda-bpm-platform by camunda.
the class NestedNonInterruptingBoundaryEventOnOuterSubprocessScenario method initTimer.
@DescribesScenario("initTimer")
@Times(7)
public static ScenarioSetup initTimer() {
return new ScenarioSetup() {
public void execute(ProcessEngine engine, String scenarioName) {
ProcessInstance instance = engine.getRuntimeService().startProcessInstanceByKey("NestedNonInterruptingTimerBoundaryEventOnOuterSubprocessScenario", scenarioName);
Job job = engine.getManagementService().createJobQuery().processInstanceId(instance.getId()).singleResult();
engine.getManagementService().executeJob(job.getId());
}
};
}
use of org.camunda.bpm.qa.upgrade.Times in project camunda-bpm-platform by camunda.
the class InterruptingEventSubprocessCompensationScenario method instantiateAndTriggerCompensation.
@DescribesScenario("init.triggerCompensation")
@ExtendsScenario("init")
@Times(3)
public static ScenarioSetup instantiateAndTriggerCompensation() {
return new ScenarioSetup() {
public void execute(ProcessEngine engine, String scenarioName) {
// throw compensation; the compensation handler for userTask should then be active
Task beforeCompensateTask = engine.getTaskService().createTaskQuery().processInstanceBusinessKey(scenarioName).singleResult();
engine.getTaskService().complete(beforeCompensateTask.getId());
}
};
}
use of org.camunda.bpm.qa.upgrade.Times in project camunda-bpm-platform by camunda.
the class SubprocessCompensationScenario method instantiateAndTriggerCompensation.
@DescribesScenario("init.triggerCompensation")
@ExtendsScenario("init")
@Times(3)
public static ScenarioSetup instantiateAndTriggerCompensation() {
return new ScenarioSetup() {
public void execute(ProcessEngine engine, String scenarioName) {
// throw compensation; the compensation handler for userTask should then be active
Task beforeCompensateTask = engine.getTaskService().createTaskQuery().processInstanceBusinessKey(scenarioName).singleResult();
engine.getTaskService().complete(beforeCompensateTask.getId());
}
};
}
use of org.camunda.bpm.qa.upgrade.Times in project camunda-bpm-platform by camunda.
the class SubprocessCompensationScenario method instantiateConcurrentAndTriggerCompensation.
@DescribesScenario("init.concurrent.triggerCompensation")
@ExtendsScenario("init.concurrent")
@Times(3)
public static ScenarioSetup instantiateConcurrentAndTriggerCompensation() {
return new ScenarioSetup() {
public void execute(ProcessEngine engine, String scenarioName) {
// throw compensation; the compensation handler for userTask should then be active
Task beforeCompensateTask = engine.getTaskService().createTaskQuery().processInstanceBusinessKey(scenarioName).singleResult();
engine.getTaskService().complete(beforeCompensateTask.getId());
}
};
}
Aggregations