Search in sources :

Example 1 with CachedProcessNodeTriggeredEvent

use of org.jbpm.test.listener.IterableProcessEventListener.CachedProcessNodeTriggeredEvent in project jbpm by kiegroup.

the class IterableListenerAssert method assertTriggered.

/**
 * Asserts that the node with the given name was triggered
 *
 * @param it       listener that listened to the process
 * @param nodeName name of the node that is expected to be triggered
 */
public static void assertTriggered(IterableProcessEventListener it, String nodeName) {
    TrackedEvent event = getEvent(it);
    Assertions.assertThat(event.getMethod()).isEqualTo(BEFORE_TRIGGERED);
    CachedProcessNodeTriggeredEvent orig = event.getEvent();
    Assertions.assertThat(orig.getNodeName()).isEqualTo(nodeName);
}
Also used : CachedProcessNodeTriggeredEvent(org.jbpm.test.listener.IterableProcessEventListener.CachedProcessNodeTriggeredEvent) TrackedEvent(org.jbpm.test.listener.IterableProcessEventListener.TrackedEvent)

Aggregations

CachedProcessNodeTriggeredEvent (org.jbpm.test.listener.IterableProcessEventListener.CachedProcessNodeTriggeredEvent)1 TrackedEvent (org.jbpm.test.listener.IterableProcessEventListener.TrackedEvent)1