CsvReporterProvider implements Provider<CsvReporter> { @Override public CsvReporter get() { return CsvReporter.forRegistry(metricRegistry) .formatFor(configuration.getLocale()) .convertDurationsTo(configuration.getUnitDurations()) .convertRatesTo(configuration.getUnitRates()) .filter(new RegexMetricFilter(configuration.getIncludeMetrics())) .build(configuration.getDirectory()); } @Inject  CsvReporterProvider(MetricsCsvReporterConfiguration configuration, MetricRegistry metricRegistry); @Override CsvReporter get();  }
@Test public void get() throws Exception { final CsvReporterProvider provider = new CsvReporterProvider(new MetricsCsvReporterConfiguration(), new MetricRegistry()); final CsvReporter reporter = provider.get(); assertNotNull(reporter); }