MockEndpoint mock1 = getMockEndpoint("mock:result1");
mock1.expectedMessageCount(2);
MockEndpoint mock2 = getMockEndpoint("mock:result2");
mock2.expectedMessageCount(2);
template.sendBody("jpa://" + VersionedItem.class.getName(), new VersionedItem("one"));
template.sendBody("jpa://" + VersionedItem.class.getName(), new VersionedItem("two"));
template.sendBody("jpa://" + VersionedItem.class.getName(), new VersionedItem("three"));
template.sendBody("jpa://" + VersionedItem.class.getName(), new VersionedItem("four"));
this.context.startRoute("second");
this.context.startRoute("first");
assertMockEndpointsSatisfied();