Home / Function/ testClientNoContext() — netty Function Reference

testClientNoContext() — netty Function Reference

Architecture documentation for the testClientNoContext() function in WebSocketServerCompressionHandlerTest.java from the netty codebase.

Entity Profile

Dependency Diagram

graph TD
  278db3fd_0042_142e_0dcc_6699bd6cf233["testClientNoContext()"]
  f04a1df1_c87f_2c9a_6db7_545340c5a3cb["WebSocketServerCompressionHandlerTest"]
  278db3fd_0042_142e_0dcc_6699bd6cf233 -->|defined in| f04a1df1_c87f_2c9a_6db7_545340c5a3cb
  style 278db3fd_0042_142e_0dcc_6699bd6cf233 fill:#6366f1,stroke:#818cf8,color:#fff

Relationship Graph

Source Code

codec-http/src/test/java/io/netty/handler/codec/http/websocketx/extensions/compression/WebSocketServerCompressionHandlerTest.java lines 159–177

    @Test
    public void testClientNoContext() {
        EmbeddedChannel ch = new EmbeddedChannel(new WebSocketServerCompressionHandler(0));

        HttpRequest req = newUpgradeRequest(PERMESSAGE_DEFLATE_EXTENSION + "; " + CLIENT_NO_CONTEXT);
        ch.writeInbound(req);

        HttpResponse res = newUpgradeResponse(null);
        ch.writeOutbound(res);

        HttpResponse res2 = ch.readOutbound();
        List<WebSocketExtensionData> exts = WebSocketExtensionUtil.extractExtensions(
                res2.headers().get(HttpHeaderNames.SEC_WEBSOCKET_EXTENSIONS));

        assertEquals(PERMESSAGE_DEFLATE_EXTENSION, exts.get(0).name());
        assertTrue(exts.get(0).parameters().isEmpty());
        assertNotNull(ch.pipeline().get(PerMessageDeflateDecoder.class));
        assertNotNull(ch.pipeline().get(PerMessageDeflateEncoder.class));
    }

Domain

Subdomains

Frequently Asked Questions

What does testClientNoContext() do?
testClientNoContext() is a function in the netty codebase, defined in codec-http/src/test/java/io/netty/handler/codec/http/websocketx/extensions/compression/WebSocketServerCompressionHandlerTest.java.
Where is testClientNoContext() defined?
testClientNoContext() is defined in codec-http/src/test/java/io/netty/handler/codec/http/websocketx/extensions/compression/WebSocketServerCompressionHandlerTest.java at line 159.

Analyze Your Own Codebase

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

Try Supermodel Free