public class ChannelPipedInputStreamTest extends BaseTest {
@Test
public void testAvailable() throws Exception {
Window window = new Window(new BogusChannel(), null, true, true);
ChannelPipedInputStream stream = new ChannelPipedInputStream(window);
byte[] b = "test".getBytes();
stream.receive(b, 0, b.length);
assertEquals(b.length, stream.available());