CodecProtobufTest Class — netty Architecture
Architecture documentation for the CodecProtobufTest class in CodecProtobufTest.java from the netty codebase.
Entity Profile
Dependency Diagram
graph TD de3e0e0c_8b7c_b0c5_a050_5385ab1422d3["CodecProtobufTest"] c8cbfeb4_f3b8_3e18_a6db_d136ef8e1991["CodecProtobufTest.java"] de3e0e0c_8b7c_b0c5_a050_5385ab1422d3 -->|defined in| c8cbfeb4_f3b8_3e18_a6db_d136ef8e1991 c82a2fbf_3cd0_924e_853c_034dd37ef23b["testDecoder()"] de3e0e0c_8b7c_b0c5_a050_5385ab1422d3 -->|method| c82a2fbf_3cd0_924e_853c_034dd37ef23b
Relationship Graph
Source Code
testsuite-jpms/src/test/java/io/netty/testsuite_jpms/test/CodecProtobufTest.java lines 28–46
public class CodecProtobufTest {
@Test
public void testDecoder() {
EmbeddedChannel ch = new EmbeddedChannel(new ProtobufVarint32FrameDecoder());
byte[] b = { 4, 1, 1, 1, 1 };
assertFalse(ch.writeInbound(wrappedBuffer(b, 0, 1)));
assertNull(ch.readInbound());
assertFalse(ch.writeInbound(wrappedBuffer(b, 1, 2)));
assertNull(ch.readInbound());
assertTrue(ch.writeInbound(wrappedBuffer(b, 3, b.length - 3)));
ByteBuf expected = wrappedBuffer(new byte[] { 1, 1, 1, 1 });
ByteBuf actual = ch.readInbound();
assertEquals(expected, actual);
assertFalse(ch.finish());
expected.release();
actual.release();
}
}
Source
Frequently Asked Questions
What is the CodecProtobufTest class?
CodecProtobufTest is a class in the netty codebase, defined in testsuite-jpms/src/test/java/io/netty/testsuite_jpms/test/CodecProtobufTest.java.
Where is CodecProtobufTest defined?
CodecProtobufTest is defined in testsuite-jpms/src/test/java/io/netty/testsuite_jpms/test/CodecProtobufTest.java at line 28.
Analyze Your Own Codebase
Get architecture documentation, dependency graphs, and domain analysis for your codebase in minutes.
Try Supermodel Free