@Test
public void testApplyCommonSettings_noSsl_noSasl_withClientProperties() {

    final Map<String, String> customProperties = new HashMap<>();
    customProperties.put("key3", "value3");
    customProperties.put("key4", "value4");
    final ClusterConfig clusterConfig = ClusterConfig.newBuilder()
        .withBrokerHosts(expectedBrokerHosts)
        .withUseSsl(false)
        .withUseSasl(false)
        // Use both setters
        .withClusterClientConfig("key1", "value1")
        .withClusterClientConfig("key2", "value2")
        .withClusterClientConfig(customProperties)
        // Build it.
        .build();
    final Map<String, Object> config = util.applyCommonSettings(clusterConfig, consumerId);
    // Validate
    validateDefaultKeys(config);
    validateNoSsl(config);
    validateNoSasl(config);
    // Validate this is not set.
    validateNoKey(config, CommonClientConfigs.SECURITY_PROTOCOL_CONFIG);
    // Validate custom properties applied
    validateKey(config, "key1", "value1");
    validateKey(config, "key2", "value2");
    validateKey(config, "key3", "value3");
    validateKey(config, "key4", "value4");
}