BUG-4355: mandatory node presence enforcement
[yangtools.git] / yang / yang-data-impl / src / main / java / org / opendaylight / yangtools / yang / data / impl / schema / tree / ChoiceModificationStrategy.java
index 56e2bac02f81dc33812e211513fd399191484b7c..38edd7bb2f088f5b7cb4f20d10edf1de37223f49 100644 (file)
@@ -108,6 +108,9 @@ final class ChoiceModificationStrategy extends AbstractNodeContainerModification
                         firstChild.getIdentifier(), enforcer, id, other, maybeChild.orNull());
                 }
             }
+
+            // Make sure all mandatory children are present
+            enforcer.enforceOnTreeNode(normalizedNode);
         }
     }