}
byte[] buffer3 = new byte[] { 'e', 'f', 'g', 'h', 'i' };
buffos.write(buffer3, 0, 5);
byteArrayis = new ByteArrayInputStream(byteArrayos.toByteArray());
assertEquals("Bytes written, not buffered", 14, byteArrayis.available());
buffos.flush();
byteArrayis = new ByteArrayInputStream(byteArrayos.toByteArray());
assertEquals("Bytes not written after flush", 19, byteArrayis
.available());
for (int i = 0; i < 10; i++) {