public static void free(final DirectBuffer buffer)
    {
        if (null != buffer)
        {
            free(buffer.byteBuffer());
        }
    }
@Test
    void freeIsANoOpIfDirectBufferContainsNonDirectByteBuffer()
    {
        final DirectBuffer buffer = mock(DirectBuffer.class);
        final ByteBuffer byteBuffer = ByteBuffer.allocate(4);
        when(buffer.byteBuffer()).thenReturn(byteBuffer);

        BufferUtil.free(buffer);

        byteBuffer.put(1, (byte)5);
        assertEquals(5, byteBuffer.get(1));
    }