any(MessageCriteria.class), anyByte());
}
@Test
public void testUpdateStatusOfInboundMessages() throws Exception {
MessageHandler inHandler = mock(MessageHandler.class);
MessageHandler outHandler = mock(MessageHandler.class);
Connection conn = mock(Connection.class);
MessageHandler handler = createMessageHandler(outHandler, inHandler);
MessageCriteria criteria = new MessageCriteria()
.direction(Direction.TO_APPLICATIONS);
handler.updateMessagesStatus(conn, criteria, Message.STATUS_RETRYING);
verify(inHandler).updateMessagesStatus(any(Connection.class),
any(MessageCriteria.class), anyByte());
verify(outHandler, never()).updateMessagesStatus(any(Connection.class),
any(MessageCriteria.class), anyByte());