5 commented on code in PR #204: URL: https://github.com/apache/cassandra-sidecar/pull/204#discussion_r1995858658
########## server/src/test/java/org/apache/cassandra/sidecar/datahub/SchemaReporterTest.java: ########## @@ -33,70 +36,101 @@ import com.datastax.driver.core.TableOptionsMetadata; import com.datastax.driver.core.UserType; import org.apache.cassandra.sidecar.common.server.utils.IOUtils; +import org.apache.cassandra.sidecar.metrics.MetricRegistryFactory; +import org.apache.cassandra.sidecar.metrics.SidecarMetrics; +import org.apache.cassandra.sidecar.metrics.SidecarMetricsImpl; +import org.apache.cassandra.sidecar.metrics.server.SchemaReportingMetrics; import static org.junit.jupiter.api.Assertions.assertEquals; +import static org.junit.jupiter.api.Assertions.assertTrue; import static org.mockito.Mockito.mock; import static org.mockito.Mockito.when; /** * Unit tests for {@link SchemaReporter} */ -@SuppressWarnings("try") +@SuppressWarnings("resource") Review Comment: The point is to suppress the compiler warning caused by the use of an in stance of `JsonEmitter` outside of `try-with-resource` block, which should not normally happen, but does make sense for tests. ########## server/src/test/java/org/apache/cassandra/sidecar/datahub/SchemaReporterTest.java: ########## @@ -33,70 +36,101 @@ import com.datastax.driver.core.TableOptionsMetadata; import com.datastax.driver.core.UserType; import org.apache.cassandra.sidecar.common.server.utils.IOUtils; +import org.apache.cassandra.sidecar.metrics.MetricRegistryFactory; +import org.apache.cassandra.sidecar.metrics.SidecarMetrics; +import org.apache.cassandra.sidecar.metrics.SidecarMetricsImpl; +import org.apache.cassandra.sidecar.metrics.server.SchemaReportingMetrics; import static org.junit.jupiter.api.Assertions.assertEquals; +import static org.junit.jupiter.api.Assertions.assertTrue; import static org.mockito.Mockito.mock; import static org.mockito.Mockito.when; /** * Unit tests for {@link SchemaReporter} */ -@SuppressWarnings("try") +@SuppressWarnings("resource") Review Comment: The point is to suppress the compiler warning caused by the use of an instance of `JsonEmitter` outside of `try-with-resource` block, which should not normally happen, but does make sense for tests. -- 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: pr-unsubscr...@cassandra.apache.org For queries about this service, please contact Infrastructure at: us...@infra.apache.org --------------------------------------------------------------------- To unsubscribe, e-mail: pr-unsubscr...@cassandra.apache.org For additional commands, e-mail: pr-h...@cassandra.apache.org