X-Git-Url: https://git.opendaylight.org/gerrit/gitweb?a=blobdiff_plain;f=opendaylight%2Fnetconf%2Fconfig-persister-impl%2Fsrc%2Ftest%2Fjava%2Forg%2Fopendaylight%2Fcontroller%2Fnetconf%2Fpersist%2Fimpl%2Fosgi%2FConfigPersisterTest.java;h=e02e27a745a032e1f36414c63e9e93dfd55e41c1;hb=87837c5398976e1f44418e9f161efea9d5fa4e7c;hp=493ecd9250262959e78523c4ed1dc49c7d177474;hpb=a04257d357eccb69d9fda2c4ac171acdc5b76e28;p=controller.git diff --git a/opendaylight/netconf/config-persister-impl/src/test/java/org/opendaylight/controller/netconf/persist/impl/osgi/ConfigPersisterTest.java b/opendaylight/netconf/config-persister-impl/src/test/java/org/opendaylight/controller/netconf/persist/impl/osgi/ConfigPersisterTest.java index 493ecd9250..e02e27a745 100644 --- a/opendaylight/netconf/config-persister-impl/src/test/java/org/opendaylight/controller/netconf/persist/impl/osgi/ConfigPersisterTest.java +++ b/opendaylight/netconf/config-persister-impl/src/test/java/org/opendaylight/controller/netconf/persist/impl/osgi/ConfigPersisterTest.java @@ -25,9 +25,7 @@ import org.slf4j.LoggerFactory; import org.w3c.dom.Document; import org.xml.sax.SAXException; -import javax.management.MBeanServer; import java.io.IOException; -import java.lang.management.ManagementFactory; import static org.mockito.Matchers.any; import static org.mockito.Matchers.anyString; @@ -41,7 +39,6 @@ public class ConfigPersisterTest { private MockedBundleContext ctx; private ConfigPersisterActivator configPersisterActivator; - private static final MBeanServer mBeanServer = ManagementFactory.getPlatformMBeanServer(); private TestingExceptionHandler handler; @@ -84,7 +81,7 @@ public class ConfigPersisterTest { // this means pushing of config was successful public void assertCannotRegisterAsJMXListener_pushWasSuccessful() { - handler.assertException(RuntimeException.class, "Cannot register as JMX listener to netconf"); + handler.assertException(IllegalStateException.class, "Cannot register as JMX listener to netconf"); } public NetconfOperationService getWorkingService(Document document) throws SAXException, IOException, NetconfDocumentedException {