@Test
public void releaseResetsTheSource() {

    // given
    ReleaseCallback callback = mock(ReleaseCallback.class);
    CompositeByteBuf byteBuf = spy(createDefaultTestByteBuf());
    // then
    ItemSource source = new ByteBufItemSource(byteBuf, callback);
    source.release();
    // then
    verify(byteBuf).clear();
}