amaechler commented on code in PR #14355:
URL: https://github.com/apache/druid/pull/14355#discussion_r1213878125
##########
indexing-service/src/test/java/org/apache/druid/indexing/seekablestream/RecordSupplierInputSourceTest.java:
##########
@@ -135,6 +137,24 @@ public void testReadTimeout() throws IOException
Assert.assertTrue(supplier.isClosed());
}
+ @Test
+ public void
testRecordSupplierInputSourceThrowsSamplerExceptionWhenExceptionDuringSeek()
+ {
+ final RecordSupplier<?, ?, ?> supplier =
Mockito.mock(RecordSupplier.class);
+ Mockito.when(supplier.getPartitionIds("test-stream"))
+ .thenThrow(new StreamException(new Exception("Something bad
happened")));
+
+ //noinspection ResultOfObjectAllocationIgnored
Review Comment:
This is technically complaining that the newly allocated object inside the
`assertThrows` closure isn't assigned to anything :) which in this case we
don't really care.
--
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: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]