BUG-1382: eliminate QName.getPrefix()
[yangtools.git] / yang / yang-parser-impl / src / test / java / org / opendaylight / yangtools / yang / parser / impl / YangParserWithContextTest.java
index f2b076930cca2c812aec1d45d7d77dc706ee6720..f997164fe06fcd7e9dc3d656d0c343af78204604 100644 (file)
@@ -222,8 +222,7 @@ public class YangParserWithContextTest {
 
         // test grouping path
         List<QName> path = new ArrayList<>();
-        QName qname = new QName(URI.create("urn:opendaylight.baz"), simpleDateFormat.parse("2013-02-27"), "baz",
-                "target");
+        QName qname = QName.create(URI.create("urn:opendaylight.baz"), simpleDateFormat.parse("2013-02-27"), "target");
         path.add(qname);
         SchemaPath expectedPath = SchemaPath.create(path, true);
         assertEquals(expectedPath, usesNode.getGroupingPath());
@@ -401,8 +400,8 @@ public class YangParserWithContextTest {
         DateFormat simpleDateFormat = new SimpleDateFormat("yyyy-MM-dd");
         Date expectedRev = simpleDateFormat.parse("2013-07-03");
         List<QName> path = new ArrayList<>();
-        path.add(new QName(expectedNS, expectedRev, "bar", "interfaces"));
-        path.add(new QName(expectedNS, expectedRev, "bar", "ifEntry"));
+        path.add(QName.create(expectedNS, expectedRev, "interfaces"));
+        path.add(QName.create(expectedNS, expectedRev, "ifEntry"));
         SchemaPath expectedPath = SchemaPath.create(path, true);
 
         assertEquals(expectedPath, dev.getTargetPath());