Author: asoldano
Date: 2014-02-21 05:18:45 -0500 (Fri, 21 Feb 2014)
New Revision: 18404
Modified:
stack/cxf/trunk/modules/testsuite/shared-tests/src/test/java/org/jboss/test/ws/jaxws/jbws1841/JBWS1841TestCase.java
Log:
Clean initial context only after the all the remote ejb3 calls have been performed
Modified:
stack/cxf/trunk/modules/testsuite/shared-tests/src/test/java/org/jboss/test/ws/jaxws/jbws1841/JBWS1841TestCase.java
===================================================================
---
stack/cxf/trunk/modules/testsuite/shared-tests/src/test/java/org/jboss/test/ws/jaxws/jbws1841/JBWS1841TestCase.java 2014-02-20
18:28:53 UTC (rev 18403)
+++
stack/cxf/trunk/modules/testsuite/shared-tests/src/test/java/org/jboss/test/ws/jaxws/jbws1841/JBWS1841TestCase.java 2014-02-21
10:18:45 UTC (rev 18404)
@@ -30,6 +30,8 @@
import javax.xml.namespace.QName;
import javax.xml.ws.Service;
import javax.naming.InitialContext;
+import javax.naming.NamingException;
+
import java.net.URL;
/**
@@ -53,6 +55,16 @@
public void cleanUp() {
port = null;
remote = null;
+ if (ctx != null)
+ {
+ final InitialContext c = ctx;
+ ctx = null;
+ try {
+ c.close();
+ } catch (NamingException ne) {
+ throw new RuntimeException(ne);
+ }
+ }
}
});
}
@@ -70,15 +82,6 @@
}
}
- protected void tearDown() throws Exception
- {
- if (ctx != null)
- {
- ctx.close();
- ctx = null;
- }
- }
-
public void testDirectWSInvocation() throws Exception
{
String result = port.echo("DirectWSInvocation");
Show replies by date