vitojeng commented on a change in pull request #9821:
URL: https://github.com/apache/kafka/pull/9821#discussion_r556295011



##########
File path: streams/src/test/java/org/apache/kafka/streams/KafkaStreamsTest.java
##########
@@ -752,6 +754,13 @@ public void 
shouldNotGetQueryMetadataWithPartitionerWhenNotRunningOrRebalancing(
         streams.queryMetadataForKey("store", "key", (topic, key, value, 
numPartitions) -> 0);
     }
 
+    @Test(expected = UnknownStateStoreException.class)
+    public void shouldThrowUnknownStateStoreExceptionWhenStoreNotExist() 
throws Exception {
+        final KafkaStreams streams = new 
KafkaStreams(getBuilderWithSource().build(), props, supplier, time);

Review comment:
       > We should use a try-with-resources clause to make sure `close()` is 
called.
   
   Got it
   
   > Seems, other tests in this class have a similar issue. Would be good to 
fix all test accordingly (if you want you can also to a separate PR for it).
   
   Ok. I would like to create another PR for it.




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

For queries about this service, please contact Infrastructure at:
[email protected]


Reply via email to