|
|
|
|
@ -20,6 +20,7 @@ import static org.assertj.core.api.Assertions.*;
@@ -20,6 +20,7 @@ import static org.assertj.core.api.Assertions.*;
|
|
|
|
|
import static org.mockito.Mockito.*; |
|
|
|
|
import static org.springframework.data.mongodb.core.DocumentTestUtils.*; |
|
|
|
|
|
|
|
|
|
import com.mongodb.DBObject; |
|
|
|
|
import lombok.EqualsAndHashCode; |
|
|
|
|
import lombok.RequiredArgsConstructor; |
|
|
|
|
|
|
|
|
|
@ -2070,9 +2071,11 @@ public class MappingMongoConverterUnitTests {
@@ -2070,9 +2071,11 @@ public class MappingMongoConverterUnitTests {
|
|
|
|
|
|
|
|
|
|
@Test // DATAMONGO-2410
|
|
|
|
|
public void shouldAllowReadingBackDbObject() { |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
assertThat(converter.read(BasicDBObject.class, new org.bson.Document("property", "value"))) |
|
|
|
|
.isEqualTo(new BasicDBObject("property", "value")); |
|
|
|
|
assertThat(converter.read(DBObject.class, new org.bson.Document("property", "value"))) |
|
|
|
|
.isEqualTo(new BasicDBObject("property", "value")); |
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
static class GenericType<T> { |
|
|
|
|
|