### Question:
KsqlRestConfig extends RestConfig { public Map<String, Object> getKsqlConfigProperties() { return getOriginals(); } KsqlRestConfig(Map<?, ?> props); Map<String, Object> getOriginals(); Map<String, Object> getCommandConsumerProperties(); Map<String, Object> getCommandProducerProperties(); Map<String, Object> getKsqlConfigProperties(); String getCommandTopic(String ksqlServiceId); boolean isUiEnabled(); static final String COMMAND_CONSUMER_PREFIX; static final String COMMAND_PRODUCER_PREFIX; static final String STREAMED_QUERY_DISCONNECT_CHECK_MS_CONFIG; static final ConfigDef.Type STREAMED_QUERY_DISCONNECT_CHECK_MS_TYPE; static final Long STREAMED_QUERY_DISCONNECT_CHECK_MS_DEFAULT; static final ConfigDef.Importance STREAMED_QUERY_DISCONNECT_CHECK_MS_IMPORTANCE; static final String STREAMED_QUERY_DISCONNECT_CHECK_MS_DOC; static final String DISTRIBUTED_COMMAND_RESPONSE_TIMEOUT_MS_CONFIG; static final ConfigDef.Type DISTRIBUTED_COMMAND_RESPONSE_TIMEOUT_MS_TYPE; static final Long DISTRIBUTED_COMMAND_RESPONSE_TIMEOUT_MS_DEFAULT; static final ConfigDef.Importance DISTRIBUTED_COMMAND_RESPONSE_TIMEOUT_MS_IMPORTANCE; static final String DISTRIBUTED_COMMAND_RESPONSE_TIMEOUT_MS_DOC; static final String UI_ENABLED_CONFIG; static final ConfigDef.Type UI_ENABLED_TYPE; static final String UI_ENABLED_DEFAULT; static final ConfigDef.Importance UI_ENABLED_IMPORTANCE; static final String UI_ENABLED_DOC; static final String INSTALL_DIR_CONFIG; static final String INSTALL_DIR_DOC; static final String COMMAND_TOPIC_SUFFIX; static final String KSQL_WEBSOCKETS_NUM_THREADS; }### Answer:
@Test public void testGetKsqlConfigProperties() { Map<String, Object> inputProperties = getBaseProperties(); inputProperties.put(ConsumerConfig.AUTO_OFFSET_RESET_CONFIG, "earliest"); inputProperties.put(KsqlConfig.KSQL_SERVICE_ID_CONFIG, "test"); KsqlRestConfig config = new KsqlRestConfig(inputProperties); Map<String, Object> ksqlConfigProperties = config.getKsqlConfigProperties(); Map<String, Object> expectedKsqlConfigProperties = new HashMap<>(); expectedKsqlConfigProperties.put(StreamsConfig.BOOTSTRAP_SERVERS_CONFIG, "localhost:9092"); expectedKsqlConfigProperties.put(StreamsConfig.APPLICATION_ID_CONFIG, "ksql_config_test"); expectedKsqlConfigProperties.put(RestConfig.LISTENERS_CONFIG, "http: expectedKsqlConfigProperties.put(ConsumerConfig.AUTO_OFFSET_RESET_CONFIG, "earliest"); expectedKsqlConfigProperties.put(KsqlConfig.KSQL_SERVICE_ID_CONFIG, "test"); assertThat(ksqlConfigProperties, equalTo(expectedKsqlConfigProperties)); }