testEmptyFullContentWithTrailer() — netty Function Reference
Architecture documentation for the testEmptyFullContentWithTrailer() function in HttpContentCompressorTest.java from the netty codebase.
Entity Profile
Dependency Diagram
graph TD d8b3fe7f_9472_4fe7_7f68_44e59c56cd5e["testEmptyFullContentWithTrailer()"] 32ab04b0_6c83_d4f7_6483_fd304f908331["HttpContentCompressorTest"] d8b3fe7f_9472_4fe7_7f68_44e59c56cd5e -->|defined in| 32ab04b0_6c83_d4f7_6483_fd304f908331 style d8b3fe7f_9472_4fe7_7f68_44e59c56cd5e fill:#6366f1,stroke:#818cf8,color:#fff
Relationship Graph
Source Code
codec-http/src/test/java/io/netty/handler/codec/http/HttpContentCompressorTest.java lines 574–597
@Test
public void testEmptyFullContentWithTrailer() throws Exception {
EmbeddedChannel ch = new EmbeddedChannel(new HttpContentCompressor());
ch.writeInbound(newRequest());
FullHttpResponse res = new DefaultFullHttpResponse(
HttpVersion.HTTP_1_1, HttpResponseStatus.OK, Unpooled.EMPTY_BUFFER);
res.trailingHeaders().set(of("X-Test"), of("Netty"));
ch.writeOutbound(res);
Object o = ch.readOutbound();
assertInstanceOf(FullHttpResponse.class, o);
res = (FullHttpResponse) o;
assertNull(res.headers().get(HttpHeaderNames.TRANSFER_ENCODING));
// Content encoding shouldn't be modified.
assertNull(res.headers().get(HttpHeaderNames.CONTENT_ENCODING));
assertEquals(0, res.content().readableBytes());
assertEquals("", res.content().toString(CharsetUtil.US_ASCII));
assertEquals("Netty", res.trailingHeaders().get(of("X-Test")));
assertEquals(DecoderResult.SUCCESS, res.decoderResult());
assertNull(ch.readOutbound());
}
Domain
Subdomains
Source
Frequently Asked Questions
What does testEmptyFullContentWithTrailer() do?
testEmptyFullContentWithTrailer() is a function in the netty codebase, defined in codec-http/src/test/java/io/netty/handler/codec/http/HttpContentCompressorTest.java.
Where is testEmptyFullContentWithTrailer() defined?
testEmptyFullContentWithTrailer() is defined in codec-http/src/test/java/io/netty/handler/codec/http/HttpContentCompressorTest.java at line 574.
Analyze Your Own Codebase
Get architecture documentation, dependency graphs, and domain analysis for your codebase in minutes.
Try Supermodel Free