testListenerSuccess() — netty Function Reference
Architecture documentation for the testListenerSuccess() function in PromiseNotifierTest.java from the netty codebase.
Entity Profile
Dependency Diagram
graph TD 25677b2d_f1ee_43cc_f534_191ddd6802f1["testListenerSuccess()"] 6d5f1092_59f3_c2aa_4bca_e779a4aabfcd["PromiseNotifierTest"] 25677b2d_f1ee_43cc_f534_191ddd6802f1 -->|defined in| 6d5f1092_59f3_c2aa_4bca_e779a4aabfcd style 25677b2d_f1ee_43cc_f534_191ddd6802f1 fill:#6366f1,stroke:#818cf8,color:#fff
Relationship Graph
Source Code
common/src/test/java/io/netty/util/concurrent/PromiseNotifierTest.java lines 50–71
@Test
public void testListenerSuccess() throws Exception {
@SuppressWarnings("unchecked")
Promise<Void> p1 = mock(Promise.class);
@SuppressWarnings("unchecked")
Promise<Void> p2 = mock(Promise.class);
@SuppressWarnings("unchecked")
PromiseNotifier<Void, Future<Void>> notifier =
new PromiseNotifier<Void, Future<Void>>(p1, p2);
@SuppressWarnings("unchecked")
Future<Void> future = mock(Future.class);
when(future.isSuccess()).thenReturn(true);
when(future.get()).thenReturn(null);
when(p1.trySuccess(null)).thenReturn(true);
when(p2.trySuccess(null)).thenReturn(true);
notifier.operationComplete(future);
verify(p1).trySuccess(null);
verify(p2).trySuccess(null);
}
Domain
Subdomains
Source
Frequently Asked Questions
What does testListenerSuccess() do?
testListenerSuccess() is a function in the netty codebase, defined in common/src/test/java/io/netty/util/concurrent/PromiseNotifierTest.java.
Where is testListenerSuccess() defined?
testListenerSuccess() is defined in common/src/test/java/io/netty/util/concurrent/PromiseNotifierTest.java at line 50.
Analyze Your Own Codebase
Get architecture documentation, dependency graphs, and domain analysis for your codebase in minutes.
Try Supermodel Free