Commit 204dd29c authored by Andy Wilkinson's avatar Andy Wilkinson

Fix test on Windows

See gh-26821
parent b5c92d51
...@@ -47,9 +47,11 @@ class BeanNotOfRequiredTypeFailureAnalyzerTests { ...@@ -47,9 +47,11 @@ class BeanNotOfRequiredTypeFailureAnalyzerTests {
assertThat(analysis.getDescription()).startsWith("The bean 'asyncBean'"); assertThat(analysis.getDescription()).startsWith("The bean 'asyncBean'");
assertThat(analysis.getDescription()) assertThat(analysis.getDescription())
.containsPattern("The bean is of type '" + AsyncBean.class.getPackage().getName() + ".\\$Proxy.*'"); .containsPattern("The bean is of type '" + AsyncBean.class.getPackage().getName() + ".\\$Proxy.*'");
assertThat(analysis.getDescription()).contains("and implements:\n\t" + SomeInterface.class.getName()); assertThat(analysis.getDescription())
.contains(String.format("and implements:%n\t") + SomeInterface.class.getName());
assertThat(analysis.getDescription()).contains("Expected a bean of type '" + AsyncBean.class.getName() + "'"); assertThat(analysis.getDescription()).contains("Expected a bean of type '" + AsyncBean.class.getName() + "'");
assertThat(analysis.getDescription()).contains("which implements:\n\t" + SomeInterface.class.getName()); assertThat(analysis.getDescription())
.contains(String.format("which implements:%n\t") + SomeInterface.class.getName());
} }
private FailureAnalysis performAnalysis(Class<?> configuration) { private FailureAnalysis performAnalysis(Class<?> configuration) {
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment