geronimo-scm mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From djen...@apache.org
Subject svn commit: r151530 - in geronimo/trunk/modules: axis/ axis/src/test/org/apache/geronimo/axis/ axis/src/test/org/apache/geronimo/axis/preconditions/ axis/src/test/org/apache/geronimo/axis/testUtils/ connector-builder/ connector-builder/src/test/org/apache/geronimo/connector/deployment/ connector/ jetty-builder/ jetty/ security-builder/ security/ spring-builder/ system/ tomcat/
Date Sat, 05 Feb 2005 23:47:29 GMT
Author: djencks
Date: Sat Feb  5 15:47:24 2005
New Revision: 151530

URL: http://svn.apache.org/viewcvs?view=rev&rev=151530
Log:
enable assertions in forked tests, fix failures that result

Modified:
    geronimo/trunk/modules/axis/project.properties
    geronimo/trunk/modules/axis/src/test/org/apache/geronimo/axis/AbstractWebServiceTest.java
    geronimo/trunk/modules/axis/src/test/org/apache/geronimo/axis/AxisGBeanTest.java
    geronimo/trunk/modules/axis/src/test/org/apache/geronimo/axis/ComplexTypeWebServiceTest.java
    geronimo/trunk/modules/axis/src/test/org/apache/geronimo/axis/EchoHeadersTest.java
    geronimo/trunk/modules/axis/src/test/org/apache/geronimo/axis/SimpleEJBWebServiceTest.java
    geronimo/trunk/modules/axis/src/test/org/apache/geronimo/axis/SimplePOJOWebServiceTest.java
    geronimo/trunk/modules/axis/src/test/org/apache/geronimo/axis/preconditions/DynamicEJBDeploymentTest.java
    geronimo/trunk/modules/axis/src/test/org/apache/geronimo/axis/testUtils/TestingUtils.java
    geronimo/trunk/modules/connector-builder/project.properties
    geronimo/trunk/modules/connector-builder/src/test/org/apache/geronimo/connector/deployment/ConnectorModuleBuilderTest.java
    geronimo/trunk/modules/connector/project.properties
    geronimo/trunk/modules/jetty-builder/project.properties
    geronimo/trunk/modules/jetty/project.properties
    geronimo/trunk/modules/security-builder/project.properties
    geronimo/trunk/modules/security/project.properties
    geronimo/trunk/modules/spring-builder/project.properties
    geronimo/trunk/modules/system/project.properties
    geronimo/trunk/modules/tomcat/project.properties

Modified: geronimo/trunk/modules/axis/project.properties
URL: http://svn.apache.org/viewcvs/geronimo/trunk/modules/axis/project.properties?view=diff&r1=151529&r2=151530
==============================================================================
--- geronimo/trunk/modules/axis/project.properties (original)
+++ geronimo/trunk/modules/axis/project.properties Sat Feb  5 15:47:24 2005
@@ -6,7 +6,7 @@
 
 maven.repo.remote=http://dist.codehaus.org, http://www.ibiblio.org/maven, http://cvs.apache.org/repository
 
-maven.junit.jvmargs=-Djava.security.auth.login.config=src/test-resources/data/login.config
+maven.junit.jvmargs=-Djava.security.auth.login.config=src/test-resources/data/login.config
-ea
 maven.junit.fork=true
 maven.compile.optimize=false
 maven.compile.fork=true

