### Question:
JMSAppender implements PaxAppender { public void doAppend(PaxLoggingEvent paxLoggingEvent) { try { TextMessage message = getOrCreateSession().createTextMessage(); message.setText(format.toString(paxLoggingEvent)); getOrCreatePublisher().send(message); } catch (JMSException e) { LOG.warn("Exception caught while sending log event - reinitializing JMS resources to recover", e); closeJMSResources(); } }  void close(); void doAppend(PaxLoggingEvent paxLoggingEvent); void setJmsConnectionFactory(ConnectionFactory jmsConnectionFactory); void setDestinationName(String destinationName); void setFormat(String name);  }### Answer:
@Test public void testLogstashAppender() throws InterruptedException { MockEndpoint events = getMockEndpoint("mock:events"); events.expectedMessageCount(1); appender.doAppend(MockEvents.createInfoEvent()); assertMockEndpointsSatisfied(); }