mimaison commented on code in PR #23914:
URL: https://github.com/apache/kafka/pull/23914#discussion_r4602308483


##########
clients/src/test/java/org/apache/kafka/common/security/ssl/DefaultSslEngineFactoryTest.java:
##########
@@ -334,8 +337,14 @@ public void testPemKeyStoreFileWithKeyPassword() throws 
Exception {
 
     @Test
     public void testUnavailableKeyFactoryAlgorithmDoesNotThrow() {
-        List<KeyFactory> factories = 
DefaultSslEngineFactory.PemStore.keyFactories(List.of("RSA", "DSA", "EC", 
"BOGUS_FACTORY"));
-        assertFalse(factories.stream().anyMatch(f -> 
f.getAlgorithm().equals("BOGUS_FACTORY")));
+        List<KeyFactory> factories = 
DefaultSslEngineFactory.PemStore.keyFactories(Set.of("BOGUS_FACTORY"));
+        assertTrue(factories.isEmpty());
+    }
+
+    @Test
+    public void testAllJvmKeyFactoryAlgorithmsLoaded() {
+        List<KeyFactory> factories = 
DefaultSslEngineFactory.PemStore.keyFactories(Security.getAlgorithms("KeyFactory"));

Review Comment:
   I'm not sure I follow what you mean here. Can you clarify?



-- 
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