Modified: geronimo/trunk/modules/axis/src/test/org/apache/geronimo/axis/AbstractWebServiceTest.java
URL: http://svn.apache.org/viewcvs/geronimo/trunk/modules/axis/src/test/org/apache/geronimo/axis/AbstractWebServiceTest.java?view=diff&r1=151529&r2=151530
==============================================================================
--- geronimo/trunk/modules/axis/src/test/org/apache/geronimo/axis/AbstractWebServiceTest.java
(original)
+++ geronimo/trunk/modules/axis/src/test/org/apache/geronimo/axis/AbstractWebServiceTest.java
Sat Feb  5 15:47:24 2005
@@ -37,11 +37,6 @@
  */
 public class AbstractWebServiceTest extends AbstractTestCase {
 
-    private static final String j2eeDomainName = "openejb.server";
-    private static final String j2eeServerName = "TestOpenEJBServer";
-    private static final ObjectName transactionManagerObjectName = JMXUtil.getObjectName(j2eeDomainName
+ ":type=TransactionManager");
-    private static final ObjectName connectionTrackerObjectName = JMXUtil.getObjectName(j2eeDomainName
+ ":type=ConnectionTracker");
-
     protected ObjectName axisname;
     protected ObjectName wsConfgBuilderName;
     protected Kernel kernel;
@@ -65,7 +60,7 @@
         kernel.boot();
         //start the J2EE server which would be started by the server plan
         //in the real case 
-        TestingUtils.startJ2EEContinerAndAxisServlet(kernel);
+        TestingUtils.startJ2EEContainerAndAxisServlet(kernel);
         
         //Start axis gbean        
         GBeanData axisgbData = new GBeanData(axisname,AxisGbean.getGBeanInfo());
@@ -90,57 +85,4 @@
     
      
     
-    protected EARConfigBuilder getEARConfigBuilder() throws Exception {
-        URI defaultParentId = new URI("org/apache/geronimo/Server");
-//        GBeanMBean moduleBuilder = new GBeanMBean(OpenEJBModuleBuilder.GBEAN_INFO);
-//        moduleBuilder.setAttribute("defaultParentId",defaultParentId);
-//        kernel.loadGBean(AxisGeronimoConstants.OPENEJB_MODULE_BUILDER_NAME,moduleBuilder);
-//        
-//        
-//        //<gbean name="geronimo.deployer:role=Builder,type=EAR,config=org/apache/geronimo/J2EEDeployer"
class="org.apache.geronimo.j2ee.deployment.EARConfigBuilder">
-//        //    <attribute name="defaultParentId">org/apache/geronimo/Server</attribute>
-//        //    <attribute name="j2eeServer" type="javax.management.ObjectName">geronimo.server:j2eeType=J2EEServer,name=geronimo</attribute>
-//        //    <attribute name="transactionContextManagerObjectName" type="javax.management.ObjectName">geronimo.server:type=TransactionContextManager</attribute>
-//        //    <attribute name="connectionTrackerObjectName" type="javax.management.ObjectName">geronimo.server:type=ConnectionTracker</attribute>
-//        //    <attribute name="transactionalTimerObjectName" type="javax.management.ObjectName">geronimo.server:type=ThreadPooledTimer,name=TransactionalThreadPooledTimer</attribute>
-//        //    <attribute name="nonTransactionalTimerObjectName" type="javax.management.ObjectName">geronimo.server:type=ThreadPooledTimer,name=NonTransactionalThreadPooledTimer</attribute>
-//        //    <reference name="Repository">*:role=Repository,*</reference>
-//        //    <reference name="EJBConfigBuilder">geronimo.deployer:role=ModuleBuilder,type=EJB,config=org/apache/geronimo/J2EEDeployer</reference>
-//        //    <reference name="EJBReferenceBuilder">geronimo.deployer:role=ModuleBuilder,type=EJB,config=org/apache/geronimo/J2EEDeployer</reference>
-//        //    <reference name="WebConfigBuilder">geronimo.deployer:role=ModuleBuilder,type=Web,config=org/apache/geronimo/J2EEDeployer</reference>
-//        //    <reference name="ConnectorConfigBuilder">geronimo.deployer:role=ModuleBuilder,type=Connector,config=org/apache/geronimo/J2EEDeployer</reference>
-//        //    <reference name="ResourceReferenceBuilder">geronimo.deployer:role=ModuleBuilder,type=Connector,config=org/apache/geronimo/J2EEDeployer</reference>
-//        //    <reference name="AppClientConfigBuilder">geronimo.deployer:role=ModuleBuilder,type=AppClient,config=org/apache/geronimo/J2EEDeployer</reference>
-//        //</gbean>
-//        
-//        GBeanMBean earmoduleBuilder = new GBeanMBean(EARConfigBuilder.GBEAN_INFO);
-//        moduleBuilder.setAttribute("defaultParentId",defaultParentId);
-//        moduleBuilder.setAttribute("transactionContextManagerObjectName",AxisGeronimoConstants.TRANSACTION_CONTEXT_MANAGER_NAME);
-//        moduleBuilder.setAttribute("connectionTrackerObjectName",AxisGeronimoConstants.CONNECTION_TRACKER_NAME);
-//        moduleBuilder.setReferencePattern("EJBConfigBuilder",AxisGeronimoConstants.OPENEJB_MODULE_BUILDER_NAME);
-//        moduleBuilder.setReferencePattern("EJBReferenceBuilder",AxisGeronimoConstants.OPENEJB_MODULE_BUILDER_NAME);
-//        moduleBuilder.setReferencePattern("ResourceReferenceBuilder",AxisGeronimoConstants.OPENEJB_MODULE_BUILDER_NAME);
-//        
-//        
-//        kernel.loadGBean(AxisGeronimoConstants.EAR_CONF_BUILDER_NAME,moduleBuilder);
-//        
-        OpenEJBModuleBuilder moduleBuilder = new OpenEJBModuleBuilder(defaultParentId, null,
null);
-        
-       EARConfigBuilder earConfigBuilder =
-                new EARConfigBuilder(defaultParentId,
-                        transactionManagerObjectName,
-                        connectionTrackerObjectName,
-                        null,
-                        null,
-                        null,
-                        moduleBuilder,
-                        moduleBuilder,
-                        null,
-                        null,
-                        TestingUtils.RESOURCE_REFERANCE_BUILDER,
-                        null,
-                        null,
-                        null);
-        return earConfigBuilder;
-    }
 }

Modified: geronimo/trunk/modules/axis/src/test/org/apache/geronimo/axis/AxisGBeanTest.java
URL: http://svn.apache.org/viewcvs/geronimo/trunk/modules/axis/src/test/org/apache/geronimo/axis/AxisGBeanTest.java?view=diff&r1=151529&r2=151530
==============================================================================
--- geronimo/trunk/modules/axis/src/test/org/apache/geronimo/axis/AxisGBeanTest.java (original)
+++ geronimo/trunk/modules/axis/src/test/org/apache/geronimo/axis/AxisGBeanTest.java Sat Feb
 5 15:47:24 2005
@@ -80,7 +80,7 @@
         name = new ObjectName("test:name=AxisGBean");
         kernel = new Kernel("test.kernel");
         kernel.boot();
