testChunkedHeadFullHttpResponse() — netty Function Reference
Architecture documentation for the testChunkedHeadFullHttpResponse() function in HttpServerCodecTest.java from the netty codebase.
Entity Profile
Dependency Diagram
graph TD 018891a0_9749_9693_27c2_b409b748bf4e["testChunkedHeadFullHttpResponse()"] b6cdc8d3_b482_5921_941d_6401914d1c4f["HttpServerCodecTest"] 018891a0_9749_9693_27c2_b409b748bf4e -->|defined in| b6cdc8d3_b482_5921_941d_6401914d1c4f style 018891a0_9749_9693_27c2_b409b748bf4e fill:#6366f1,stroke:#818cf8,color:#fff
Relationship Graph
Source Code
codec-http/src/test/java/io/netty/handler/codec/http/HttpServerCodecTest.java lines 151–175
@Test
public void testChunkedHeadFullHttpResponse() {
EmbeddedChannel ch = new EmbeddedChannel(new HttpServerCodec());
// Send the request headers.
assertTrue(ch.writeInbound(Unpooled.copiedBuffer(
"HEAD / HTTP/1.1\r\n\r\n", CharsetUtil.UTF_8)));
HttpRequest request = ch.readInbound();
assertEquals(HttpMethod.HEAD, request.method());
LastHttpContent content = ch.readInbound();
assertFalse(content.content().isReadable());
content.release();
FullHttpResponse response = new DefaultFullHttpResponse(HttpVersion.HTTP_1_1, HttpResponseStatus.OK);
HttpUtil.setTransferEncodingChunked(response, true);
assertTrue(ch.writeOutbound(response));
assertTrue(ch.finish());
ByteBuf buf = ch.readOutbound();
assertEquals("HTTP/1.1 200 OK\r\ntransfer-encoding: chunked\r\n\r\n", buf.toString(CharsetUtil.US_ASCII));
buf.release();
assertFalse(ch.finishAndReleaseAll());
}
Domain
Subdomains
Source
Frequently Asked Questions
What does testChunkedHeadFullHttpResponse() do?
testChunkedHeadFullHttpResponse() is a function in the netty codebase, defined in codec-http/src/test/java/io/netty/handler/codec/http/HttpServerCodecTest.java.
Where is testChunkedHeadFullHttpResponse() defined?
testChunkedHeadFullHttpResponse() is defined in codec-http/src/test/java/io/netty/handler/codec/http/HttpServerCodecTest.java at line 151.
Analyze Your Own Codebase
Get architecture documentation, dependency graphs, and domain analysis for your codebase in minutes.
Try Supermodel Free