X-Git-Url: https://git.opendaylight.org/gerrit/gitweb?a=blobdiff_plain;f=yang%2Fyang-parser-rfc7950%2Fsrc%2Ftest%2Fjava%2Forg%2Fopendaylight%2Fyangtools%2Fyang%2Fstmt%2FIncludedStmtsTest.java;h=1968e1f99214ae6df85b3d79f06278b4dd421bfd;hb=223f7753e408b981b0f077d14ede44b8037425c8;hp=e078597c8a8fdf845a9a07be613030ed74cee448;hpb=c8668229ad6e73d5ae03a52f4b87e8e4d2a67c6e;p=yangtools.git diff --git a/yang/yang-parser-rfc7950/src/test/java/org/opendaylight/yangtools/yang/stmt/IncludedStmtsTest.java b/yang/yang-parser-rfc7950/src/test/java/org/opendaylight/yangtools/yang/stmt/IncludedStmtsTest.java index e078597c8a..1968e1f992 100644 --- a/yang/yang-parser-rfc7950/src/test/java/org/opendaylight/yangtools/yang/stmt/IncludedStmtsTest.java +++ b/yang/yang-parser-rfc7950/src/test/java/org/opendaylight/yangtools/yang/stmt/IncludedStmtsTest.java @@ -5,7 +5,6 @@ * terms of the Eclipse Public License v1.0 which accompanies this distribution, * and is available at http://www.eclipse.org/legal/epl-v10.html */ - package org.opendaylight.yangtools.yang.stmt; import static org.hamcrest.CoreMatchers.anyOf; @@ -15,8 +14,8 @@ import static org.junit.Assert.assertEquals; import static org.junit.Assert.assertNotNull; import static org.opendaylight.yangtools.yang.stmt.StmtTestUtils.sourceForResource; +import java.util.Collection; import java.util.Iterator; -import java.util.Set; import org.junit.AfterClass; import org.junit.BeforeClass; import org.junit.Test; @@ -26,6 +25,7 @@ import org.opendaylight.yangtools.yang.model.api.FeatureDefinition; import org.opendaylight.yangtools.yang.model.api.LeafSchemaNode; import org.opendaylight.yangtools.yang.model.api.Module; import org.opendaylight.yangtools.yang.model.api.SchemaContext; +import org.opendaylight.yangtools.yang.model.api.Submodule; import org.opendaylight.yangtools.yang.model.api.TypeDefinition; import org.opendaylight.yangtools.yang.parser.rfc7950.reactor.RFC7950Reactors; import org.opendaylight.yangtools.yang.parser.spi.meta.ReactorException; @@ -51,10 +51,10 @@ public class IncludedStmtsTest { final Module testModule = result.findModules("root-module").iterator().next(); assertNotNull(testModule); - final Set> typedefs = testModule.getTypeDefinitions(); + final Collection> typedefs = testModule.getTypeDefinitions(); assertEquals(2, typedefs.size()); - final Iterator> typedefsIterator = typedefs.iterator(); + final Iterator> typedefsIterator = typedefs.iterator(); TypeDefinition typedef = typedefsIterator.next(); assertThat(typedef.getQName().getLocalName(), anyOf(is("new-string-type"), is("new-int32-type"))); assertThat(typedef.getBaseType().getQName().getLocalName(), anyOf(is("string"), is("int32"))); @@ -68,10 +68,10 @@ public class IncludedStmtsTest { final Module testModule = result.findModules("root-module").iterator().next(); assertNotNull(testModule); - final Set features = testModule.getFeatures(); + final Collection features = testModule.getFeatures(); assertEquals(2, features.size()); - final Iterator featuresIterator = features.iterator(); + final Iterator featuresIterator = features.iterator(); FeatureDefinition feature = featuresIterator.next(); assertThat(feature.getQName().getLocalName(), anyOf(is("new-feature1"), is("new-feature2"))); feature = featuresIterator.next(); @@ -103,7 +103,7 @@ public class IncludedStmtsTest { final Module testModule = result.findModules("root-module").iterator().next(); assertNotNull(testModule); - final Module subModule = testModule.getSubmodules().iterator().next(); + final Submodule subModule = testModule.getSubmodules().iterator().next(); assertEquals("urn:opendaylight.org/root-module", subModule.getNamespace().toString()); } }