|
|
|
@ -25,7 +25,6 @@ import java.math.BigInteger; |
|
|
|
import java.net.URL; |
|
|
|
import java.net.URL; |
|
|
|
import java.time.LocalDate; |
|
|
|
import java.time.LocalDate; |
|
|
|
import java.time.LocalDateTime; |
|
|
|
import java.time.LocalDateTime; |
|
|
|
import java.time.ZoneOffset; |
|
|
|
|
|
|
|
import java.time.temporal.ChronoUnit; |
|
|
|
import java.time.temporal.ChronoUnit; |
|
|
|
import java.util.*; |
|
|
|
import java.util.*; |
|
|
|
|
|
|
|
|
|
|
|
@ -106,6 +105,7 @@ import com.mongodb.DBRef; |
|
|
|
* @author Mark Paluch |
|
|
|
* @author Mark Paluch |
|
|
|
* @author Roman Puchkovskiy |
|
|
|
* @author Roman Puchkovskiy |
|
|
|
* @author Heesu Jung |
|
|
|
* @author Heesu Jung |
|
|
|
|
|
|
|
* @author Julia Lee |
|
|
|
*/ |
|
|
|
*/ |
|
|
|
@ExtendWith(MockitoExtension.class) |
|
|
|
@ExtendWith(MockitoExtension.class) |
|
|
|
class MappingMongoConverterUnitTests { |
|
|
|
class MappingMongoConverterUnitTests { |
|
|
|
@ -2619,7 +2619,7 @@ class MappingMongoConverterUnitTests { |
|
|
|
void projectShouldReadSimpleInterfaceProjection() { |
|
|
|
void projectShouldReadSimpleInterfaceProjection() { |
|
|
|
|
|
|
|
|
|
|
|
org.bson.Document source = new org.bson.Document("birthDate", |
|
|
|
org.bson.Document source = new org.bson.Document("birthDate", |
|
|
|
Date.from(LocalDate.of(1999, 12, 1).atStartOfDay().toInstant(ZoneOffset.UTC))).append("foo", "Walter"); |
|
|
|
Date.from(LocalDate.of(1999, 12, 1).atStartOfDay(systemDefault()).toInstant())).append("foo", "Walter"); |
|
|
|
|
|
|
|
|
|
|
|
EntityProjectionIntrospector discoverer = EntityProjectionIntrospector.create(converter.getProjectionFactory(), |
|
|
|
EntityProjectionIntrospector discoverer = EntityProjectionIntrospector.create(converter.getProjectionFactory(), |
|
|
|
EntityProjectionIntrospector.ProjectionPredicate.typeHierarchy() |
|
|
|
EntityProjectionIntrospector.ProjectionPredicate.typeHierarchy() |
|
|
|
@ -2637,7 +2637,7 @@ class MappingMongoConverterUnitTests { |
|
|
|
void projectShouldReadSimpleDtoProjection() { |
|
|
|
void projectShouldReadSimpleDtoProjection() { |
|
|
|
|
|
|
|
|
|
|
|
org.bson.Document source = new org.bson.Document("birthDate", |
|
|
|
org.bson.Document source = new org.bson.Document("birthDate", |
|
|
|
Date.from(LocalDate.of(1999, 12, 1).atStartOfDay().toInstant(ZoneOffset.UTC))).append("foo", "Walter"); |
|
|
|
Date.from(LocalDate.of(1999, 12, 1).atStartOfDay(systemDefault()).toInstant())).append("foo", "Walter"); |
|
|
|
|
|
|
|
|
|
|
|
EntityProjectionIntrospector introspector = EntityProjectionIntrospector.create(converter.getProjectionFactory(), |
|
|
|
EntityProjectionIntrospector introspector = EntityProjectionIntrospector.create(converter.getProjectionFactory(), |
|
|
|
EntityProjectionIntrospector.ProjectionPredicate.typeHierarchy() |
|
|
|
EntityProjectionIntrospector.ProjectionPredicate.typeHierarchy() |
|
|
|
|