AnsweredAssumed Answered

Activiti with jBehave

Question asked by greg002 on Nov 25, 2014
Latest reply on Dec 5, 2014 by jbarrez
I am creating jBehave scenario's and I should get a "clean and reset activiti flow" at the start of every new scenario.
What's the best way to do this? The only way I'm currently seeing is: Restarting the server but this takes ages for 100+ jBehave tests.

Any ideas?

To make it more concrete:
Scenario 1:
given that I am logged in and there are 2 tasks to complete
when I complete both tasks
then there are no more tasks in activiti to be completed

Scenario 2:
given that I am logged in and there are 5 tasks to complete
when i complete 3 tasks
then there are 2 tasks in activiti to be completed

Both scenario's should start from "0" (we are calling the runtimeService.startProcessInstanceByKey("xxxx", params) method in the givens).

Outcomes