@Test
public void testReadString()throws Exception
{

    String string = "I like cake";
    ByteBuffer buffer = ByteBuffer.wrap(string.getBytes());
    int positionBeforeCall = buffer.position();
    assertEquals(string, ByteBufferUtils.readString(buffer));
    assertTrue(positionBeforeCall==buffer.position());
}