@Test
public void testLastSpdyDataFrame() throws Exception {

    int streamId = RANDOM.nextInt() & 0x7FFFFFFF | 0x01;
    byte flags = 0x01; // FLAG_FIN
    int length = 0;
    ByteBuf buf = Unpooled.buffer(SPDY_HEADER_SIZE + length);
    encodeDataFrameHeader(buf, streamId, flags, length);
    decoder.decode(buf);
    verify(delegate).readDataFrame(streamId, true, Unpooled.EMPTY_BUFFER);
    assertFalse(buf.isReadable());
    buf.release();
}