MockSQSConnectorFactory implements SQSConnectorFactory, ResettableMock { @Override public void reset() { _mockSQSConnector.reset(); }  @Override SQSConnector getInstance(String awsAccessKey, String awsSecretKey); @Override SQSConnector getInstance(String awsAccessKey, String awsSecretKey, String awsSQSEndpoint, String awsSNSEndpoint); @Override void reset(); static final String BAD_ENDPOINT_URL; }
@Test public void testResetWillResetTheInternalConnectorBackToEmpty() throws Exception { _mockSQSConnector.sendMessage(_queue, _queueMessage); _mockSQSConnectorFactory.reset(); NevadoMessage resultMessage = _mockSQSConnector.receiveMessage(_nevadoConnection, _queue, DEFAULT_TIMEOUT); Assert.assertNull("queue message was returned and internal connector should have been reset", resultMessage); }