Home / Function/ testThreadGroup() — netty Function Reference

testThreadGroup() — netty Function Reference

Architecture documentation for the testThreadGroup() function in ThreadDeathWatcherTest.java from the netty codebase.

Entity Profile

Dependency Diagram

graph TD
  81f03a62_aad1_78d0_7b90_86bef47b09b0["testThreadGroup()"]
  4732e020_0588_e2dd_973d_3462f91e7c9e["ThreadDeathWatcherTest"]
  81f03a62_aad1_78d0_7b90_86bef47b09b0 -->|defined in| 4732e020_0588_e2dd_973d_3462f91e7c9e
  style 81f03a62_aad1_78d0_7b90_86bef47b09b0 fill:#6366f1,stroke:#818cf8,color:#fff

Relationship Graph

Source Code

common/src/test/java/io/netty/util/ThreadDeathWatcherTest.java lines 123–143

    @Test
    @Timeout(value = 2000, unit = TimeUnit.MILLISECONDS)
    public void testThreadGroup() throws InterruptedException {
        final ThreadGroup group = new ThreadGroup("group");
        final AtomicReference<ThreadGroup> capturedGroup = new AtomicReference<ThreadGroup>();
        final Thread thread = new Thread(group, new Runnable() {
            @Override
            public void run() {
                final Thread t = ThreadDeathWatcher.threadFactory.newThread(new Runnable() {
                    @Override
                    public void run() {
                    }
                });
                capturedGroup.set(t.getThreadGroup());
            }
        });
        thread.start();
        thread.join();

        assertEquals(group, capturedGroup.get());
    }

Domain

Subdomains

Frequently Asked Questions

What does testThreadGroup() do?
testThreadGroup() is a function in the netty codebase, defined in common/src/test/java/io/netty/util/ThreadDeathWatcherTest.java.
Where is testThreadGroup() defined?
testThreadGroup() is defined in common/src/test/java/io/netty/util/ThreadDeathWatcherTest.java at line 123.

Analyze Your Own Codebase

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

Try Supermodel Free