|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectorg.axonframework.test.saga.EventValidator
public class EventValidator
Helper class for validating events published on a given EventBus.
| Constructor Summary | |
|---|---|
EventValidator(EventBus eventBus,
FieldFilter fieldFilter)
Initializes the event validator to monitor the given eventBus. |
|
| Method Summary | |
|---|---|
void |
assertPublishedEvents(Object... expected)
Assert that the given expected events have been published. |
void |
assertPublishedEventsMatching(org.hamcrest.Matcher<? extends Iterable<?>> matcher)
Asserts that events have been published matching the given matcher. |
void |
handle(EventMessage event)
Process the given event. |
void |
startRecording()
Starts recording event published by the event bus. |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
|---|
public EventValidator(EventBus eventBus,
FieldFilter fieldFilter)
eventBus.
eventBus - the event bus to monitorfieldFilter - the filter describing the Fields to include in a comparison| Method Detail |
|---|
public void assertPublishedEventsMatching(org.hamcrest.Matcher<? extends Iterable<?>> matcher)
matcher.
matcher - The matcher that will validate the actual eventspublic void assertPublishedEvents(Object... expected)
expected events have been published.
expected - the events that must have been published.public void handle(EventMessage event)
EventListener
handle in interface EventListenerevent - the event to handlepublic void startRecording()
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||