Bug 6669: Mandatory nodes cannot be added to node from another module via augment
[yangtools.git] / yang / yang-parser-impl / src / test / resources / bugs / bug6669 / valid / test3 / bar.yang
diff --git a/yang/yang-parser-impl/src/test/resources/bugs/bug6669/valid/test3/bar.yang b/yang/yang-parser-impl/src/test/resources/bugs/bug6669/valid/test3/bar.yang
new file mode 100644 (file)
index 0000000..52107de
--- /dev/null
@@ -0,0 +1,30 @@
+module bar {
+    namespace "bar";
+    prefix bar;
+
+    import foo { prefix foo; revision-date 2016-09-08; }
+
+    revision 2016-09-08;
+
+    augment /foo:root {
+        container bar {
+        }
+    }
+
+    augment /foo:root/bar:bar {
+        container bar1 {
+            presence "presence container";
+        }
+    }
+
+    augment /foo:root/bar:bar/bar:bar1 {
+        container bar2 {
+        }
+    }
+
+    augment /foo:root/bar:bar/bar:bar1/bar:bar2 {
+        list l {
+            min-elements 1;
+        }
+    }
+}