Cleanup warnings
[controller.git] / opendaylight / md-sal / sal-distributed-datastore / src / test / java / org / opendaylight / controller / cluster / datastore / TransactionProxyTest.java
index ca804fdeee4db8f1fb2a4b5a7ddb0ae70cd9c14f..8ee4a2dd7067e43133600312d362d83c18a175bc 100644 (file)
@@ -378,9 +378,10 @@ public class TransactionProxyTest extends AbstractTransactionProxyTest {
 
         Uninterruptibles.awaitUninterruptibly(readComplete, 5, TimeUnit.SECONDS);
 
-        if (caughtEx.get() != null) {
-            Throwables.propagateIfInstanceOf(caughtEx.get(), Exception.class);
-            Throwables.propagate(caughtEx.get());
+        final Throwable t = caughtEx.get();
+        if (t != null) {
+            Throwables.propagateIfPossible(t, Exception.class);
+            throw new RuntimeException(t);
         }
 
         // This sends the batched modification.