We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 30e96f9 commit c9d5565Copy full SHA for c9d5565
spring-data-mongodb/src/test/java/org/springframework/data/document/mongodb/mapping/MongoMappingContextUnitTests.java
@@ -0,0 +1,26 @@
1
+package org.springframework.data.document.mongodb.mapping;
2
+
3
+import java.util.Collections;
4
+import java.util.Map;
5
6
+import org.junit.Test;
7
8
+/**
9
+ * Unit tests for {@link MongoMappingContext}.
10
+ *
11
+ * @author Oliver Gierke
12
+ */
13
+public class MongoMappingContextUnitTests {
14
15
+ @Test
16
+ public void addsSelfReferencingPersistentEntityCorrectly() {
17
+ MongoMappingContext context = new MongoMappingContext();
18
+ context.setInitialEntitySet(Collections.singleton(SampleClass.class));
19
+ context.afterPropertiesSet();
20
+ }
21
22
+ public class SampleClass {
23
24
+ Map<String, SampleClass> children;
25
26
+}
0 commit comments