X-Git-Url: https://git.opendaylight.org/gerrit/gitweb?a=blobdiff_plain;f=restconf%2Frestconf-nb-bierman02%2Fsrc%2Ftest%2Fjava%2Forg%2Fopendaylight%2Fcontroller%2Fsal%2Frestconf%2Fimpl%2Finput%2Fto%2Fcnsn%2Ftest%2FRestPutListDataTest.java;h=90d917335d8876f2d97710d4cf08f088e6a99e05;hb=982e75ece2483e413befe3edd8fd90022a644f72;hp=58358d7950584e1928192979932b52be0f28cb77;hpb=61b5bba1c5f1be19252f65f67c43a6e9ba33feb3;p=netconf.git diff --git a/restconf/restconf-nb-bierman02/src/test/java/org/opendaylight/controller/sal/restconf/impl/input/to/cnsn/test/RestPutListDataTest.java b/restconf/restconf-nb-bierman02/src/test/java/org/opendaylight/controller/sal/restconf/impl/input/to/cnsn/test/RestPutListDataTest.java index 58358d7950..90d917335d 100644 --- a/restconf/restconf-nb-bierman02/src/test/java/org/opendaylight/controller/sal/restconf/impl/input/to/cnsn/test/RestPutListDataTest.java +++ b/restconf/restconf-nb-bierman02/src/test/java/org/opendaylight/controller/sal/restconf/impl/input/to/cnsn/test/RestPutListDataTest.java @@ -10,12 +10,12 @@ package org.opendaylight.controller.sal.restconf.impl.input.to.cnsn.test; import static org.junit.Assert.assertEquals; import static org.junit.Assert.assertTrue; import static org.junit.Assert.fail; -import static org.mockito.Matchers.any; +import static org.mockito.ArgumentMatchers.any; import static org.mockito.Mockito.mock; import static org.mockito.Mockito.when; import com.google.common.collect.Iterables; -import com.google.common.util.concurrent.CheckedFuture; +import com.google.common.util.concurrent.FluentFuture; import java.io.FileNotFoundException; import java.util.List; import javax.ws.rs.core.Response.Status; @@ -45,8 +45,8 @@ import org.opendaylight.yangtools.yang.data.api.schema.LeafNode; import org.opendaylight.yangtools.yang.data.api.schema.MapEntryNode; import org.opendaylight.yangtools.yang.data.api.schema.NormalizedNode; import org.opendaylight.yangtools.yang.data.impl.schema.Builders; -import org.opendaylight.yangtools.yang.data.impl.schema.builder.api.DataContainerNodeAttrBuilder; -import org.opendaylight.yangtools.yang.data.impl.schema.builder.api.NormalizedNodeAttrBuilder; +import org.opendaylight.yangtools.yang.data.impl.schema.builder.api.DataContainerNodeBuilder; +import org.opendaylight.yangtools.yang.data.impl.schema.builder.api.NormalizedNodeBuilder; import org.opendaylight.yangtools.yang.data.impl.schema.builder.impl.valid.DataValidationException; import org.opendaylight.yangtools.yang.model.api.DataSchemaNode; import org.opendaylight.yangtools.yang.model.api.LeafSchemaNode; @@ -76,7 +76,7 @@ public class RestPutListDataTest { when(brokerFacade.commitConfigurationDataPut(any(SchemaContext.class), any(YangInstanceIdentifier.class), any(NormalizedNode.class), Mockito.anyString(), Mockito.anyString())) .thenReturn(result); - when(result.getFutureOfPutData()).thenReturn(mock(CheckedFuture.class)); + when(result.getFutureOfPutData()).thenReturn(mock(FluentFuture.class)); when(result.getStatus()).thenReturn(Status.OK); } @@ -174,7 +174,7 @@ public class RestPutListDataTest { final DataSchemaNode testNodeSchemaNode = schemaContextTestModule.getDataChildByName(lstWithCompositeKey); assertTrue(testNodeSchemaNode != null); assertTrue(testNodeSchemaNode instanceof ListSchemaNode); - final DataContainerNodeAttrBuilder testNodeContainer = + final DataContainerNodeBuilder testNodeContainer = Builders.mapEntryBuilder((ListSchemaNode) testNodeSchemaNode); List testChildren = ControllerContext.findInstanceDataChildrenByName( @@ -183,7 +183,7 @@ public class RestPutListDataTest { final DataSchemaNode testLeafKey1SchemaNode = Iterables.getFirst(testChildren, null); assertTrue(testLeafKey1SchemaNode != null); assertTrue(testLeafKey1SchemaNode instanceof LeafSchemaNode); - final NormalizedNodeAttrBuilder> leafKey1 = + final NormalizedNodeBuilder> leafKey1 = Builders.leafBuilder((LeafSchemaNode) testLeafKey1SchemaNode); leafKey1.withValue(payloadKey1); testNodeContainer.withChild(leafKey1.build()); @@ -195,7 +195,7 @@ public class RestPutListDataTest { final DataSchemaNode testLeafKey2SchemaNode = Iterables.getFirst(testChildren, null); assertTrue(testLeafKey2SchemaNode != null); assertTrue(testLeafKey2SchemaNode instanceof LeafSchemaNode); - final NormalizedNodeAttrBuilder> leafKey2 = + final NormalizedNodeBuilder> leafKey2 = Builders.leafBuilder((LeafSchemaNode) testLeafKey2SchemaNode); leafKey2.withValue(payloadKey2); testNodeContainer.withChild(leafKey2.build()); @@ -222,5 +222,4 @@ public class RestPutListDataTest { } return uriBuilder.toString(); } - }