private void verifyInvalidReconfigure(ListenerReconfigurable reconfigurable,
                                          Map<String, Object>  invalidConfigs, String errorMessage) {
        assertThrows(KafkaException.class, () -> reconfigurable.validateReconfiguration(invalidConfigs));
        assertThrows(KafkaException.class, () -> reconfigurable.reconfigure(invalidConfigs));
    }
Tests invalid ssl.engine.factory plugin class
clients/src/test/java/org/apache/kafka/common/network/SslTransportLayerTest.java