OmniaGM commented on code in PR #15655:
URL: https://github.com/apache/kafka/pull/15655#discussion_r1551790292


##########
clients/src/test/java/org/apache/kafka/common/network/SslTransportLayerTest.java:
##########
@@ -1528,4 +1530,30 @@ public void 
testHandshakeUnwrapContinuesUnwrappingOnNeedUnwrapAfterAllBytesRead(
         assertEquals(SSLEngineResult.Status.OK, result.getStatus());
         assertEquals(SSLEngineResult.HandshakeStatus.NEED_WRAP, 
result.getHandshakeStatus());
     }
+
+    @Test
+    public void testSSLEngineCloseInboundInvokedOnClose() throws IOException {
+        // Given
+        SSLEngine sslEngine = mock(SSLEngine.class);
+        Socket socket = mock(Socket.class);
+        SocketChannel socketChannel = mock(SocketChannel.class);
+        SelectionKey selectionKey = mock(SelectionKey.class);
+        when(socketChannel.socket()).thenReturn(socket);
+        when(selectionKey.channel()).thenReturn(socketChannel);
+        SslTransportLayer sslTransportLayer = new SslTransportLayer(
+                "test-channel",
+                selectionKey,
+                sslEngine,
+                mock(ChannelMetadataRegistry.class)
+        );
+

Review Comment:
   Could you please remove any unnecessary extra lines?



-- 
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: jira-unsubscr...@kafka.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org

Reply via email to