Eliminate ConstraintDefition.isMandatory()
[yangtools.git] / yang / yang-parser-impl / src / test / java / org / opendaylight / yangtools / yang / stmt / EffectiveUsesRefineAndConstraintsTest.java
index ce2a075568b1d0156c570cfc869fee33843b2c97..1d564cc6360a3528adbe0361daf17997dea73c02 100644 (file)
@@ -102,9 +102,9 @@ public class EffectiveUsesRefineAndConstraintsTest {
         assertNotNull(choiceInContainerNode);
 
         ChoiceSchemaNode choiceSchemaNode = (ChoiceSchemaNode) choiceInContainerNode;
+        assertFalse(choiceSchemaNode.isMandatory());
 
         ConstraintDefinition choiceConstraints = choiceSchemaNode.getConstraints();
-        assertFalse(choiceConstraints.isMandatory());
         assertTrue(choiceConstraints.getMustConstraints().isEmpty());
     }
 
@@ -142,9 +142,9 @@ public class EffectiveUsesRefineAndConstraintsTest {
         assertNotNull(choiceInContainerNode);
 
         ChoiceSchemaNode choiceSchemaNode = (ChoiceSchemaNode) choiceInContainerNode;
+        assertTrue(choiceSchemaNode.isMandatory());
 
         ConstraintDefinition choiceConstraints = choiceSchemaNode.getConstraints();
-        assertTrue(choiceConstraints.isMandatory());
         assertTrue(choiceConstraints.getMustConstraints().isEmpty());
     }