@Test
public void callingCompletedReleasesBulkItemSource() {

    // given
    BufferedBulk.Builder builder = createDefaultTestMockedBuilder();
    ByteBufItemSource buffer = mock(ByteBufItemSource.class);
    builder.withBuffer(buffer);
    BufferedBulk bulk = builder.build();
    // when
    bulk.completed();
    // then
    verify(buffer).release();
}