Home / Function/ testHttpUpgradeRequestInvalidUpgradeHeader() — netty Function Reference

testHttpUpgradeRequestInvalidUpgradeHeader() — netty Function Reference

Architecture documentation for the testHttpUpgradeRequestInvalidUpgradeHeader() function in WebSocketServerProtocolHandlerTest.java from the netty codebase.

Entity Profile

Dependency Diagram

graph TD
  9347a476_c384_e3d7_5be7_b167d7509a97["testHttpUpgradeRequestInvalidUpgradeHeader()"]
  7afc952d_7109_096b_f81d_bf3293e37581["WebSocketServerProtocolHandlerTest"]
  9347a476_c384_e3d7_5be7_b167d7509a97 -->|defined in| 7afc952d_7109_096b_f81d_bf3293e37581
  style 9347a476_c384_e3d7_5be7_b167d7509a97 fill:#6366f1,stroke:#818cf8,color:#fff

Relationship Graph

Source Code

codec-http/src/test/java/io/netty/handler/codec/http/websocketx/WebSocketServerProtocolHandlerTest.java lines 109–127

    @Test
    public void testHttpUpgradeRequestInvalidUpgradeHeader() {
        EmbeddedChannel ch = createChannel();
        FullHttpRequest httpRequestWithEntity = new WebSocketRequestBuilder().httpVersion(HTTP_1_1)
                .method(HttpMethod.GET)
                .uri("/test")
                .connection("Upgrade")
                .version00()
                .upgrade("BogusSocket")
                .build();

        ch.writeInbound(httpRequestWithEntity);

        FullHttpResponse response = responses.remove();
        assertEquals(BAD_REQUEST, response.status());
        assertEquals("not a WebSocket handshake request: missing upgrade", getResponseMessage(response));
        response.release();
        assertFalse(ch.finish());
    }

Domain

Subdomains

Frequently Asked Questions

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

Analyze Your Own Codebase

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

Try Supermodel Free