Class ProcessEventInspections
java.lang.Object
io.camunda.zeebe.process.test.inspections.ProcessEventInspections
Inspections for process events. This class is particularly useful to find processes that have
been started without manually triggering them (e.g. with a timer start event).
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionFinds the first process instance that matches the applied filtersFinds the last process instance that matches the applied filtersfindProcessInstance(int index) Finds the process instance that matches the applied filters at a given indextriggeredByTimer(String timerId) Filters the process instances to only include instances that were triggered by a given timer event idwithProcessDefinitionKey(long processDefinitionKey) Filters the process instances to only include instance with a given process definition key
-
Constructor Details
-
ProcessEventInspections
-
-
Method Details
-
triggeredByTimer
Filters the process instances to only include instances that were triggered by a given timer event id- Parameters:
timerId- The element ID of the timer event- Returns:
- this
ProcessEventInspections
-
withProcessDefinitionKey
Filters the process instances to only include instance with a given process definition key- Parameters:
processDefinitionKey- The process definition key- Returns:
- this
ProcessEventInspections
-
findFirstProcessInstance
Finds the first process instance that matches the applied filters- Returns:
OptionalofInspectedProcessInstance
-
findLastProcessInstance
Finds the last process instance that matches the applied filters- Returns:
OptionalofInspectedProcessInstance
-
findProcessInstance
Finds the process instance that matches the applied filters at a given indexExample: If 3 process instances have been started, findProcessInstance(1) would return the second started instance.
- Parameters:
index- The index of the process instance start at 0- Returns:
OptionalofInspectedProcessInstance
-