Closes gh-6835
pull/7002/head
Phillip Webb 8 years ago
parent faab9047d6
commit 3172d434a7

@ -80,8 +80,8 @@ public class EndpointDocumentation {
private MvcEndpoints mvcEndpoints;
@Autowired
@Qualifier("metricFilter")
private Filter metricFilter;
@Qualifier("metricsFilter")
private Filter metricsFilter;
@Autowired
@Qualifier("webRequestLoggingFilter")
@ -95,7 +95,7 @@ public class EndpointDocumentation {
@Before
public void setUp() {
this.mockMvc = MockMvcBuilders.webAppContextSetup(this.context)
.addFilters(this.metricFilter, this.traceFilter)
.addFilters(this.metricsFilter, this.traceFilter)
.apply(documentationConfiguration(this.restDocumentation)).build();
}

@ -55,7 +55,7 @@ public class MetricFilterAutoConfiguration {
private GaugeService gaugeService;
@Bean
public MetricsFilter metricFilter() {
public MetricsFilter metricsFilter() {
return new MetricsFilter(this.counterService, this.gaugeService);
}

@ -86,10 +86,8 @@ public class JmsHealthIndicatorTests {
given(connectionMetaData.getJMSProviderName()).willReturn("JMS test provider");
Connection connection = mock(Connection.class);
given(connection.getMetaData()).willReturn(connectionMetaData);
willThrow(new JMSException("Could not start", "123"))
.given(connection).start();
given(connectionFactory.createConnection())
.willReturn(connection);
willThrow(new JMSException("Could not start", "123")).given(connection).start();
given(connectionFactory.createConnection()).willReturn(connection);
JmsHealthIndicator indicator = new JmsHealthIndicator(connectionFactory);
Health health = indicator.health();
assertEquals(Status.DOWN, health.getStatus());

Loading…
Cancel
Save