private static void sendFrameHeaders(BufferedOutputStream bos,
                                         HttpStatus status,
                                         boolean endOfStream, int streamId) throws Exception {
        final HPackEncoder encoder = new HPackEncoder(4096, StandardCharsets.UTF_8);
        final ByteArrayBuffer buffer = new ByteArrayBuffer(1024);
        encoder.encodeHeader(buffer, ":status", status.codeAsText(), false);
        final byte[] headersPayload = buffer.toByteArray();

        final ByteBuf buf = Unpooled.buffer(FRAME_HEADER_LENGTH + headersPayload.length);
        buf.writeMedium(headersPayload.length);
        buf.writeByte(Http2FrameTypes.HEADERS);
        buf.writeByte(new Http2Flags().endOfHeaders(true).endOfStream(endOfStream).value());
        buf.writeInt(streamId);
        buf.writeBytes(headersPayload);

        bos.write(buf.array());
        bos.flush();
    }
This test is to check the behavior of the HttpClient when the 'Expect: 100-continue' header is set.
core/src/test/java/com/linecorp/armeria/client/HttpClientExpect100HeaderTest.java