use of com.codahale.metrics.Gauge in project metrics by dropwizard.
the class MemoryUsageGaugeSetTest method hasAGaugeForHeapCommitted.
@Test
public void hasAGaugeForHeapCommitted() throws Exception {
final Gauge gauge = (Gauge) gauges.getMetrics().get("heap.committed");
assertThat(gauge.getValue()).isEqualTo(10L);
}
use of com.codahale.metrics.Gauge in project metrics by dropwizard.
the class GarbageCollectorMetricSetTest method hasAGaugeForGcCounts.
@Test
public void hasAGaugeForGcCounts() throws Exception {
final Gauge gauge = (Gauge) metrics.getMetrics().get("PS-OldGen.count");
assertThat(gauge.getValue()).isEqualTo(1L);
}
use of com.codahale.metrics.Gauge in project metrics by dropwizard.
the class MemoryUsageGaugeSetTest method hasAGaugeForHeapInit.
@Test
public void hasAGaugeForHeapInit() throws Exception {
final Gauge gauge = (Gauge) gauges.getMetrics().get("heap.init");
assertThat(gauge.getValue()).isEqualTo(20L);
}
use of com.codahale.metrics.Gauge in project metrics by dropwizard.
the class MemoryUsageGaugeSetTest method hasAGaugeForTotalInit.
@Test
public void hasAGaugeForTotalInit() throws Exception {
final Gauge gauge = (Gauge) gauges.getMetrics().get("total.init");
assertThat(gauge.getValue()).isEqualTo(22L);
}
use of com.codahale.metrics.Gauge in project metrics by dropwizard.
the class MemoryUsageGaugeSetTest method hasAGaugeForNonHeapInit.
@Test
public void hasAGaugeForNonHeapInit() throws Exception {
final Gauge gauge = (Gauge) gauges.getMetrics().get("non-heap.init");
assertThat(gauge.getValue()).isEqualTo(2L);
}
Aggregations