Polish some Map operations
Closes gh-15103
This commit is contained in:
committed by
Stephane Nicoll
parent
804f647a34
commit
3e95af2c85
@@ -68,8 +68,8 @@ class JavaBeanBinder implements BeanBinder {
|
||||
private <T> boolean bind(BeanPropertyBinder propertyBinder, Bean<T> bean,
|
||||
BeanSupplier<T> beanSupplier) {
|
||||
boolean bound = false;
|
||||
for (Map.Entry<String, BeanProperty> entry : bean.getProperties().entrySet()) {
|
||||
bound |= bind(beanSupplier, propertyBinder, entry.getValue());
|
||||
for (BeanProperty beanProperty : bean.getProperties().values()) {
|
||||
bound |= bind(beanSupplier, propertyBinder, beanProperty);
|
||||
}
|
||||
return bound;
|
||||
}
|
||||
|
||||
@@ -620,7 +620,7 @@ public class MapBinderTests {
|
||||
.withExistingValue(Collections.singletonMap("a", "b")))
|
||||
.get();
|
||||
assertThat(result).hasSize(3);
|
||||
assertThat(result.entrySet()).containsExactly(entry("a", "b"), entry("c", "d"),
|
||||
assertThat(result).containsExactly(entry("a", "b"), entry("c", "d"),
|
||||
entry("e", "f"));
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user