public void richGaugePublicMetrics() {
AnnotationConfigApplicationContext context = new AnnotationConfigApplicationContext(
RichGaugeReaderConfig.class, MetricRepositoryAutoConfiguration.class,
PublicMetricsAutoConfiguration.class);
RichGaugeReader richGaugeReader = context.getBean(RichGaugeReader.class);
assertNotNull(richGaugeReader);
given(richGaugeReader.findAll()).willReturn(
Collections.singletonList(new RichGauge("bar", 3.7d)));
RichGaugeReaderPublicMetrics publicMetrics = context
.getBean(RichGaugeReaderPublicMetrics.class);
assertNotNull(publicMetrics);