@@ -0,0 +1,1147 @@
+package uk.gov.mint;%0A%0Aimport com.rabbitmq.client.Channel;%0Aimport com.rabbitmq.client.Envelope;%0Aimport org.junit.Before;%0Aimport org.junit.Test;%0Aimport org.junit.runner.RunWith;%0Aimport org.mockito.Mock;%0Aimport org.mockito.runners.MockitoJUnitRunner;%0Aimport uk.gov.integration.DataStoreApplication;%0A%0Aimport static org.mockito.Mockito.mock;%0Aimport static org.mockito.Mockito.verify;%0Aimport static org.mockito.Mockito.when;%0A%0A@RunWith(MockitoJUnitRunner.class)%0Apublic class MessageHandlerTest %7B%0A%0A    private MessageHandler messageHandler;%0A%0A    @Mock%0A    private Channel channel;%0A    @Mock%0A    private DataStoreApplication dataStore;%0A%0A    @Before%0A    public void setUp() throws Exception %7B%0A        messageHandler = new MessageHandler(channel, dataStore);%0A    %7D%0A%0A    @Test%0A    public void shouldAcceptJsonEntry() throws Exception %7B%0A        byte%5B%5D jsonBytes = %22%7B%5C%22foo%5C%22:%5C%22bar%5C%22%7D%22.getBytes();%0A        Envelope mock = mock(Envelope.class);%0A        when(mock.getDeliveryTag()).thenReturn(52L);%0A        messageHandler.handleDelivery(null, mock, null, jsonBytes);%0A%0A        verify(dataStore).add(jsonBytes);%0A        verify(channel).basicAck(52L, false);%0A    %7D%0A%7D%0A

Add test for MessageHandler