mirror of
https://github.com/spring-projects/spring-boot.git
synced 2024-07-15 01:07:30 +08:00
Start building against Spring Framework 6.0.10 snapshots
This reverts commit bc63c511
as Framework's previous behavior has
been restored.
See gh-35751
This commit is contained in:
parent
3eaaf58536
commit
036b982dd7
@ -6,7 +6,7 @@ org.gradle.jvmargs=-Xmx2g -Dfile.encoding=UTF-8
|
|||||||
|
|
||||||
kotlinVersion=1.8.21
|
kotlinVersion=1.8.21
|
||||||
nativeBuildToolsVersion=0.9.22
|
nativeBuildToolsVersion=0.9.22
|
||||||
springFrameworkVersion=6.0.9
|
springFrameworkVersion=6.0.10-SNAPSHOT
|
||||||
tomcatVersion=10.1.8
|
tomcatVersion=10.1.8
|
||||||
|
|
||||||
kotlin.stdlib.default.dependency=false
|
kotlin.stdlib.default.dependency=false
|
||||||
|
@ -24,7 +24,6 @@ import java.util.LinkedHashMap;
|
|||||||
import java.util.List;
|
import java.util.List;
|
||||||
import java.util.Map;
|
import java.util.Map;
|
||||||
import java.util.Properties;
|
import java.util.Properties;
|
||||||
import java.util.SortedMap;
|
|
||||||
import java.util.stream.Collectors;
|
import java.util.stream.Collectors;
|
||||||
|
|
||||||
import org.junit.jupiter.api.Test;
|
import org.junit.jupiter.api.Test;
|
||||||
@ -245,7 +244,7 @@ class MapBinderTests {
|
|||||||
existing.put("baz", 1001);
|
existing.put("baz", 1001);
|
||||||
Bindable<Map<String, Integer>> target = STRING_INTEGER_MAP.withExistingValue(existing);
|
Bindable<Map<String, Integer>> target = STRING_INTEGER_MAP.withExistingValue(existing);
|
||||||
Map<String, Integer> result = this.binder.bind("foo", target).get();
|
Map<String, Integer> result = this.binder.bind("foo", target).get();
|
||||||
assertThat(result).isInstanceOf(HashMap.class);
|
assertThat(result).isExactlyInstanceOf(HashMap.class);
|
||||||
assertThat(result).hasSize(2);
|
assertThat(result).hasSize(2);
|
||||||
assertThat(result).containsEntry("bar", 1);
|
assertThat(result).containsEntry("bar", 1);
|
||||||
assertThat(result).containsEntry("baz", 1001);
|
assertThat(result).containsEntry("baz", 1001);
|
||||||
@ -254,10 +253,10 @@ class MapBinderTests {
|
|||||||
@Test
|
@Test
|
||||||
void bindToMapShouldRespectMapType() {
|
void bindToMapShouldRespectMapType() {
|
||||||
this.sources.add(new MockConfigurationPropertySource("foo.bar", "1"));
|
this.sources.add(new MockConfigurationPropertySource("foo.bar", "1"));
|
||||||
ResolvableType type = ResolvableType.forClassWithGenerics(SortedMap.class, String.class, Integer.class);
|
ResolvableType type = ResolvableType.forClassWithGenerics(HashMap.class, String.class, Integer.class);
|
||||||
Object defaultMap = this.binder.bind("foo", STRING_INTEGER_MAP).get();
|
Object defaultMap = this.binder.bind("foo", STRING_INTEGER_MAP).get();
|
||||||
Object customMap = this.binder.bind("foo", Bindable.of(type)).get();
|
Object customMap = this.binder.bind("foo", Bindable.of(type)).get();
|
||||||
assertThat(customMap).isInstanceOf(SortedMap.class).isNotInstanceOf(defaultMap.getClass());
|
assertThat(customMap).isExactlyInstanceOf(HashMap.class).isNotInstanceOf(defaultMap.getClass());
|
||||||
}
|
}
|
||||||
|
|
||||||
@Test
|
@Test
|
||||||
|
Loading…
Reference in New Issue
Block a user