GaugesCreation { public static Gauge buildGaugeWithoutLabels(String metricName, String help, double value) { Gauge gauge = Gauge.build() .name(metricName) .help(help) .create(); gauge.set(value); return gauge; } private  GaugesCreation(); static Gauge buildGaugeWithLabels(String metricName,
                                             String help,
                                             List<String> labelNames,
                                             List<List<String>> labelValues,
                                             List<Double> values); static Gauge buildGaugeWithoutLabels(String metricName,
                                                String help,
                                                double value);  }
@Test public void shouldBuildGaugeWithoutLabels() { String metricName = "metric_name"; String help = "help"; double value = 1d; Gauge gauge = GaugesCreation.buildGaugeWithoutLabels(metricName, help, value); assertForGauge(gauge, metricName, help, Collections.emptyList(), Collections.singletonList(Collections.emptyList()), Collections.singletonList(value)); }