I try to create a Scenario Test for the Camunda Invoice Example.
There is a Scenario, where I pass the Approve Invoice User Task twice:
- approve=false
- approve=true
The mocking in Camunda Scenario looks like:
when(mockedProcess.waitsAtUserTask(userTask.id))
.thenReturn { task =>
task.complete(userTask.out.asJavaVars())
}
As the userTask.id
is the same, I can only have one Mock.
Is there a way to achieve this (I have a solution with Camunda Assert)?