Home / Function/ testEncodeDataEndWithTrailersAsClient() — netty Function Reference

testEncodeDataEndWithTrailersAsClient() — netty Function Reference

Architecture documentation for the testEncodeDataEndWithTrailersAsClient() function in Http3FrameToHttpObjectCodecTest.java from the netty codebase.

Entity Profile

Dependency Diagram

graph TD
  271bdd33_54e4_6a1f_f5d0_8bb218f03255["testEncodeDataEndWithTrailersAsClient()"]
  0358625f_2420_3fbe_f6d7_5ee2577ca675["Http3FrameToHttpObjectCodecTest"]
  271bdd33_54e4_6a1f_f5d0_8bb218f03255 -->|defined in| 0358625f_2420_3fbe_f6d7_5ee2577ca675
  style 271bdd33_54e4_6a1f_f5d0_8bb218f03255 fill:#6366f1,stroke:#818cf8,color:#fff

Relationship Graph

Source Code

codec-http3/src/test/java/io/netty/handler/codec/http3/Http3FrameToHttpObjectCodecTest.java lines 571–592

    @Test
    public void testEncodeDataEndWithTrailersAsClient() {
        EmbeddedQuicStreamChannel ch = new EmbeddedQuicStreamChannel(new Http3FrameToHttpObjectCodec(false));
        ByteBuf hello = Unpooled.copiedBuffer("hello world", CharsetUtil.UTF_8);
        LastHttpContent trailers = new DefaultLastHttpContent(hello, true);
        HttpHeaders headers = trailers.trailingHeaders();
        headers.set("key", "value");
        assertTrue(ch.writeOutbound(trailers));

        Http3DataFrame dataFrame = ch.readOutbound();
        try {
            assertThat(dataFrame.content().toString(CharsetUtil.UTF_8), is("hello world"));
        } finally {
            dataFrame.release();
        }

        Http3HeadersFrame headerFrame = ch.readOutbound();
        assertThat(headerFrame.headers().get("key").toString(), is("value"));

        assertTrue(ch.isOutputShutdown());
        assertFalse(ch.finish());
    }

Domain

Subdomains

Frequently Asked Questions

What does testEncodeDataEndWithTrailersAsClient() do?
testEncodeDataEndWithTrailersAsClient() is a function in the netty codebase, defined in codec-http3/src/test/java/io/netty/handler/codec/http3/Http3FrameToHttpObjectCodecTest.java.
Where is testEncodeDataEndWithTrailersAsClient() defined?
testEncodeDataEndWithTrailersAsClient() is defined in codec-http3/src/test/java/io/netty/handler/codec/http3/Http3FrameToHttpObjectCodecTest.java at line 571.

Analyze Your Own Codebase

Get architecture documentation, dependency graphs, and domain analysis for your codebase in minutes.

Try Supermodel Free