testArrayThrowable() — netty Function Reference
Architecture documentation for the testArrayThrowable() function in MessageFormatterTest.java from the netty codebase.
Entity Profile
Dependency Diagram
graph TD 84efed4b_e669_5a24_3fbb_77e1f9e594d5["testArrayThrowable()"] 61b49498_5128_d2ab_e17e_0c346b46695a["MessageFormatterTest"] 84efed4b_e669_5a24_3fbb_77e1f9e594d5 -->|defined in| 61b49498_5128_d2ab_e17e_0c346b46695a style 84efed4b_e669_5a24_3fbb_77e1f9e594d5 fill:#6366f1,stroke:#818cf8,color:#fff
Relationship Graph
Source Code
common/src/test/java/io/netty/util/internal/logging/MessageFormatterTest.java lines 283–324
@Test
public void testArrayThrowable() {
FormattingTuple ft;
Throwable t = new Throwable();
Object[] ia = { 1, 2, 3, t };
ft = MessageFormatter.arrayFormat("Value {} is smaller than {} and {}.", ia);
assertEquals("Value 1 is smaller than 2 and 3.", ft.getMessage());
assertEquals(t, ft.getThrowable());
ft = MessageFormatter.arrayFormat("{}{}{}", ia);
assertEquals("123", ft.getMessage());
assertEquals(t, ft.getThrowable());
ft = MessageFormatter.arrayFormat("Value {} is smaller than {}.", ia);
assertEquals("Value 1 is smaller than 2.", ft.getMessage());
assertEquals(t, ft.getThrowable());
ft = MessageFormatter.arrayFormat("Value {} is smaller than {}", ia);
assertEquals("Value 1 is smaller than 2", ft.getMessage());
assertEquals(t, ft.getThrowable());
ft = MessageFormatter.arrayFormat("Val={}, {, Val={}", ia);
assertEquals("Val=1, {, Val=2", ft.getMessage());
assertEquals(t, ft.getThrowable());
ft = MessageFormatter.arrayFormat("Val={}, \\{, Val={}", ia);
assertEquals("Val=1, \\{, Val=2", ft.getMessage());
assertEquals(t, ft.getThrowable());
ft = MessageFormatter.arrayFormat("Val1={}, Val2={", ia);
assertEquals("Val1=1, Val2={", ft.getMessage());
assertEquals(t, ft.getThrowable());
ft = MessageFormatter.arrayFormat("Value {} is smaller than {} and {}.", ia);
assertEquals("Value 1 is smaller than 2 and 3.", ft.getMessage());
assertEquals(t, ft.getThrowable());
ft = MessageFormatter.arrayFormat("{}{}{}{}", ia);
assertEquals("123java.lang.Throwable", ft.getMessage());
assertNull(ft.getThrowable());
}
Domain
Subdomains
Source
Frequently Asked Questions
What does testArrayThrowable() do?
testArrayThrowable() is a function in the netty codebase, defined in common/src/test/java/io/netty/util/internal/logging/MessageFormatterTest.java.
Where is testArrayThrowable() defined?
testArrayThrowable() is defined in common/src/test/java/io/netty/util/internal/logging/MessageFormatterTest.java at line 283.
Analyze Your Own Codebase
Get architecture documentation, dependency graphs, and domain analysis for your codebase in minutes.
Try Supermodel Free