for (Route route : routes) {
Endpoint key = route.getEndpoint();
assertEquals("From endpoint", "queue:a", key.getEndpointUri());
Processor processor = getProcessorWithoutErrorHandler(route);
IdempotentConsumer idempotentConsumer = assertIsInstanceOf(IdempotentConsumer.class, processor);
assertEquals("messageIdExpression", "header(myMessageId)", idempotentConsumer.getMessageIdExpression().toString());
assertIsInstanceOf(MemoryMessageIdRepository.class, idempotentConsumer.getMessageIdRepository());
SendProcessor sendProcessor = assertIsInstanceOf(SendProcessor.class, idempotentConsumer.getNextProcessor());
assertEquals("Endpoint URI", "queue:b", sendProcessor.getDestination().getEndpointUri());
}
}