X-Git-Url: https://git.opendaylight.org/gerrit/gitweb?a=blobdiff_plain;f=opendaylight%2Fmd-sal%2Fsal-rest-connector%2Fsrc%2Ftest%2Fjava%2Forg%2Fopendaylight%2Fcontroller%2Fsal%2Frestconf%2Fimpl%2Ftest%2FURITest.java;h=efd5482bfe7925e1dd81706544ca8d1f178ea2ed;hb=bfcc4fd3a238b227e246cb869558d707dadcdb34;hp=4900e6a66f1ab9d9d3324c85e6ca5c98f103e5ba;hpb=e90c8ce4f0fbcef2097f56e63e83dff232b7f39a;p=controller.git diff --git a/opendaylight/md-sal/sal-rest-connector/src/test/java/org/opendaylight/controller/sal/restconf/impl/test/URITest.java b/opendaylight/md-sal/sal-rest-connector/src/test/java/org/opendaylight/controller/sal/restconf/impl/test/URITest.java index 4900e6a66f..efd5482bfe 100644 --- a/opendaylight/md-sal/sal-rest-connector/src/test/java/org/opendaylight/controller/sal/restconf/impl/test/URITest.java +++ b/opendaylight/md-sal/sal-rest-connector/src/test/java/org/opendaylight/controller/sal/restconf/impl/test/URITest.java @@ -13,8 +13,8 @@ import static org.junit.Assert.assertTrue; import static org.mockito.Matchers.any; import static org.mockito.Mockito.mock; import static org.mockito.Mockito.when; - import com.google.common.base.Optional; +import com.google.common.collect.ImmutableList; import com.google.common.collect.Iterables; import java.io.FileNotFoundException; import java.util.Set; @@ -124,7 +124,7 @@ public class URITest { .toInstanceIdentifier("simple-nodes:users/yang-ext:mount/test-interface2:class/student/name"); assertEquals( "[(urn:ietf:params:xml:ns:yang:test-interface2?revision=2014-08-01)class, (urn:ietf:params:xml:ns:yang:test-interface2?revision=2014-08-01)student[{(urn:ietf:params:xml:ns:yang:test-interface2?revision=2014-08-01)name=name}]]", - instanceIdentifier.getInstanceIdentifier().getPath().toString()); + ImmutableList.copyOf(instanceIdentifier.getInstanceIdentifier().getPathArguments()).toString()); } @Test @@ -140,8 +140,7 @@ public class URITest { exception.expect(RestconfDocumentedException.class); controllerContext.setMountService(null); - InstanceIdentifierContext instanceIdentifier = controllerContext - .toInstanceIdentifier("simple-nodes:users/yang-ext:mount/test-interface2:class/student/name"); + controllerContext.toInstanceIdentifier("simple-nodes:users/yang-ext:mount/test-interface2:class/student/name"); } @Test @@ -149,8 +148,7 @@ public class URITest { initMountService(false); exception.expect(RestconfDocumentedException.class); - InstanceIdentifierContext instanceIdentifier = controllerContext - .toInstanceIdentifier("simple-nodes:users/yang-ext:mount/test-interface2:class"); + controllerContext.toInstanceIdentifier("simple-nodes:users/yang-ext:mount/test-interface2:class"); } public void initMountService(final boolean withSchema) {