@Test
public void testInternalReleaseConnectionWhereConnectionIsMarkedBrokenButConnectionTestSucceeds() throws InterruptedException, SQLException {

	// Test case where connection is broken
	mockConnection.logicallyClosed = new AtomicBoolean(false);
	reset(mockConnection,mockPartition, mockConnectionHandles);
	expect(mockConnection.isPossiblyBroken()).andReturn(true).once();
	expect(mockConfig.getConnectionTestStatement()).andReturn(null).once();
	expect(mockConnection.getMetaData()).andReturn(EasyMock.createNiceMock(DatabaseMetaData.class)).once();
	expect(mockPartition.getFreeConnections()).andReturn(mockConnectionHandles).anyTimes();
	expect(mockPartition.getAvailableConnections()).andReturn(1).anyTimes();
	expect(mockConnection.getOriginatingPartition()).andReturn(mockPartition).anyTimes();
			Connection mockRealConnection = EasyMock.createNiceMock(Connection.class);
	expect(mockConnection.getInternalConnection()).andReturn(mockRealConnection).anyTimes();
	replay(mockPartition, mockConnection);
	testClass.internalReleaseConnection(mockConnection);
	verify(mockPartition, mockConnection);
}