Search in sources :

Example 1 with StubJmsActivationSpecFactory

use of org.springframework.jms.listener.endpoint.StubJmsActivationSpecFactory in project spring-framework by spring-projects.

the class JmsListenerContainerFactoryTests method jcaExclusiveProperties.

@Test
public void jcaExclusiveProperties() {
    DefaultJcaListenerContainerFactory factory = new DefaultJcaListenerContainerFactory();
    factory.setDestinationResolver(destinationResolver);
    factory.setActivationSpecFactory(new StubJmsActivationSpecFactory());
    SimpleJmsListenerEndpoint endpoint = new SimpleJmsListenerEndpoint();
    endpoint.setMessageListener(new MessageListenerAdapter());
    thrown.expect(IllegalStateException.class);
    factory.createListenerContainer(endpoint);
}
Also used : MessageListenerAdapter(org.springframework.jms.listener.adapter.MessageListenerAdapter) StubJmsActivationSpecFactory(org.springframework.jms.listener.endpoint.StubJmsActivationSpecFactory) Test(org.junit.Test)

Aggregations

Test (org.junit.Test)1 MessageListenerAdapter (org.springframework.jms.listener.adapter.MessageListenerAdapter)1 StubJmsActivationSpecFactory (org.springframework.jms.listener.endpoint.StubJmsActivationSpecFactory)1