fishy commented on code in PR #2772:
URL: https://github.com/apache/thrift/pull/2772#discussion_r1159030073


##########
lib/java/src/test/java/org/apache/thrift/transport/TestTByteBuffer.java:
##########
@@ -39,4 +41,29 @@ public void testOverflow() throws Exception {
             () -> byteBuffer.write("Hello 
World".getBytes(StandardCharsets.UTF_8)));
     assertEquals("Not enough room in output buffer", e.getMessage());
   }
+
+  @Test
+  public void testSmallTConfiguration() throws Exception {
+    // Test that TByteBuffer init fail with small max message size.
+    final TConfiguration configSmall =
+        new TConfiguration(
+            4, TConfiguration.DEFAULT_MAX_FRAME_SIZE, 
TConfiguration.DEFAULT_RECURSION_DEPTH);

Review Comment:
   I'm not sure if we have a java style guide or something but this style looks 
weird to me, but that might be just me (as I don't write java nowadays).



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]

Reply via email to