Ejemplo n.º 1
0
        public void WithPrometheusEndpointReportPathEncodingTest()
        {
            var context         = new DefaultMetricsContext();
            var endpointReports = new MetricsEndpointReports(context.DataProvider, () => new HealthStatus());
            var reports         = endpointReports.WithPrometheusEndpointReport("test/prometheus", new UTF8Encoding(false));

            Assert.AreEqual(endpointReports, reports);
        }
Ejemplo n.º 2
0
        public void WithPrometheusEndpointReportTest()
        {
            var context         = new DefaultMetricsContext();
            var endpointReports = new MetricsEndpointReports(context.DataProvider, () => new HealthStatus());
            var reports         = endpointReports.WithPrometheusEndpointReport();

            Assert.AreEqual(endpointReports, reports);
        }
Ejemplo n.º 3
0
        public void WithPrometheusEndpointReportPathConfigTest()
        {
            var context         = new DefaultMetricsContext();
            var endpointReports = new MetricsEndpointReports(context.DataProvider, () => new HealthStatus());
            var config          = new PrometheusReportConfig
            {
                OutputSetItems = true
            };
            var reports = endpointReports.WithPrometheusEndpointReport(path: "test/prometheus", reportConfig: config);

            Assert.AreEqual(endpointReports, reports);
        }