}
@Test
public void topicMessageWithWrongType() {
Threads.sleep(1000);
LogbackListAppender appender = new LogbackListAppender();
appender.addToLogger(AdvancedNotifyMessageListener.class);
advancedJmsTemplate.send(advancedNotifyTopic, new MessageCreator() {
@Override
public Message createMessage(Session session) throws JMSException {
MapMessage message = session.createMapMessage();
message.setStringProperty("objectType", "role");
return message;
}
});
Threads.sleep(1000);
assertThat(appender.isEmpty()).isTrue();
}