mx4j/src/test/test/javax/management/remote JMXConnectorFactoryTest.java,1.5,1.6

[email protected]
Newsgroups gmane.comp.java.mx4j.cvs
Message-ID <[email protected]>
Update of /cvsroot/mx4j/mx4j/src/test/test/javax/management/remote
In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv1428/test/test/javax/management/remote

Modified Files:
	JMXConnectorFactoryTest.java 
Log Message:
Adding a test for bug #907629: loading a resolver with the same mechanism of the provider

Index: JMXConnectorFactoryTest.java
===================================================================
RCS file: /cvsroot/mx4j/mx4j/src/test/test/javax/management/remote/JMXConnectorFactoryTest.java,v
retrieving revision 1.5
retrieving revision 1.6
diff -C2 -d -r1.5 -r1.6
*** JMXConnectorFactoryTest.java	27 Feb 2004 09:52:40 -0000	1.5
--- JMXConnectorFactoryTest.java	1 Mar 2004 18:21:33 -0000	1.6
***************
*** 114,120 ****
        HashMap env = new HashMap();
        JMXServiceURL url = new JMXServiceURL("service:jmx:rmi://host");
! 
        env.put(JMXConnectorFactory.PROTOCOL_PROVIDER_CLASS_LOADER, getClass().getClassLoader());
!       JMXConnectorFactory.connect(url, env);
     }
  
--- 114,121 ----
        HashMap env = new HashMap();
        JMXServiceURL url = new JMXServiceURL("service:jmx:rmi://host");
!       Thread.currentThread().setContextClassLoader(getClass().getClassLoader().getParent());
        env.put(JMXConnectorFactory.PROTOCOL_PROVIDER_CLASS_LOADER, getClass().getClassLoader());
!       JMXConnector connector = JMXConnectorFactory.newJMXConnector(url, env);
!       assertNotNull(connector);
     }
  



-------------------------------------------------------
SF.Net is sponsored by: Speed Start Your Linux Apps Now.
Build and deploy apps & Web services for Linux with
a free DVD software kit from IBM. Click Now!
http://ads.osdn.com/?ad_id=1356&alloc_id=3438&op=click
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.