|
|
|
@ -59,8 +59,8 @@ public class DataSourceBeanCreationFailureAnalyzerTests {
|
|
|
|
|
public void failureAnalysisIsPerformedWithActiveProfiles() {
|
|
|
|
|
this.environment.setActiveProfiles("first", "second");
|
|
|
|
|
FailureAnalysis failureAnalysis = performAnalysis(TestConfiguration.class);
|
|
|
|
|
assertThat(failureAnalysis.getAction()).contains(
|
|
|
|
|
"(the profiles first,¬second are currently active)");
|
|
|
|
|
assertThat(failureAnalysis.getAction())
|
|
|
|
|
.contains("(the profiles first,¬second are currently active)");
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
private FailureAnalysis performAnalysis(Class<?> configuration) {
|
|
|
|
@ -77,6 +77,7 @@ public class DataSourceBeanCreationFailureAnalyzerTests {
|
|
|
|
|
context.setEnvironment(this.environment);
|
|
|
|
|
context.register(configuration);
|
|
|
|
|
context.refresh();
|
|
|
|
|
context.close();
|
|
|
|
|
return null;
|
|
|
|
|
}
|
|
|
|
|
catch (BeanCreationException ex) {
|
|
|
|
|