yashmayya commented on code in PR #14152:
URL: https://github.com/apache/kafka/pull/14152#discussion_r1313019711


##########
streams/src/test/java/org/apache/kafka/streams/state/internals/WindowStoreBuilderTest.java:
##########
@@ -164,17 +160,6 @@ public void shouldThrowNullPointerIfInnerIsNull() {
         assertThrows(NullPointerException.class, () -> new 
WindowStoreBuilder<>(null, Serdes.String(), Serdes.String(), new MockTime()));
     }
 
-    @Test
-    public void shouldThrowNullPointerIfKeySerdeIsNull() {
-        assertThrows(NullPointerException.class, () -> new 
WindowStoreBuilder<>(supplier, null, Serdes.String(), new MockTime()));
-    }
-
-    @Test
-    public void shouldThrowNullPointerIfValueSerdeIsNull() {
-        assertThrows(NullPointerException.class, () -> new 
WindowStoreBuilder<>(supplier, Serdes.String(),
-            null, new MockTime()));
-    }

Review Comment:
   There were similar buggy tests that were removed in the 
`SessionStoreBuilderTest` migration as well - 
https://github.com/apache/kafka/pull/14142#discussion_r1287021377. I think not 
having a `null` check on the key / value serdes is intentional - a default key 
/ value serdes is picked up from the processor context later on if the key / 
value serdes in the builder is `null`.



##########
streams/src/test/java/org/apache/kafka/streams/state/internals/WindowStoreBuilderTest.java:
##########
@@ -183,18 +168,7 @@ public void shouldThrowNullPointerIfTimeIsNull() {
 
     @Test
     public void shouldThrowNullPointerIfMetricsScopeIsNull() {
-        reset(supplier);
-        expect(supplier.get()).andReturn(new RocksDBWindowStore(

Review Comment:
   The relevant stubs are already setup in the `@Before` method and these 
aren't necessary.



-- 
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: jira-unsubscr...@kafka.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org

Reply via email to