Test multi-instance using ZeebeTestRule

I’m looking for a way to test the number of instances created when using bpmn multi-instances and iterate between instances to check the existence of variables using ZeebeTestRule or other tools.
Is their any way to get the id’s or the names of the differente instances created by zeebe in a subprocess ?
Bpmn-Spec dosn’t support testing subprocess or multinstances neither.

1 Like

Hi @B-hamza,

that is an interesting question. I think there is no solution in any tool yet.

BPMN-Spec might be a good place to add the missing function. Currently, it can verify variable values but it gets complicated for a multi-instance activity. Here, every element instance has the same element name.

Besides that, I would not recommend the ZeebeTestRule anymore. The test-containers project provides a better isolation of the environment. However, it doesn’t contain any assertions by itself.

Best regards,
Philipp