diff --git a/spring-boot/src/test/java/org/springframework/boot/context/config/ConfigFileApplicationListenerTests.java b/spring-boot/src/test/java/org/springframework/boot/context/config/ConfigFileApplicationListenerTests.java index 8dac5d4a1cc..ae0e8cc022b 100644 --- a/spring-boot/src/test/java/org/springframework/boot/context/config/ConfigFileApplicationListenerTests.java +++ b/spring-boot/src/test/java/org/springframework/boot/context/config/ConfigFileApplicationListenerTests.java @@ -604,7 +604,7 @@ public class ConfigFileApplicationListenerTests { @Test public void absoluteResourceDefaultsToFile() throws Exception { String location = new File("src/test/resources/specificlocation.properties") - .getAbsolutePath(); + .getAbsolutePath().replace("\\", "/"); TestPropertySourceUtils.addInlinedPropertiesToEnvironment(this.environment, "spring.config.location=" + location); this.initializer.postProcessEnvironment(this.environment, this.application);