@Test
public void decode() {

    Http2Connection connection = new Http2Connection();
    ByteBuffer buffer = ByteBuffer.wrap(TestMessages.PING_STANDARD_BUFFER);
    Http2PingFrame frame = (Http2PingFrame) connection.decode(buffer);
    assertNotNull(frame);
    assertEquals(8, frame.getLength());
    assertEquals(6, frame.getType());
    assertEquals(0x00, frame.getFlags());
    assertEquals(32, frame.getStreamID());
    assertArrayEquals(new byte[] {0x00, 0x01, 0x02, 0x03, 0x04, 0x05, 0x06, 0x07}, frame.getData());
}