@Test
public void testShouldIgnoreBytesBeforeStart() throws Exception {
byte[] bytes = { 0, 1, 2, 3, 4, 5, 6, 7, 8, 9 };
ByteBuffer src = ByteBuffer.wrap(bytes);
PartialWritableByteChannel channel = new PartialWritableByteChannel(
this, 4, 6);
assertEquals(10, channel.write(src));
assertEquals(6, sink.position());
sink.flip();
for (int i = 4; i < 10; i++) {
assertEquals(i, sink.get());
}