divijvaidya commented on code in PR #14222: URL: https://github.com/apache/kafka/pull/14222#discussion_r1307205079
########## streams/src/test/java/org/apache/kafka/streams/state/internals/TimestampedKeyValueStoreBuilderTest.java: ########## @@ -155,42 +144,24 @@ public void shouldThrowNullPointerIfInnerIsNull() { @Test public void shouldNotThrowNullPointerIfKeySerdeIsNull() { - reset(supplier); - expect(supplier.name()).andReturn("name"); - expect(supplier.metricsScope()).andReturn("metricScope").anyTimes(); - replay(supplier); - // does not throw new TimestampedKeyValueStoreBuilder<>(supplier, null, Serdes.String(), new MockTime()); } @Test public void shouldNotThrowNullPointerIfValueSerdeIsNull() { - reset(supplier); - expect(supplier.name()).andReturn("name"); - expect(supplier.metricsScope()).andReturn("metricScope").anyTimes(); - replay(supplier); - // does not throw new TimestampedKeyValueStoreBuilder<>(supplier, Serdes.String(), null, new MockTime()); } @Test public void shouldThrowNullPointerIfTimeIsNull() { - reset(supplier); - expect(supplier.name()).andReturn("name"); - expect(supplier.metricsScope()).andReturn("metricScope").anyTimes(); - replay(supplier); - assertThrows(NullPointerException.class, () -> new TimestampedKeyValueStoreBuilder<>(supplier, Serdes.String(), Serdes.String(), null)); } @Test public void shouldThrowNullPointerIfMetricsScopeIsNull() { - reset(supplier); - expect(supplier.get()).andReturn(new RocksDBTimestampedStore("name", null)); - expect(supplier.name()).andReturn("name"); Review Comment: makes sense. Thank you. -- 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