public MetricsBuilder prometheus(PrometheusConfig prometheus) {
        this.prometheus = prometheus;
        return getThis();
    }
@Test
    void prometheus() {
        PrometheusConfig.Exporter exporter = new PrometheusConfig.Exporter();
        exporter.setEnabled(true);
        exporter.setEnableHttpServiceDiscovery(true);
        exporter.setHttpServiceDiscoveryUrl("localhost:8080");

        PrometheusConfig.Pushgateway pushGateway = new PrometheusConfig.Pushgateway();
        pushGateway.setEnabled(true);
        pushGateway.setBaseUrl("localhost:9091");
        pushGateway.setUsername("username");
        pushGateway.setPassword("password");
        pushGateway.setJob("job");
        pushGateway.setPushInterval(30);

        PrometheusConfig prometheus = new PrometheusConfig();
        prometheus.setExporter(exporter);
        prometheus.setPushgateway(pushGateway);

        MetricsBuilder builder = MetricsBuilder.newBuilder();
        builder.prometheus(prometheus);

        Assertions.assertSame(prometheus, builder.build().getPrometheus());
        Assertions.assertSame(exporter, builder.build().getPrometheus().getExporter());
        Assertions.assertSame(pushGateway, builder.build().getPrometheus().getPushgateway());
        Assertions.assertTrue(builder.build().getPrometheus().getExporter().getEnabled());
        Assertions.assertTrue(builder.build().getPrometheus().getExporter().getEnableHttpServiceDiscovery());
        Assertions.assertEquals(
                "localhost:8080", builder.build().getPrometheus().getExporter().getHttpServiceDiscoveryUrl());
        Assertions.assertTrue(builder.build().getPrometheus().getPushgateway().getEnabled());
        Assertions.assertEquals(
                "localhost:9091",
                builder.build().getPrometheus().getPushgateway().getBaseUrl());
        Assertions.assertEquals(
                "username", builder.build().getPrometheus().getPushgateway().getUsername());
        Assertions.assertEquals(
                "password", builder.build().getPrometheus().getPushgateway().getPassword());
        Assertions.assertEquals(
                "job", builder.build().getPrometheus().getPushgateway().getJob());
        Assertions.assertEquals(
                30, builder.build().getPrometheus().getPushgateway().getPushInterval());
    }