@Test
public void testPipelinedSpdyDataFrames() throws Exception {

    int streamId1 = RANDOM.nextInt() & 0x7FFFFFFF | 0x01;
    int streamId2 = RANDOM.nextInt() & 0x7FFFFFFF | 0x01;
    byte flags = 0;
    int length = 0;
    ByteBuf buf = Unpooled.buffer(2 * (SPDY_HEADER_SIZE + length));
    encodeDataFrameHeader(buf, streamId1, flags, length);
    encodeDataFrameHeader(buf, streamId2, flags, length);
    decoder.decode(buf);
    verify(delegate).readDataFrame(streamId1, false, Unpooled.EMPTY_BUFFER);
    verify(delegate).readDataFrame(streamId2, false, Unpooled.EMPTY_BUFFER);
    assertFalse(buf.isReadable());
    buf.release();
}