-        TestingUtils.startJ2EEContinerAndAxisServlet(kernel);
+        TestingUtils.startJ2EEContainerAndAxisServlet(kernel);
     }
 
     protected void tearDown() throws Exception {

Modified: geronimo/trunk/modules/axis/src/test/org/apache/geronimo/axis/ComplexTypeWebServiceTest.java
URL: http://svn.apache.org/viewcvs/geronimo/trunk/modules/axis/src/test/org/apache/geronimo/axis/ComplexTypeWebServiceTest.java?view=diff&r1=151529&r2=151530
==============================================================================
--- geronimo/trunk/modules/axis/src/test/org/apache/geronimo/axis/ComplexTypeWebServiceTest.java
(original)
+++ geronimo/trunk/modules/axis/src/test/org/apache/geronimo/axis/ComplexTypeWebServiceTest.java
Sat Feb  5 15:47:24 2005
@@ -46,8 +46,7 @@
   
         File jarfile = new File(getTestFile("target/generated/samples/echo-ewsimpl.jar"));
         
-        EARConfigBuilder earConfigBuilder = getEARConfigBuilder();
-        TestingUtils.buildConfiguration(jarfile,store,earConfigBuilder,kernel,wsConfgBuilderName);
       
+        TestingUtils.buildConfiguration(jarfile,store,kernel,wsConfgBuilderName);       

 
         //check the real web service invocations 
         Class echoLoacaterClass = ClassUtils.forName("org.apache.ws.echosample.EchoServiceLocator");

Modified: geronimo/trunk/modules/axis/src/test/org/apache/geronimo/axis/EchoHeadersTest.java
URL: http://svn.apache.org/viewcvs/geronimo/trunk/modules/axis/src/test/org/apache/geronimo/axis/EchoHeadersTest.java?view=diff&r1=151529&r2=151530
==============================================================================
--- geronimo/trunk/modules/axis/src/test/org/apache/geronimo/axis/EchoHeadersTest.java (original)
+++ geronimo/trunk/modules/axis/src/test/org/apache/geronimo/axis/EchoHeadersTest.java Sat
Feb  5 15:47:24 2005
@@ -60,7 +60,7 @@
         ClassLoader cl = getClass().getClassLoader();
         ClassLoader myCl = new URLClassLoader(new URL[]{}, cl);
         
-        TestingUtils.startJ2EEContinerAndAxisServlet(kernel);
+        TestingUtils.startJ2EEContainerAndAxisServlet(kernel);
         GBeanData gbean = new GBeanData(name,AxisGbean.getGBeanInfo());
         gbean.setAttribute("Name", "Test");
         kernel.loadGBean(gbean,myCl);

Modified: geronimo/trunk/modules/axis/src/test/org/apache/geronimo/axis/SimpleEJBWebServiceTest.java
URL: http://svn.apache.org/viewcvs/geronimo/trunk/modules/axis/src/test/org/apache/geronimo/axis/SimpleEJBWebServiceTest.java?view=diff&r1=151529&r2=151530
==============================================================================
--- geronimo/trunk/modules/axis/src/test/org/apache/geronimo/axis/SimpleEJBWebServiceTest.java
(original)
+++ geronimo/trunk/modules/axis/src/test/org/apache/geronimo/axis/SimpleEJBWebServiceTest.java
Sat Feb  5 15:47:24 2005
@@ -42,8 +42,7 @@
 
         File jarfile = new File(getTestFile("target/generated/samples/echo-jar/echo-ewsimpl.jar"));
         
-        EARConfigBuilder earConfigBuilder = getEARConfigBuilder();
-        TestingUtils.buildConfiguration(jarfile,store,earConfigBuilder,kernel,wsConfgBuilderName);
       
+        TestingUtils.buildConfiguration(jarfile,store,kernel,wsConfgBuilderName);
 
         URL wsdlrequestUrl = AxisGeronimoUtils.getURL("/axis/services/echoPort?wsdl");
         //+"/axis/services/AdminService?wsdl");

Modified: geronimo/trunk/modules/axis/src/test/org/apache/geronimo/axis/SimplePOJOWebServiceTest.java
URL: http://svn.apache.org/viewcvs/geronimo/trunk/modules/axis/src/test/org/apache/geronimo/axis/SimplePOJOWebServiceTest.java?view=diff&r1=151529&r2=151530
==============================================================================
--- geronimo/trunk/modules/axis/src/test/org/apache/geronimo/axis/SimplePOJOWebServiceTest.java
(original)
+++ geronimo/trunk/modules/axis/src/test/org/apache/geronimo/axis/SimplePOJOWebServiceTest.java
Sat Feb  5 15:47:24 2005
@@ -42,8 +42,7 @@
         ClassLoader myCl = new URLClassLoader(new URL[]{}, cl);
         File jarfile = new File(getTestFile("target/generated/samples/echo-war/echo-ewsimpl.jar"));
   
-        EARConfigBuilder earConfigBuilder = getEARConfigBuilder();
-        TestingUtils.buildConfiguration(jarfile,store,earConfigBuilder,kernel,wsConfgBuilderName);
+        TestingUtils.buildConfiguration(jarfile,store,kernel,wsConfgBuilderName);
 
         //let us try to brows the WSDL of the service
         URL wsdlrequestUrl = AxisGeronimoUtils.getURL("/axis/services/echoPort?wsdl");

Modified: geronimo/trunk/modules/axis/src/test/org/apache/geronimo/axis/preconditions/DynamicEJBDeploymentTest.java
URL: http://svn.apache.org/viewcvs/geronimo/trunk/modules/axis/src/test/org/apache/geronimo/axis/preconditions/DynamicEJBDeploymentTest.java?view=diff&r1=151529&r2=151530
==============================================================================
--- geronimo/trunk/modules/axis/src/test/org/apache/geronimo/axis/preconditions/DynamicEJBDeploymentTest.java
(original)
+++ geronimo/trunk/modules/axis/src/test/org/apache/geronimo/axis/preconditions/DynamicEJBDeploymentTest.java
Sat Feb  5 15:47:24 2005
@@ -64,10 +64,10 @@
         System.setProperty(javax.naming.Context.URL_PKG_PREFIXES, str);
         kernel = new Kernel("blah");
         kernel.boot();
-       // TestingUtils.startJ2EEContinerAndAxisServlet(kernel);
+       // TestingUtils.startJ2EEContainerAndAxisServlet(kernel);
     }
 
