Adjust to yangtools-2.0.0/odlparent-3.0.0 changes
[netconf.git] / netconf / netconf-topology-singleton / src / test / java / org / opendaylight / netconf / topology / singleton / impl / tx / ProxyWriteTransactionTest.java
index 05ad6be8dd82cd92becafcd30f693ab79f1f4cad..b51375b14558803e1c873c358b01b04407e87f5a 100644 (file)
@@ -53,7 +53,7 @@ public class ProxyWriteTransactionTest {
         masterActor = new TestProbe(system);
         final RemoteDeviceId id = new RemoteDeviceId("dev1", InetSocketAddress.createUnresolved("localhost", 17830));
         node = Builders.containerBuilder()
-                .withNodeIdentifier(new YangInstanceIdentifier.NodeIdentifier(QName.create("cont")))
+                .withNodeIdentifier(new YangInstanceIdentifier.NodeIdentifier(QName.create("", "cont")))
                 .build();
         tx = new ProxyWriteTransaction(masterActor.ref(), id, system, Timeout.apply(5, TimeUnit.SECONDS));
     }
@@ -73,10 +73,10 @@ public class ProxyWriteTransactionTest {
 
     @Test
     public void testCancelSubmitted() throws Exception {
-        final CheckedFuture<Void, TransactionCommitFailedException> submitFuture = tx.submit();
+        final ListenableFuture<Void> submitFuture = tx.submit();
         masterActor.expectMsgClass(SubmitRequest.class);
         masterActor.reply(new SubmitReply());
-        submitFuture.checkedGet();
+        submitFuture.get();
         final Future<Boolean> submit = Executors.newSingleThreadExecutor().submit(() -> tx.cancel());
         masterActor.expectNoMsg();
         Assert.assertFalse(submit.get());
@@ -84,18 +84,18 @@ public class ProxyWriteTransactionTest {
 
     @Test
     public void testSubmit() throws Exception {
-        final CheckedFuture<Void, TransactionCommitFailedException> submitFuture = tx.submit();
+        final ListenableFuture<Void> submitFuture = tx.submit();
         masterActor.expectMsgClass(SubmitRequest.class);
         masterActor.reply(new SubmitReply());
-        submitFuture.checkedGet();
+        submitFuture.get();
     }
 
     @Test
     public void testDoubleSubmit() throws Exception {
-        final CheckedFuture<Void, TransactionCommitFailedException> submitFuture = tx.submit();
+        final ListenableFuture<Void> submitFuture = tx.submit();
         masterActor.expectMsgClass(SubmitRequest.class);
         masterActor.reply(new SubmitReply());
-        submitFuture.checkedGet();
+        submitFuture.get();
         try {
             tx.submit().checkedGet();
             Assert.fail("Should throw IllegalStateException");