Slf4jReporterProvider implements Provider<Slf4jReporter> { @Override public Slf4jReporter get() { return Slf4jReporter.forRegistry(metricRegistry) .markWith(configuration.getMarker()) .outputTo(configuration.getLogger()) .withLoggingLevel(configuration.getLevel()) .convertDurationsTo(configuration.getUnitDurations()) .convertRatesTo(configuration.getUnitRates()) .filter(new RegexMetricFilter(configuration.getIncludeMetrics())) .build(); } @Inject  Slf4jReporterProvider(MetricsSlf4jReporterConfiguration configuration, MetricRegistry metricRegistry); @Override Slf4jReporter get();  }
@Test public void get() throws Exception { final Slf4jReporterProvider provider = new Slf4jReporterProvider(new MetricsSlf4jReporterConfiguration(), new MetricRegistry()); final Slf4jReporter reporter = provider.get(); assertNotNull(reporter); }