dain 2005/05/08 15:37:11
Modified: modules/core/src/test/org/openejb/server/xfire
WSContainerTest.java
Log:
Added KernelFactory for pluggable kernel
Kernel is now an interface
Moved Kernel implementation to basic kernel
Converted JMX registry and config manager to plain old gbeans (they do not
require special access to the kernel)
Magic attributes such as state and enabled are now accessed via kernel methods
Use of getAttribute and invoke for magic attributes and state transition is
now deprecated
Cleaned up cruft in GBean infos such as declaration of non existent attributes
Upgraded to newest CGLIB, asm, and commons-collections
Revision Changes Path
1.8 +5 -5
openejb/modules/core/src/test/org/openejb/server/xfire/WSContainerTest.java
Index: WSContainerTest.java
===================================================================
RCS file:
/home/projects/openejb/scm/openejb/modules/core/src/test/org/openejb/server/xfire/WSContainerTest.java,v
retrieving revision 1.7
retrieving revision 1.8
diff -u -r1.7 -r1.8
--- WSContainerTest.java 25 Mar 2005 11:23:42 -0000 1.7
+++ WSContainerTest.java 8 May 2005 19:37:11 -0000 1.8
@@ -67,6 +67,7 @@
import junit.framework.TestCase;
import org.apache.geronimo.gbean.GBeanData;
+import org.apache.geronimo.kernel.KernelFactory;
import org.apache.geronimo.kernel.Kernel;
import org.apache.geronimo.kernel.jmx.JMXUtil;
import org.apache.geronimo.kernel.management.State;
@@ -94,7 +95,7 @@
}
public void xtestGetWSDL() throws Exception {
- Kernel kernel = new Kernel("wstest");
+ Kernel kernel = KernelFactory.newInstance().createKernel("wstest");
kernel.boot();
URL wsdlURL = new
File("target/test-ejb-jar/META-INF/wsdl/test-ejb.wsdl").toURL();
@@ -145,7 +146,7 @@
}
public void testAxisStyleMessage() throws Exception {
- Kernel kernel = new Kernel("wstest");
+ Kernel kernel = KernelFactory.newInstance().createKernel("wstest");
kernel.boot();
URL wsdlURL = new
File("target/test-ejb-jar/META-INF/wsdl/test-ejb.wsdl").toURL();
@@ -204,8 +205,7 @@
}
private void assertRunning(Kernel kernel, ObjectName objectName) throws
Exception {
- int state = ((Integer) kernel.getAttribute(objectName,
"state")).intValue();
- assertEquals("should be running: " + objectName,
State.RUNNING_INDEX, state);
+ assertEquals("should be running: " + objectName,
State.RUNNING_INDEX, kernel.getGBeanState(objectName));
}
private String getResult(InputStream responseStream) throws
ParserConfigurationException, SAXException, IOException {