Home / Function/ testBadResponse() — netty Function Reference

testBadResponse() — netty Function Reference

Architecture documentation for the testBadResponse() function in HttpObjectAggregatorTest.java from the netty codebase.

Entity Profile

Dependency Diagram

graph TD
  f3021c2a_c2d2_60db_757a_cb285465cd8f["testBadResponse()"]
  32ca569a_2b67_1114_bbc8_cbf703c91b95["HttpObjectAggregatorTest"]
  f3021c2a_c2d2_60db_757a_cb285465cd8f -->|defined in| 32ca569a_2b67_1114_bbc8_cbf703c91b95
  style f3021c2a_c2d2_60db_757a_cb285465cd8f fill:#6366f1,stroke:#818cf8,color:#fff

Relationship Graph

Source Code

codec-http/src/test/java/io/netty/handler/codec/http/HttpObjectAggregatorTest.java lines 375–384

    @Test
    public void testBadResponse() throws Exception {
        EmbeddedChannel ch = new EmbeddedChannel(new HttpResponseDecoder(), new HttpObjectAggregator(1024 * 1024));
        ch.writeInbound(Unpooled.copiedBuffer("HTTP/1.0 BAD_CODE Bad Server\r\n", CharsetUtil.UTF_8));
        Object inbound = ch.readInbound();
        assertInstanceOf(FullHttpResponse.class, inbound);
        assertTrue(((DecoderResultProvider) inbound).decoderResult().isFailure());
        assertNull(ch.readInbound());
        ch.finish();
    }

Domain

Subdomains

Frequently Asked Questions

What does testBadResponse() do?
testBadResponse() is a function in the netty codebase, defined in codec-http/src/test/java/io/netty/handler/codec/http/HttpObjectAggregatorTest.java.
Where is testBadResponse() defined?
testBadResponse() is defined in codec-http/src/test/java/io/netty/handler/codec/http/HttpObjectAggregatorTest.java at line 375.

Analyze Your Own Codebase

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

Try Supermodel Free