-    private ResourceReferenceBuilder resourceReferenceBuilder = TestingUtils.RESOURCE_REFERANCE_BUILDER;
+    private ResourceReferenceBuilder resourceReferenceBuilder = TestingUtils.resourceReferenceBuilder;
     public void testEJBJarDeploy() throws Exception {
         File jarFile = new File(outDir , "echo-jar/echo-ewsimpl.jar");
         

Modified: geronimo/trunk/modules/axis/src/test/org/apache/geronimo/axis/testUtils/TestingUtils.java
URL: http://svn.apache.org/viewcvs/geronimo/trunk/modules/axis/src/test/org/apache/geronimo/axis/testUtils/TestingUtils.java?view=diff&r1=151529&r2=151530
==============================================================================
--- geronimo/trunk/modules/axis/src/test/org/apache/geronimo/axis/testUtils/TestingUtils.java
(original)
+++ geronimo/trunk/modules/axis/src/test/org/apache/geronimo/axis/testUtils/TestingUtils.java
Sat Feb  5 15:47:24 2005
@@ -20,10 +20,13 @@
 import java.net.URL;
 import java.util.Collections;
 import java.util.Enumeration;
+import java.util.Map;
+import java.util.List;
 import java.util.jar.JarFile;
 import java.util.zip.ZipEntry;
 import javax.management.ObjectName;
 import javax.naming.Reference;
+import javax.xml.namespace.QName;
 
 import org.apache.geronimo.axis.AxisGeronimoUtils;
 import org.apache.geronimo.axis.WSPlan;
@@ -31,49 +34,31 @@
 import org.apache.geronimo.gbean.GBeanInfo;
 import org.apache.geronimo.j2ee.deployment.EARConfigBuilder;
 import org.apache.geronimo.j2ee.deployment.ResourceReferenceBuilder;
+import org.apache.geronimo.j2ee.deployment.ServiceReferenceBuilder;
+import org.apache.geronimo.j2ee.deployment.Module;
 import org.apache.geronimo.kernel.Kernel;
+import org.apache.geronimo.kernel.jmx.JMXUtil;
 import org.apache.geronimo.kernel.config.Configuration;
 import org.apache.geronimo.kernel.config.ConfigurationManager;
 import org.apache.geronimo.kernel.config.ConfigurationStore;
 import org.apache.geronimo.transaction.OnlineUserTransaction;
+import org.apache.geronimo.deployment.DeploymentContext;
+import org.apache.geronimo.common.DeploymentException;
+import org.apache.geronimo.jetty.JettyWebAppContext;
+import org.openejb.deployment.OpenEJBModuleBuilder;
 
 /**
  * @version $Rev: $ $Date: $
  */
 public class TestingUtils {
 
-    protected static J2EEManager j2eeManager = new J2EEManager();
-
-
-    public static void startJ2EEContinerAndAxisServlet(Kernel kernel) throws Exception {
-        //This does the work need to be done by plan
-        j2eeManager.startJ2EEContainer(kernel);
-        //start the Axis Serverlet which would be started by the service plan
-        ClassLoader classLoader = Thread.currentThread().getContextClassLoader();
-        GBeanInfo gbeanInfo = GBeanInfo.getGBeanInfo("org.apache.geronimo.jetty.JettyWebAppContext",
classLoader);
-        GBeanData app = new GBeanData(AxisGeronimoConstants.APPLICATION_NAME, gbeanInfo);
-        URL url = classLoader.getResource("deployables/axis/");
-        System.out.print(url);
-        app.setAttribute("uri", URI.create(url.toString()));
-        app.setAttribute("contextPath", "/axis");
-        app.setAttribute("componentContext", null);
-        OnlineUserTransaction userTransaction = new OnlineUserTransaction();
-        app.setAttribute("userTransaction", userTransaction);
-        app.setAttribute("webClassPath", new URI[0]);
-        app.setAttribute("contextPriorityClassLoader", Boolean.FALSE);
-        app.setReferencePatterns("JettyContainer", Collections.singleton(AxisGeronimoConstants.WEB_CONTAINER_NAME));
-        app.setAttribute("configurationBaseUrl", Thread.currentThread().getContextClassLoader().getResource("deployables/"));
-        app.setReferencePattern("TransactionContextManager", AxisGeronimoConstants.TRANSACTION_CONTEXT_MANAGER_NAME);
-        app.setReferencePattern("TrackedConnectionAssociator", AxisGeronimoConstants.TRACKED_CONNECTION_ASSOCIATOR_NAME);
-        AxisGeronimoUtils.startGBean(app, kernel, classLoader);
-
-    }
+    private static final String j2eeDomainName = "openejb.server";
+    private static final String j2eeServerName = "TestOpenEJBServer";
 
-    public static void stopJ2EEContinerAndAxisServlet(Kernel kernel) throws Exception {
-        j2eeManager.stopJ2EEContainer(kernel);
-    }
-
-    public static ResourceReferenceBuilder RESOURCE_REFERANCE_BUILDER = new ResourceReferenceBuilder()
{
+    private static final ObjectName transactionManagerObjectName = JMXUtil.getObjectName(j2eeDomainName
+ ":type=TransactionManager");
+    private static final ObjectName connectionTrackerObjectName = JMXUtil.getObjectName(j2eeDomainName
+ ":type=ConnectionTracker");
+    protected static J2EEManager j2eeManager = new J2EEManager();
+    public static ResourceReferenceBuilder resourceReferenceBuilder = new ResourceReferenceBuilder()
{
 
         public Reference createResourceRef(String containerId, Class iface) {
             return null;
@@ -104,12 +89,70 @@
         }
     };
 
+    private static ServiceReferenceBuilder serviceReferenceBuilder = new ServiceReferenceBuilder()
{
+
+        //it could return a Service or a Reference, we don't care
+        public Object createService(Class serviceInterface, URI wsdlURI, URI jaxrpcMappingURI,
QName serviceQName, Map portComponentRefMap, List handlers, DeploymentContext deploymentContext,
Module module, ClassLoader classLoader) throws DeploymentException {
+            return null;
+        }
+    };
+
+
+    public static void startJ2EEContainerAndAxisServlet(Kernel kernel) throws Exception {
+        //This does the work need to be done by plan
+        j2eeManager.startJ2EEContainer(kernel);
+        //start the Axis Serverlet which would be started by the service plan
+        ClassLoader classLoader = Thread.currentThread().getContextClassLoader();
+        GBeanData app = new GBeanData(AxisGeronimoConstants.APPLICATION_NAME, JettyWebAppContext.GBEAN_INFO);
+        URL url = classLoader.getResource("deployables/axis/");
+        System.out.print(url);
+        app.setAttribute("uri", URI.create(url.toString()));
+        app.setAttribute("contextPath", "/axis");
+        app.setAttribute("componentContext", Collections.EMPTY_MAP);
+        OnlineUserTransaction userTransaction = new OnlineUserTransaction();
+        app.setAttribute("userTransaction", userTransaction);
+        app.setAttribute("webClassPath", new URI[0]);
+        app.setAttribute("contextPriorityClassLoader", Boolean.FALSE);
+        app.setReferencePatterns("JettyContainer", Collections.singleton(AxisGeronimoConstants.WEB_CONTAINER_NAME));
+        app.setAttribute("configurationBaseUrl", Thread.currentThread().getContextClassLoader().getResource("deployables/"));
+        app.setReferencePattern("TransactionContextManager", AxisGeronimoConstants.TRANSACTION_CONTEXT_MANAGER_NAME);
+        app.setReferencePattern("TrackedConnectionAssociator", AxisGeronimoConstants.TRACKED_CONNECTION_ASSOCIATOR_NAME);
+        AxisGeronimoUtils.startGBean(app, kernel, classLoader);
+
+    }
+
+    public static void stopJ2EEContinerAndAxisServlet(Kernel kernel) throws Exception {
+        j2eeManager.stopJ2EEContainer(kernel);
+    }
+
+
+    protected static EARConfigBuilder getEARConfigBuilder() throws Exception {
+        URI defaultParentId = new URI("org/apache/geronimo/Server");
+        OpenEJBModuleBuilder moduleBuilder = new OpenEJBModuleBuilder(defaultParentId, null,
null);
+
+       EARConfigBuilder earConfigBuilder =
+                new EARConfigBuilder(defaultParentId,
+                        transactionManagerObjectName,
+                        connectionTrackerObjectName,
+                        null,
+                        null,
+                        null,
+                        moduleBuilder,
+                        moduleBuilder,
+                        null,
+                        null,
+                        resourceReferenceBuilder,
+                        null,
+                        serviceReferenceBuilder,
+                        null);
+        return earConfigBuilder;
+    }
 
     public static void buildConfiguration(File jarfile,
             ConfigurationStore store,
-            EARConfigBuilder earConfigBuilder,
             Kernel kernel,
             ObjectName wsConfgBuilderName) throws Exception {
+        EARConfigBuilder earConfigBuilder = getEARConfigBuilder();
 
         ObjectName wsconf = new ObjectName("geronimo.test:name=" + jarfile.getName() + ",value=check");
         URI wsURI = new URI("new");

Modified: geronimo/trunk/modules/connector-builder/project.properties
URL: http://svn.apache.org/viewcvs/geronimo/trunk/modules/connector-builder/project.properties?view=diff&r1=151529&r2=151530
==============================================================================
--- geronimo/trunk/modules/connector-builder/project.properties (original)
+++ geronimo/trunk/modules/connector-builder/project.properties Sat Feb  5 15:47:24 2005
@@ -10,6 +10,6 @@
 maven.eclipse.classpath.include=target/xmlbeans
 maven.junit.fork=true
 
-maven.junit.jvmargs=-Djava.security.auth.login.config=src/test-data/data/login.config
+maven.junit.jvmargs=-Djava.security.auth.login.config=src/test-data/data/login.config -ea
 
 maven.idea.generated.source=xmlbeans

Modified: geronimo/trunk/modules/connector-builder/src/test/org/apache/geronimo/connector/deployment/ConnectorModuleBuilderTest.java
URL: http://svn.apache.org/viewcvs/geronimo/trunk/modules/connector-builder/src/test/org/apache/geronimo/connector/deployment/ConnectorModuleBuilderTest.java?view=diff&r1=151529&r2=151530
==============================================================================
--- geronimo/trunk/modules/connector-builder/src/test/org/apache/geronimo/connector/deployment/ConnectorModuleBuilderTest.java
(original)
+++ geronimo/trunk/modules/connector-builder/src/test/org/apache/geronimo/connector/deployment/ConnectorModuleBuilderTest.java
Sat Feb  5 15:47:24 2005
@@ -32,18 +32,20 @@
 import java.sql.Connection;
 import java.sql.Statement;
 import java.util.Collections;
+import java.util.Iterator;
 import java.util.List;
 import java.util.Map;
 import java.util.Set;
-import java.util.Iterator;
 import java.util.jar.JarFile;
 import javax.management.MalformedObjectNameException;
 import javax.management.ObjectName;
 import javax.sql.DataSource;
 import javax.xml.namespace.QName;
+import javax.naming.Reference;
 
 import junit.framework.TestCase;
 import org.apache.geronimo.common.DeploymentException;
+import org.apache.geronimo.connector.outbound.connectiontracking.ConnectionTrackingCoordinator;
 import org.apache.geronimo.deployment.DeploymentContext;
 import org.apache.geronimo.deployment.util.DeploymentUtil;
 import org.apache.geronimo.gbean.GBeanData;
@@ -55,21 +57,22 @@
 import org.apache.geronimo.j2ee.deployment.ModuleBuilder;
 import org.apache.geronimo.j2ee.deployment.RefContext;
 import org.apache.geronimo.j2ee.deployment.ServiceReferenceBuilder;
+import org.apache.geronimo.j2ee.deployment.EJBReferenceBuilder;
+import org.apache.geronimo.j2ee.deployment.ResourceReferenceBuilder;
 import org.apache.geronimo.j2ee.j2eeobjectnames.J2eeContext;
 import org.apache.geronimo.j2ee.j2eeobjectnames.J2eeContextImpl;
 import org.apache.geronimo.j2ee.j2eeobjectnames.NameFactory;
 import org.apache.geronimo.j2ee.management.impl.J2EEServerImpl;
 import org.apache.geronimo.kernel.Kernel;
-import org.apache.geronimo.kernel.jmx.JMXUtil;
-import org.apache.geronimo.kernel.registry.BasicGBeanRegistry;
 import org.apache.geronimo.kernel.config.Configuration;
 import org.apache.geronimo.kernel.config.ConfigurationStore;
 import org.apache.geronimo.kernel.config.InvalidConfigException;
 import org.apache.geronimo.kernel.config.NoSuchConfigException;
+import org.apache.geronimo.kernel.jmx.JMXUtil;
 import org.apache.geronimo.kernel.management.State;
+import org.apache.geronimo.kernel.registry.BasicGBeanRegistry;
+import org.apache.geronimo.kernel.repository.Repository;
 import org.apache.geronimo.system.serverinfo.ServerInfo;
-import org.apache.geronimo.connector.outbound.connectiontracking.ConnectionTracker;
-import org.apache.geronimo.connector.outbound.connectiontracking.ConnectionTrackingCoordinator;
 import org.tranql.sql.jdbc.JDBCUtil;
 
 /**
@@ -84,6 +87,64 @@
     private int defaultBlockingTimeoutMilliseconds = 5000;
     private int defaultidleTimeoutMinutes = 15;
     private URI defaultParentId;
+    private Repository repository = new Repository() {
+
+                public boolean hasURI(URI uri) {
+                    return false;
+                }
+
+                public URL getURL(URI uri) throws MalformedURLException {
+                    return null;
+                }
+            };
+
+    private EJBReferenceBuilder ejbReferenceBuilder = new EJBReferenceBuilder() {
+
+        public Reference createEJBLocalReference(String objectName, boolean isSession, String
localHome, String local) throws DeploymentException {
+            return null;
+        }
+
+        public Reference createEJBRemoteReference(String objectName, boolean isSession, String
home, String remote) throws DeploymentException {
+            return null;
+        }
+    };
+
+    private ResourceReferenceBuilder resourceReferenceBuilder = new ResourceReferenceBuilder()
{
+
+        public Reference createResourceRef(String containerId, Class iface) throws DeploymentException
{
+            return null;
+        }
+
+        public Reference createAdminObjectRef(String containerId, Class iface) throws DeploymentException
{
+            return null;
+        }
+
+        public ObjectName locateResourceName(ObjectName query) throws DeploymentException
{
+            return null;
+        }
+
+        public GBeanData locateActivationSpecInfo(ObjectName resourceAdapterName, String
messageListenerInterface) throws DeploymentException {
+            return null;
+        }
+
+        public GBeanData locateResourceAdapterGBeanData(ObjectName resourceAdapterModuleName)
throws DeploymentException {
+            return null;
+        }
+
+        public GBeanData locateAdminObjectInfo(ObjectName resourceAdapterModuleName, String
adminObjectInterfaceName) throws DeploymentException {
+            return null;
+        }
+
+        public GBeanData locateConnectionFactoryInfo(ObjectName resourceAdapterModuleName,
String connectionFactoryInterfaceName) throws DeploymentException {
+            return null;
+        }
+    };
+    private ServiceReferenceBuilder serviceReferenceBuilder = new ServiceReferenceBuilder()
{
+                                        //it could return a Service or a Reference, we don't
care
+                                        public Object createService(Class serviceInterface,
URI wsdlURI, URI jaxrpcMappingURI, QName serviceQName, Map portComponentRefMap, List handlers,
DeploymentContext deploymentContext, Module module, ClassLoader classLoader) {
+                                            return null;
+                                        }
+                                    };
 
 
     public void testBuildEar() throws Exception {
@@ -98,7 +159,7 @@
             kernel.startGBean(store.getName());
 
             rarFile = DeploymentUtil.createJarFile(new File(basedir, "target/test-ear-noger.ear"));
-            EARConfigBuilder configBuilder = new EARConfigBuilder(defaultParentId, null,
connectionTrackerName, null, null, null, null, null, null, new ConnectorModuleBuilder(defaultParentId,
defaultMaxSize, defaultMinSize, defaultBlockingTimeoutMilliseconds, defaultidleTimeoutMinutes,
defaultXATransactionCaching, defaultXAThreadCaching, null, kernel), null, null, null, kernel);
+            EARConfigBuilder configBuilder = new EARConfigBuilder(defaultParentId, null,
connectionTrackerName, null, null, null, null, ejbReferenceBuilder, null, new ConnectorModuleBuilder(defaultParentId,
defaultMaxSize, defaultMinSize, defaultBlockingTimeoutMilliseconds, defaultidleTimeoutMinutes,
defaultXATransactionCaching, defaultXAThreadCaching, repository, kernel), resourceReferenceBuilder,
null, serviceReferenceBuilder, kernel);
             File tempDir = null;
             try {
                 tempDir = DeploymentUtil.createTempDir();
@@ -233,7 +294,7 @@
             GBeanData store = new GBeanData(JMXUtil.getObjectName("foo:j2eeType=ConfigurationStore,name=mock"),
MockConfigStore.GBEAN_INFO);
             kernel.loadGBean(store, this.getClass().getClassLoader());
             kernel.startGBean(store.getName());
-            ConnectorModuleBuilder moduleBuilder = new ConnectorModuleBuilder(defaultParentId,
defaultMaxSize, defaultMinSize, defaultBlockingTimeoutMilliseconds, defaultidleTimeoutMinutes,
defaultXATransactionCaching, defaultXAThreadCaching, null, kernel);
+            ConnectorModuleBuilder moduleBuilder = new ConnectorModuleBuilder(defaultParentId,
defaultMaxSize, defaultMinSize, defaultBlockingTimeoutMilliseconds, defaultidleTimeoutMinutes,
defaultXATransactionCaching, defaultXAThreadCaching, repository, kernel);
             File rarFile = action.getRARFile();
 
             ClassLoader oldCl = Thread.currentThread().getContextClassLoader();
@@ -261,14 +322,9 @@
                         connectionTrackerName,
                         null,
                         null,
-                        new RefContext(null,
+                        new RefContext(ejbReferenceBuilder,
                                 moduleBuilder,
-                                new ServiceReferenceBuilder() {
-                                    //it could return a Service or a Reference, we don't
care
-                                    public Object createService(Class serviceInterface, URI
wsdlURI, URI jaxrpcMappingURI, QName serviceQName, Map portComponentRefMap, List handlers,
DeploymentContext deploymentContext, Module module, ClassLoader classLoader) {
-                                        return null;
-                                    }
-                                }));
+                                serviceReferenceBuilder));
 
                 action.install(moduleBuilder, earContext, module);
                 earContext.getClassLoader(null);

Modified: geronimo/trunk/modules/connector/project.properties
URL: http://svn.apache.org/viewcvs/geronimo/trunk/modules/connector/project.properties?view=diff&r1=151529&r2=151530
==============================================================================
--- geronimo/trunk/modules/connector/project.properties (original)
+++ geronimo/trunk/modules/connector/project.properties Sat Feb  5 15:47:24 2005
@@ -9,4 +9,4 @@
 # Include the generated xmlbean classes in the eclipse classpath
 maven.junit.fork=true
 
-maven.junit.jvmargs=-Djava.security.auth.login.config=src/test-data/data/login.config
+maven.junit.jvmargs=-Djava.security.auth.login.config=src/test-data/data/login.config -ea

Modified: geronimo/trunk/modules/jetty-builder/project.properties
URL: http://svn.apache.org/viewcvs/geronimo/trunk/modules/jetty-builder/project.properties?view=diff&r1=151529&r2=151530
==============================================================================
--- geronimo/trunk/modules/jetty-builder/project.properties (original)
+++ geronimo/trunk/modules/jetty-builder/project.properties Sat Feb  5 15:47:24 2005
@@ -6,7 +6,7 @@
 
 maven.repo.remote=http://www.apache.org/~jboynes, http://www.mortbay.org/maven, http://www.openejb.org/maven,
http://dist.codehaus.org, http://www.ibiblio.org/maven, http://www.apache.org/dist/java-repository/
 
-maven.junit.jvmargs=-Djava.security.auth.login.config=src/test-resources/data/login.config
+maven.junit.jvmargs=-Djava.security.auth.login.config=src/test-resources/data/login.config
-ea
 maven.junit.fork=true
 
 # Include the generated xmlbean classes in the eclipse classpath

Modified: geronimo/trunk/modules/jetty/project.properties
URL: http://svn.apache.org/viewcvs/geronimo/trunk/modules/jetty/project.properties?view=diff&r1=151529&r2=151530
==============================================================================
--- geronimo/trunk/modules/jetty/project.properties (original)
+++ geronimo/trunk/modules/jetty/project.properties Sat Feb  5 15:47:24 2005
@@ -6,5 +6,5 @@
 
 maven.repo.remote=http://www.apache.org/~jboynes, http://www.mortbay.org/maven, http://www.openejb.org/maven,
http://dist.codehaus.org, http://www.ibiblio.org/maven, http://www.apache.org/dist/java-repository/
 
-maven.junit.jvmargs=-Djava.security.auth.login.config=src/test-resources/data/login.config
+maven.junit.jvmargs=-Djava.security.auth.login.config=src/test-resources/data/login.config
-ea
 maven.junit.fork=true

Modified: geronimo/trunk/modules/security-builder/project.properties
URL: http://svn.apache.org/viewcvs/geronimo/trunk/modules/security-builder/project.properties?view=diff&r1=151529&r2=151530
==============================================================================
--- geronimo/trunk/modules/security-builder/project.properties (original)
+++ geronimo/trunk/modules/security-builder/project.properties Sat Feb  5 15:47:24 2005
@@ -20,7 +20,7 @@
 ##
 
 maven.repo.remote=http://www.openejb.org/maven, http://www.ibiblio.org/maven
-maven.junit.jvmargs=-Djava.security.auth.login.config=src/test-data/data/login.config -Dlog4j.configuration=file:log4j.properties
+maven.junit.jvmargs=-Djava.security.auth.login.config=src/test-data/data/login.config -Dlog4j.configuration=file:log4j.properties
-ea
 maven.junit.fork=true
 # Include the generated xmlbean classes in the eclipse classpath
 maven.eclipse.classpath.include=target/xmlbeans

Modified: geronimo/trunk/modules/security/project.properties
URL: http://svn.apache.org/viewcvs/geronimo/trunk/modules/security/project.properties?view=diff&r1=151529&r2=151530
==============================================================================
--- geronimo/trunk/modules/security/project.properties (original)
+++ geronimo/trunk/modules/security/project.properties Sat Feb  5 15:47:24 2005
@@ -20,5 +20,5 @@
 ##
 
 maven.repo.remote=http://www.openejb.org/maven, http://www.ibiblio.org/maven
-maven.junit.jvmargs=-Djava.security.auth.login.config=src/test-data/data/login.config -Dlog4j.configuration=file:log4j.properties
+maven.junit.jvmargs=-Djava.security.auth.login.config=src/test-data/data/login.config -Dlog4j.configuration=file:log4j.properties
-ea
 maven.junit.fork=true

Modified: geronimo/trunk/modules/spring-builder/project.properties
URL: http://svn.apache.org/viewcvs/geronimo/trunk/modules/spring-builder/project.properties?view=diff&r1=151529&r2=151530
==============================================================================
--- geronimo/trunk/modules/spring-builder/project.properties (original)
+++ geronimo/trunk/modules/spring-builder/project.properties Sat Feb  5 15:47:24 2005
@@ -6,7 +6,7 @@
 
 maven.repo.remote=http://www.apache.org/~jboynes, http://www.mortbay.org/maven, http://www.openejb.org/maven,
http://dist.codehaus.org, http://www.ibiblio.org/maven, http://www.apache.org/dist/java-repository/
 
-maven.junit.jvmargs=-Djava.security.auth.login.config=src/test-resources/data/login.config
+maven.junit.jvmargs=-Djava.security.auth.login.config=src/test-resources/data/login.config
-ea
 maven.junit.fork=true
 
 # Include the generated xmlbean classes in the eclipse classpath

Modified: geronimo/trunk/modules/system/project.properties
URL: http://svn.apache.org/viewcvs/geronimo/trunk/modules/system/project.properties?view=diff&r1=151529&r2=151530
==============================================================================
--- geronimo/trunk/modules/system/project.properties (original)
+++ geronimo/trunk/modules/system/project.properties Sat Feb  5 15:47:24 2005
@@ -19,5 +19,5 @@
 ## $Rev$ $Date$
 ##
 
-maven.junit.jvmargs=-Djava.io.tmpdir=target/tmp
+maven.junit.jvmargs=-Djava.io.tmpdir=target/tmp -ea
 maven.junit.fork=true

Modified: geronimo/trunk/modules/tomcat/project.properties
URL: http://svn.apache.org/viewcvs/geronimo/trunk/modules/tomcat/project.properties?view=diff&r1=151529&r2=151530
==============================================================================
--- geronimo/trunk/modules/tomcat/project.properties (original)
+++ geronimo/trunk/modules/tomcat/project.properties Sat Feb  5 15:47:24 2005
@@ -3,5 +3,5 @@
 ##
 
 maven.repo.remote=http://www.apache.org/~jlaskowski/maven, http://www.ibiblio.org/maven
-maven.junit.jvmargs=-Djava.endorsed.dirs=${maven.build.dir}/endorsed -Djava.security.auth.login.config=src/test-resources/data/login.config
+maven.junit.jvmargs=-Djava.endorsed.dirs=${maven.build.dir}/endorsed -Djava.security.auth.login.config=src/test-resources/data/login.config
-ea
 maven.junit.fork=true



Mime
View raw message