ILaunch launch = wc.launch("run", new NullProgressMonitor());
Thread.sleep(10000);
try {
IConnectionProvider defProvider =
ExtensionManager.getProvider(DefaultConnectionProvider.PROVIDER_ID);
HashMap map = new HashMap();
map.put(DefaultConnectionProvider.ID, "Test Connection");
map.put(DefaultConnectionProvider.URL, "service:jmx:rmi:///jndi/rmi://localhost:9999" +
"/jmxrmi");
map.put(DefaultConnectionProvider.USERNAME, "");
map.put(DefaultConnectionProvider.PASSWORD, "");
IConnectionWrapper wrapper = defProvider.createConnection(map);
assertTrue("Connection was null", wrapper != null);
wrapper.connect();
Root root = wrapper.getRoot();
assertTrue("Root was not null", root == null);