From b46e81c230595cd1b7cf345f9a31f5a137348276 Mon Sep 17 00:00:00 2001 From: Stephane Nicoll Date: Tue, 1 Aug 2023 14:49:15 +0200 Subject: [PATCH] Start building against Spring Framework 6.1.0-M4 snapshots See gh-36678 --- gradle.properties | 2 +- .../boot/test/context/SpringBootContextLoader.java | 4 ++-- .../boot/test/context/SpringBootTestContextBootstrapper.java | 2 +- 3 files changed, 4 insertions(+), 4 deletions(-) diff --git a/gradle.properties b/gradle.properties index c0cea14c259..4a6916a666a 100644 --- a/gradle.properties +++ b/gradle.properties @@ -6,7 +6,7 @@ org.gradle.jvmargs=-Xmx2g -Dfile.encoding=UTF-8 kotlinVersion=1.9.0 nativeBuildToolsVersion=0.9.23 -springFrameworkVersion=6.1.0-M3 +springFrameworkVersion=6.1.0-SNAPSHOT tomcatVersion=10.1.11 kotlin.stdlib.default.dependency=false diff --git a/spring-boot-project/spring-boot-test/src/main/java/org/springframework/boot/test/context/SpringBootContextLoader.java b/spring-boot-project/spring-boot-test/src/main/java/org/springframework/boot/test/context/SpringBootContextLoader.java index a07e13d1c09..00d9c714eb9 100644 --- a/spring-boot-project/spring-boot-test/src/main/java/org/springframework/boot/test/context/SpringBootContextLoader.java +++ b/spring-boot-project/spring-boot-test/src/main/java/org/springframework/boot/test/context/SpringBootContextLoader.java @@ -230,8 +230,8 @@ public class SpringBootContextLoader extends AbstractContextLoader implements Ao setActiveProfiles(environment, mergedConfig.getActiveProfiles(), applicationEnvironment); ResourceLoader resourceLoader = (application.getResourceLoader() != null) ? application.getResourceLoader() : new DefaultResourceLoader(null); - TestPropertySourceUtils.addPropertiesFilesToEnvironment(environment, resourceLoader, - mergedConfig.getPropertySourceLocations()); + TestPropertySourceUtils.addPropertySourcesToEnvironment(environment, resourceLoader, + mergedConfig.getPropertySourceDescriptors()); TestPropertySourceUtils.addInlinedPropertiesToEnvironment(environment, getInlinedProperties(mergedConfig)); } diff --git a/spring-boot-project/spring-boot-test/src/main/java/org/springframework/boot/test/context/SpringBootTestContextBootstrapper.java b/spring-boot-project/spring-boot-test/src/main/java/org/springframework/boot/test/context/SpringBootTestContextBootstrapper.java index ce07386b1a7..40970888546 100644 --- a/spring-boot-project/spring-boot-test/src/main/java/org/springframework/boot/test/context/SpringBootTestContextBootstrapper.java +++ b/spring-boot-project/spring-boot-test/src/main/java/org/springframework/boot/test/context/SpringBootTestContextBootstrapper.java @@ -376,7 +376,7 @@ public class SpringBootTestContextBootstrapper extends DefaultTestContextBootstr contextCustomizers.add(new SpringBootTestAnnotation(mergedConfig.getTestClass())); return new MergedContextConfiguration(mergedConfig.getTestClass(), mergedConfig.getLocations(), classes, mergedConfig.getContextInitializerClasses(), mergedConfig.getActiveProfiles(), - mergedConfig.getPropertySourceLocations(), propertySourceProperties, contextCustomizers, + mergedConfig.getPropertySourceDescriptors(), propertySourceProperties, contextCustomizers, mergedConfig.getContextLoader(), getCacheAwareContextLoaderDelegate(), mergedConfig.getParent()); }