### Question:
DefaultHttp2FrameReader implements Http2FrameReader, Http2FrameSizePolicy, Configuration { private void readSettingsFrame( final ChannelHandlerContext ctx, final ByteBuf payload, final Http2FrameListener listener) throws Http2Exception { if (flags.ack()) { listener.onSettingsAckRead(ctx); } else { final int numSettings = payloadLength / SETTING_ENTRY_LENGTH; final Http2Settings settings = new Http2Settings(); for (int index = 0; index < numSettings; ++index) { final char id = (char) payload.readUnsignedShort(); final long value = payload.readUnsignedInt(); try { settings.put(id, Long.valueOf(value)); } catch (final IllegalArgumentException e) { switch (id) { case SETTINGS_MAX_FRAME_SIZE: throw connectionError(PROTOCOL_ERROR, e, e.getMessage()); case SETTINGS_INITIAL_WINDOW_SIZE: throw connectionError(FLOW_CONTROL_ERROR, e, e.getMessage()); default: throw connectionError(PROTOCOL_ERROR, e, e.getMessage()); } } } listener.onSettingsRead(ctx, settings); } } DefaultHttp2FrameReader();  DefaultHttp2FrameReader(final boolean validateHeaders);  DefaultHttp2FrameReader(final Http2HeadersDecoder headersDecoder); @Override Http2HeadersDecoder.Configuration headersConfiguration(); @Override Configuration configuration(); @Override Http2FrameSizePolicy frameSizePolicy(); @Override void maxFrameSize(final int max); @Override int maxFrameSize(); @Override void close(); @Override void readFrame(
      final ChannelHandlerContext ctx, final ByteBuf input, final Http2FrameListener listener);  }### Answer:
@Test public void readSettingsFrame() throws Http2Exception { final ByteBuf input = Unpooled.buffer(); try { writeFrameHeader(input, 6, SETTINGS, new Http2Flags(), 0); input.writeShort(SETTINGS_MAX_HEADER_LIST_SIZE); input.writeInt(1024); frameReader.readFrame(ctx, input, listener); listener.onSettingsRead(ctx, new Http2Settings().maxHeaderListSize(1024)); } finally { input.release(); } }