use of org.springframework.integration.jms.JmsHeaderMapper in project spring-integration by spring-projects.
the class JmsOutboundChannelAdapterParserTests method adapterWithHeaderMapper.
@Test
public void adapterWithHeaderMapper() {
ClassPathXmlApplicationContext context = new ClassPathXmlApplicationContext("jmsOutboundWithHeaderMapper.xml", this.getClass());
EventDrivenConsumer endpoint = (EventDrivenConsumer) context.getBean("adapter");
DirectFieldAccessor accessor = new DirectFieldAccessor(new DirectFieldAccessor(endpoint).getPropertyValue("handler"));
JmsHeaderMapper headerMapper = (JmsHeaderMapper) accessor.getPropertyValue("headerMapper");
assertNotNull(headerMapper);
assertEquals(TestJmsHeaderMapper.class, headerMapper.getClass());
context.close();
}
Aggregations