SafeguardController { public void setMessageWritingEnabled(final boolean messageWritingEnabled) { responseQueueListener.setMessageLoggingEnabled(messageWritingEnabled); jmsRequestLogger.setMessageLoggingEnabled(messageWritingEnabled); }  void setFIDecompressionEnabled(final boolean fIDecompressionEnabled); void setMessageWritingEnabled(final boolean messageWritingEnabled);  }
@Test public void testSetMessageWritingEnabledShouldCallBothRequestAndResponseQueueListeners() { underTest.setMessageWritingEnabled(true); verify(responseQueueListener).setMessageLoggingEnabled(true); verify(jmsRequestLogger).setMessageLoggingEnabled(true); }