use of org.springframework.jms.support.converter.SimpleMessageConverter in project spring-framework by spring-projects.
the class SimpleMessageConverterTests method testToMessageSimplyReturnsMessageAsIsIfSuppliedWithMessage.
@Test
public void testToMessageSimplyReturnsMessageAsIsIfSuppliedWithMessage() throws JMSException {
Session session = mock(Session.class);
ObjectMessage message = mock(ObjectMessage.class);
SimpleMessageConverter converter = new SimpleMessageConverter();
Message msg = converter.toMessage(message, session);
assertSame(message, msg);
}
use of org.springframework.jms.support.converter.SimpleMessageConverter in project spring-framework by spring-projects.
the class SimpleMessageConverterTests method testFromMessageSimplyReturnsMessageAsIsIfSuppliedWithMessage.
@Test
public void testFromMessageSimplyReturnsMessageAsIsIfSuppliedWithMessage() throws JMSException {
Message message = mock(Message.class);
SimpleMessageConverter converter = new SimpleMessageConverter();
Object msg = converter.fromMessage(message);
assertSame(message, msg);
}
Aggregations