From 6c9231a4da6d247e6397512c008857edd90ecd48 Mon Sep 17 00:00:00 2001 From: Spencer Gibb Date: Thu, 4 Oct 2018 11:47:43 -0400 Subject: [PATCH] Verify ConfigProps is a bean and refreshables is actually tested. --- .../cloud/autoconfigure/RefreshAutoConfigurationTests.java | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/spring-cloud-context/src/test/java/org/springframework/cloud/autoconfigure/RefreshAutoConfigurationTests.java b/spring-cloud-context/src/test/java/org/springframework/cloud/autoconfigure/RefreshAutoConfigurationTests.java index 2ec3f28d..9510e72b 100644 --- a/spring-cloud-context/src/test/java/org/springframework/cloud/autoconfigure/RefreshAutoConfigurationTests.java +++ b/spring-cloud-context/src/test/java/org/springframework/cloud/autoconfigure/RefreshAutoConfigurationTests.java @@ -47,6 +47,7 @@ public class RefreshAutoConfigurationTests { try (ConfigurableApplicationContext context = getApplicationContext( WebApplicationType.NONE, Config.class, "config.foo=bar", "spring.cloud.refresh.refreshable:" + ConfigProps.class.getName())) { + context.getBean(ConfigProps.class); context.getBean(ContextRefresher.class).refresh(); } } @@ -57,6 +58,7 @@ public class RefreshAutoConfigurationTests { WebApplicationType.NONE, Config.class, "config.foo=bar", "spring.cloud.refresh.extra-refreshable:" + ConfigProps.class.getName())) { + context.getBean(ConfigProps.class); context.getBean(ContextRefresher.class).refresh(); } } @@ -69,7 +71,7 @@ public class RefreshAutoConfigurationTests { @Configuration @EnableAutoConfiguration(exclude = DataSourceAutoConfiguration.class) - @EnableConfigurationProperties + @EnableConfigurationProperties(ConfigProps.class) static class Config { }