geronimo-scm mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From djen...@apache.org
Subject svn commit: r525609 [2/3] - in /geronimo/server/trunk/modules: geronimo-connector-builder/src/main/java/org/apache/geronimo/connector/deployment/ geronimo-connector-builder/src/test/java/org/apache/geronimo/connector/deployment/annotation/ geronimo-con...
Date Wed, 04 Apr 2007 21:20:05 GMT
Added: geronimo/server/trunk/modules/geronimo-j2ee-builder/src/test/java/org/apache/geronimo/j2ee/deployment/annotation/AnnotationHelperTest.java
URL: http://svn.apache.org/viewvc/geronimo/server/trunk/modules/geronimo-j2ee-builder/src/test/java/org/apache/geronimo/j2ee/deployment/annotation/AnnotationHelperTest.java?view=auto&rev=525609
==============================================================================
--- geronimo/server/trunk/modules/geronimo-j2ee-builder/src/test/java/org/apache/geronimo/j2ee/deployment/annotation/AnnotationHelperTest.java (added)
+++ geronimo/server/trunk/modules/geronimo-j2ee-builder/src/test/java/org/apache/geronimo/j2ee/deployment/annotation/AnnotationHelperTest.java Wed Apr  4 14:20:03 2007
@@ -0,0 +1,265 @@
+/**
+ *  Licensed to the Apache Software Foundation (ASF) under one or more
+ *  contributor license agreements.  See the NOTICE file distributed with
+ *  this work for additional information regarding copyright ownership.
+ *  The ASF licenses this file to You under the Apache License, Version 2.0
+ *  (the "License"); you may not use this file except in compliance with
+ *  the License.  You may obtain a copy of the License at
+ *
+ *     http://www.apache.org/licenses/LICENSE-2.0
+ *
+ *  Unless required by applicable law or agreed to in writing, software
+ *  distributed under the License is distributed on an "AS IS" BASIS,
+ *  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ *  See the License for the specific language governing permissions and
+ *  limitations under the License.
+ */
+
+package org.apache.geronimo.j2ee.deployment.annotation;
+
+import java.lang.reflect.Field;
+import java.lang.reflect.Method;
+import java.net.URL;
+import java.util.ArrayList;
+import java.util.Arrays;
+import java.util.List;
+
+import javax.ejb.EJB;
+import javax.ejb.EJBs;
+import javax.jws.HandlerChain;
+import javax.persistence.PersistenceContext;
+import javax.persistence.PersistenceContexts;
+import javax.persistence.PersistenceUnit;
+import javax.persistence.PersistenceUnits;
+import javax.xml.ws.WebServiceRef;
+import javax.xml.ws.WebServiceRefs;
+
+import org.apache.geronimo.kernel.config.Configuration;
+import org.apache.geronimo.testsupport.XmlBeansTestSupport;
+import org.apache.geronimo.xbeans.javaee.WebAppDocument;
+import org.apache.geronimo.xbeans.javaee.WebAppType;
+import org.apache.xbean.finder.ClassFinder;
+import org.apache.xmlbeans.XmlCursor;
+import org.apache.xmlbeans.XmlException;
+import org.apache.xmlbeans.XmlObject;
+import org.apache.xmlbeans.XmlOptions;
+
+/**
+ * Testcases for each of the various AnnotationHelper class
+ */
+public class AnnotationHelperTest extends XmlBeansTestSupport {
+
+    private Class[] classes = {EJBAnnotationTest.class, HandlerChainAnnotationTest.class,
+        PersistenceContextAnnotationTest.class, PersistenceUnitAnnotationTest.class,
+        WebServiceRefAnnotationTest.class};
+
+    private ClassFinder classFinder = new ClassFinder(classes);
+    private ClassLoader classLoader = this.getClass().getClassLoader();
+    private XmlOptions options = new XmlOptions();
+
+
+    public void testEJBAnnotationHelper() throws Exception {
+
+        //-------------------------------------------------
+        // Ensure annotations are discovered correctly
+        //-------------------------------------------------
+        List<Class> annotatedClasses = classFinder.findAnnotatedClasses(EJBs.class);
+        assertNotNull(annotatedClasses);
+        assertEquals(1, annotatedClasses.size());
+        assertTrue(annotatedClasses.contains(EJBAnnotationTest.class));
+
+        List<Method> annotatedMethods = classFinder.findAnnotatedMethods(EJB.class);
+        assertNotNull(annotatedMethods);
+        assertEquals(2, annotatedMethods.size());
+        assertTrue(annotatedMethods.contains(EJBAnnotationTest.class.getDeclaredMethod("setAnnotatedMethod1", new Class[]{int.class})));
+        assertTrue(annotatedMethods.contains(EJBAnnotationTest.class.getDeclaredMethod("setAnnotatedMethod2", new Class[]{String.class})));
+
+        List<Field> annotatedFields = classFinder.findAnnotatedFields(EJB.class);
+        assertNotNull(annotatedFields);
+        assertEquals(2, annotatedFields.size());
+        assertTrue(annotatedFields.contains(EJBAnnotationTest.class.getDeclaredField("annotatedField1")));
+        assertTrue(annotatedFields.contains(EJBAnnotationTest.class.getDeclaredField("annotatedField2")));
+
+        //-------------------------------------------------
+        // Ensure annotations are processed correctly
+        //-------------------------------------------------
+        URL srcXML = classLoader.getResource("annotation/empty-web-src.xml");
+        XmlObject xmlObject = XmlObject.Factory.parse(srcXML, options);
+        WebAppDocument webAppDoc = (WebAppDocument) xmlObject.changeType(WebAppDocument.type);
+        WebAppType webApp = webAppDoc.getWebApp();
+        AnnotatedWebApp annotatedWebApp = new AnnotatedWebApp(webApp);
+        EJBAnnotationHelper.processAnnotations(annotatedWebApp, classFinder);
+        URL expectedXML = classLoader.getResource("annotation/ejb-expected.xml");
+        XmlObject expected = XmlObject.Factory.parse(expectedXML);
+        log.debug("[@EJB Source XML] " + '\n' + webApp.toString() + '\n');
+        log.debug("[@EJB Expected XML]" + '\n' + expected.toString() + '\n');
+        List problems = new ArrayList();
+        boolean ok = compareXmlObjects(webApp, expected, problems);
+        assertTrue("Differences: " + problems, ok);
+    }
+
+
+    public void testHandlerChainAnnotationHelper() throws Exception {
+
+        //-------------------------------------------------
+        // Ensure annotations are discovered correctly
+        //-------------------------------------------------
+        List<Class> annotatedClasses = classFinder.findAnnotatedClasses(HandlerChain.class);
+        assertNotNull(annotatedClasses);
+        assertEquals(1, annotatedClasses.size());
+        assertTrue(annotatedClasses.contains(HandlerChainAnnotationTest.class));
+
+        List<Method> annotatedMethods = classFinder.findAnnotatedMethods(HandlerChain.class);
+        assertNotNull(annotatedMethods);
+        assertEquals(2, annotatedMethods.size());
+        assertTrue(annotatedMethods.contains(HandlerChainAnnotationTest.class.getDeclaredMethod("setAnnotatedMethod1", new Class[]{String.class})));
+        assertTrue(annotatedMethods.contains(HandlerChainAnnotationTest.class.getDeclaredMethod("setAnnotatedMethod2", new Class[]{int.class})));
+
+        List<Field> annotatedFields = classFinder.findAnnotatedFields(HandlerChain.class);
+        assertNotNull(annotatedFields);
+        assertEquals(2, annotatedFields.size());
+        assertTrue(annotatedFields.contains(HandlerChainAnnotationTest.class.getDeclaredField("annotatedField1")));
+        assertTrue(annotatedFields.contains(HandlerChainAnnotationTest.class.getDeclaredField("annotatedField2")));
+
+        //-------------------------------------------------
+        // Ensure annotations are processed correctly
+        //-------------------------------------------------
+        URL srcXML = classLoader.getResource("annotation/handler-chain-src.xml");
+        XmlObject xmlObject = XmlObject.Factory.parse(srcXML, options);
+        WebAppDocument webAppDoc = (WebAppDocument) xmlObject.changeType(WebAppDocument.type);
+        WebAppType webApp = webAppDoc.getWebApp();
+        AnnotatedWebApp annotatedWebApp = new AnnotatedWebApp(webApp);
+        HandlerChainAnnotationHelper.processAnnotations(annotatedWebApp, classFinder);
+        URL expectedXML = classLoader.getResource("annotation/handler-chain-expected.xml");
+        XmlObject expected = XmlObject.Factory.parse(expectedXML);
+        log.debug("[@HandlerChain Source XML] " + '\n' + webApp.toString() + '\n');
+        log.debug("[@HandlerChain Expected XML]" + '\n' + expected.toString() + '\n');
+        List problems = new ArrayList();
+        boolean ok = compareXmlObjects(webApp, expected, problems);
+        assertTrue("Differences: " + problems, ok);
+    }
+
+
+    public void testPersistenceContextAnnotationHelper() throws Exception {
+
+        //-------------------------------------------------
+        // Ensure annotations are discovered correctly
+        //-------------------------------------------------
+        List<Class> annotatedClasses = classFinder.findAnnotatedClasses(PersistenceContexts.class);
+        assertNotNull(annotatedClasses);
+        assertEquals(1, annotatedClasses.size());
+        assertTrue(annotatedClasses.contains(PersistenceContextAnnotationTest.class));
+
+        List<Method> annotatedMethods = classFinder.findAnnotatedMethods(PersistenceContext.class);
+        assertNotNull(annotatedMethods);
+        assertEquals(2, annotatedMethods.size());
+        assertTrue(annotatedMethods.contains(PersistenceContextAnnotationTest.class.getDeclaredMethod("setAnnotatedMethod1", new Class[]{String.class})));
+        assertTrue(annotatedMethods.contains(PersistenceContextAnnotationTest.class.getDeclaredMethod("setAnnotatedMethod2", new Class[]{String.class})));
+
+        List<Field> annotatedFields = classFinder.findAnnotatedFields(PersistenceContext.class);
+        assertNotNull(annotatedFields);
+        assertEquals(2, annotatedFields.size());
+        assertTrue(annotatedFields.contains(PersistenceContextAnnotationTest.class.getDeclaredField("annotatedField1")));
+        assertTrue(annotatedFields.contains(PersistenceContextAnnotationTest.class.getDeclaredField("annotatedField2")));
+
+        //-------------------------------------------------
+        // Ensure annotations are processed correctly
+        //-------------------------------------------------
+        URL srcXML = classLoader.getResource("annotation/empty-web-src.xml");
+        XmlObject xmlObject = XmlObject.Factory.parse(srcXML, options);
+        WebAppDocument webAppDoc = (WebAppDocument) xmlObject.changeType(WebAppDocument.type);
+        WebAppType webApp = webAppDoc.getWebApp();
+        AnnotatedWebApp annotatedWebApp = new AnnotatedWebApp(webApp);
+        PersistenceContextAnnotationHelper.processAnnotations(annotatedWebApp, classFinder);
+        URL expectedXML = classLoader.getResource("annotation/persistence-context-expected.xml");
+        XmlObject expected = XmlObject.Factory.parse(expectedXML);
+        log.debug("[@PersistenceContext Source XML] " + '\n' + webApp.toString() + '\n');
+        log.debug("[@PersistenceContext Expected XML]" + '\n' + expected.toString() + '\n');
+        List problems = new ArrayList();
+        boolean ok = compareXmlObjects(webApp, expected, problems);
+        assertTrue("Differences: " + problems, ok);
+    }
+
+
+    public void testPersistenceUnitAnnotationHelper() throws Exception {
+
+        List<Class> annotatedClasses = classFinder.findAnnotatedClasses(PersistenceUnits.class);
+        assertNotNull(annotatedClasses);
+        assertEquals(1, annotatedClasses.size());
+        assertTrue(annotatedClasses.contains(PersistenceUnitAnnotationTest.class));
+
+        List<Method> annotatedMethods = classFinder.findAnnotatedMethods(PersistenceUnit.class);
+        assertNotNull(annotatedMethods);
+        assertEquals(2, annotatedMethods.size());
+        assertTrue(annotatedMethods.contains(PersistenceUnitAnnotationTest.class.getDeclaredMethod("setAnnotatedMethod1", new Class[]{int.class})));
+        assertTrue(annotatedMethods.contains(PersistenceUnitAnnotationTest.class.getDeclaredMethod("setAnnotatedMethod2", new Class[]{boolean.class})));
+
+        List<Field> annotatedFields = classFinder.findAnnotatedFields(PersistenceUnit.class);
+        assertNotNull(annotatedFields);
+        assertEquals(2, annotatedFields.size());
+        assertTrue(annotatedFields.contains(PersistenceUnitAnnotationTest.class.getDeclaredField("annotatedField1")));
+        assertTrue(annotatedFields.contains(PersistenceUnitAnnotationTest.class.getDeclaredField("annotatedField2")));
+
+        //-------------------------------------------------
+        // Ensure annotations are processed correctly
+        //-------------------------------------------------
+        URL srcXML = classLoader.getResource("annotation/empty-web-src.xml");
+        XmlObject xmlObject = XmlObject.Factory.parse(srcXML, options);
+        WebAppDocument webAppDoc = (WebAppDocument) xmlObject.changeType(WebAppDocument.type);
+        WebAppType webApp = webAppDoc.getWebApp();
+        AnnotatedWebApp annotatedWebApp = new AnnotatedWebApp(webApp);
+        PersistenceUnitAnnotationHelper.processAnnotations(annotatedWebApp, classFinder);
+        URL expectedXML = classLoader.getResource("annotation/persistence-unit-expected.xml");
+        XmlObject expected = XmlObject.Factory.parse(expectedXML);
+        log.debug("[@PersistenceUnit Source XML] " + '\n' + webApp.toString() + '\n');
+        log.debug("[@PersistenceUnit Expected XML]" + '\n' + expected.toString() + '\n');
+        List problems = new ArrayList();
+        boolean ok = compareXmlObjects(webApp, expected, problems);
+        assertTrue("Differences: " + problems, ok);
+    }
+
+
+    public void testWebServiceRefAnnotationHelper() throws Exception {
+
+        //-------------------------------------------------
+        // Ensure annotations are discovered correctly
+        //-------------------------------------------------
+        List<Class> annotatedClasses = classFinder.findAnnotatedClasses(WebServiceRefs.class);
+        assertNotNull(annotatedClasses);
+        assertEquals(1, annotatedClasses.size());
+        assertTrue(annotatedClasses.contains(WebServiceRefAnnotationTest.class));
+
+        List<Method> annotatedMethods = classFinder.findAnnotatedMethods(WebServiceRef.class);
+        assertNotNull(annotatedMethods);
+        assertEquals(4, annotatedMethods.size());
+        assertTrue(annotatedMethods.contains(WebServiceRefAnnotationTest.class.getDeclaredMethod("setAnnotatedMethod1", new Class[]{boolean.class})));
+        assertTrue(annotatedMethods.contains(WebServiceRefAnnotationTest.class.getDeclaredMethod("setAnnotatedMethod2", new Class[]{String.class})));
+        assertTrue(annotatedMethods.contains(HandlerChainAnnotationTest.class.getDeclaredMethod("setAnnotatedMethod1", new Class[]{String.class})));
+        assertTrue(annotatedMethods.contains(HandlerChainAnnotationTest.class.getDeclaredMethod("setAnnotatedMethod2", new Class[]{int.class})));
+
+        List<Field> annotatedFields = classFinder.findAnnotatedFields(WebServiceRef.class);
+        assertNotNull(annotatedFields);
+        assertEquals(4, annotatedFields.size());
+        assertTrue(annotatedFields.contains(WebServiceRefAnnotationTest.class.getDeclaredField("annotatedField1")));
+        assertTrue(annotatedFields.contains(WebServiceRefAnnotationTest.class.getDeclaredField("annotatedField2")));
+        assertTrue(annotatedFields.contains(HandlerChainAnnotationTest.class.getDeclaredField("annotatedField1")));
+        assertTrue(annotatedFields.contains(HandlerChainAnnotationTest.class.getDeclaredField("annotatedField2")));
+
+        //-------------------------------------------------
+        // Ensure annotations are processed correctly
+        //-------------------------------------------------
+        URL srcXML = classLoader.getResource("annotation/empty-web-src.xml");
+        XmlObject xmlObject = XmlObject.Factory.parse(srcXML, options);
+        WebAppDocument webAppDoc = (WebAppDocument) xmlObject.changeType(WebAppDocument.type);
+        WebAppType webApp = webAppDoc.getWebApp();
+        AnnotatedWebApp annotatedWebApp = new AnnotatedWebApp(webApp);
+        WebServiceRefAnnotationHelper.processAnnotations(annotatedWebApp, classFinder);
+        URL expectedXML = classLoader.getResource("annotation/webservice-ref-expected.xml");
+        XmlObject expected = XmlObject.Factory.parse(expectedXML);
+        log.debug("[@WebServiceRef Source XML] " + '\n' + webApp.toString() + '\n');
+        log.debug("[@WebServiceRef Expected XML]" + '\n' + expected.toString() + '\n');
+        List problems = new ArrayList();
+        boolean ok = compareXmlObjects(webApp, expected, problems);
+        assertTrue("Differences: " + problems, ok);
+    }
+}

Propchange: geronimo/server/trunk/modules/geronimo-j2ee-builder/src/test/java/org/apache/geronimo/j2ee/deployment/annotation/AnnotationHelperTest.java
------------------------------------------------------------------------------
    svn:eol-style = native

Propchange: geronimo/server/trunk/modules/geronimo-j2ee-builder/src/test/java/org/apache/geronimo/j2ee/deployment/annotation/AnnotationHelperTest.java
------------------------------------------------------------------------------
    svn:keywords = Date Revision

Propchange: geronimo/server/trunk/modules/geronimo-j2ee-builder/src/test/java/org/apache/geronimo/j2ee/deployment/annotation/AnnotationHelperTest.java
------------------------------------------------------------------------------
    svn:mime-type = text/plain

Added: geronimo/server/trunk/modules/geronimo-j2ee-builder/src/test/java/org/apache/geronimo/j2ee/deployment/annotation/EJBAnnotationTest.java
URL: http://svn.apache.org/viewvc/geronimo/server/trunk/modules/geronimo-j2ee-builder/src/test/java/org/apache/geronimo/j2ee/deployment/annotation/EJBAnnotationTest.java?view=auto&rev=525609
==============================================================================
--- geronimo/server/trunk/modules/geronimo-j2ee-builder/src/test/java/org/apache/geronimo/j2ee/deployment/annotation/EJBAnnotationTest.java (added)
+++ geronimo/server/trunk/modules/geronimo-j2ee-builder/src/test/java/org/apache/geronimo/j2ee/deployment/annotation/EJBAnnotationTest.java Wed Apr  4 14:20:03 2007
@@ -0,0 +1,93 @@
+/**
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+
+package org.apache.geronimo.j2ee.deployment.annotation;
+
+import javax.ejb.EJB;
+import javax.ejb.EJBs;
+
+@EJBs ({
+           @EJB(name = "EJB1",
+                description = "description1",
+                beanInterface = javax.ejb.EJBHome.class,
+                beanName = "beanName1",
+                mappedName = "mappedName1"),
+           @EJB(name = "EJB2",
+                description = "description2",
+                beanInterface = javax.ejb.EJBLocalHome.class,
+                beanName = "beanName2",
+                mappedName = "mappedName2"),
+           @EJB(name = "EJB3",
+                description = "description3",
+                beanInterface = java.lang.Object.class,
+                beanName = "beanName3",
+                mappedName = "mappedName3"),
+           @EJB(name = "EJB4",
+                description = "description4",
+                beanInterface = javax.ejb.EJBLocalHome.class,
+                beanName = "beanName4",
+                mappedName = "mappedName4"),
+           @EJB(name = "EJB5",
+                description = "description5",
+                beanInterface = javax.ejb.EJBHome.class,
+                beanName = "beanName5",
+                mappedName = "mappedName5"),
+           @EJB(name = "EJB6",
+                description = "description6",
+                beanInterface = javax.ejb.EJBLocalHome.class,
+                beanName = "beanName6",
+                mappedName = "mappedName6"),
+           @EJB(name = "EJB7",
+                description = "description7",
+                beanInterface = java.lang.Object.class,
+                beanName = "beanName7",
+                mappedName = "mappedName7")
+       })
+public class EJBAnnotationTest {
+
+    @EJB
+    String annotatedField1;
+
+    @EJB(name = "EJB9",
+         description = "description9",
+         beanName = "beanName9",
+         mappedName = "mappedName9")
+    String annotatedField2;
+
+    //------------------------------------------------------------------------------------------
+    // Method name (for setter-based injection) must follow JavaBeans conventions:
+    // -- Must start with "set"
+    // -- Have one parameter
+    // -- Return void
+    //------------------------------------------------------------------------------------------
+    @EJB(name = "EJB10",
+         description = "description10",
+        beanInterface = javax.ejb.EJBLocalHome.class,
+         mappedName = "mappedName10")
+    public void setAnnotatedMethod1(int ii) {
+    }
+
+    @EJB(name = "EJB11",
+         description = "description11",
+         beanName = "beanName11",
+         mappedName = "mappedName11")
+    public void setAnnotatedMethod2(String string) {
+    }
+}
+

Propchange: geronimo/server/trunk/modules/geronimo-j2ee-builder/src/test/java/org/apache/geronimo/j2ee/deployment/annotation/EJBAnnotationTest.java
------------------------------------------------------------------------------
    svn:eol-style = native

Propchange: geronimo/server/trunk/modules/geronimo-j2ee-builder/src/test/java/org/apache/geronimo/j2ee/deployment/annotation/EJBAnnotationTest.java
------------------------------------------------------------------------------
    svn:keywords = Date Revision

Propchange: geronimo/server/trunk/modules/geronimo-j2ee-builder/src/test/java/org/apache/geronimo/j2ee/deployment/annotation/EJBAnnotationTest.java
------------------------------------------------------------------------------
    svn:mime-type = text/plain

Added: geronimo/server/trunk/modules/geronimo-j2ee-builder/src/test/java/org/apache/geronimo/j2ee/deployment/annotation/HandlerChainAnnotationTest.java
URL: http://svn.apache.org/viewvc/geronimo/server/trunk/modules/geronimo-j2ee-builder/src/test/java/org/apache/geronimo/j2ee/deployment/annotation/HandlerChainAnnotationTest.java?view=auto&rev=525609
==============================================================================
--- geronimo/server/trunk/modules/geronimo-j2ee-builder/src/test/java/org/apache/geronimo/j2ee/deployment/annotation/HandlerChainAnnotationTest.java (added)
+++ geronimo/server/trunk/modules/geronimo-j2ee-builder/src/test/java/org/apache/geronimo/j2ee/deployment/annotation/HandlerChainAnnotationTest.java Wed Apr  4 14:20:03 2007
@@ -0,0 +1,64 @@
+/**
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+
+package org.apache.geronimo.j2ee.deployment.annotation;
+
+import javax.jws.HandlerChain;
+import javax.xml.ws.WebServiceRef;
+
+@HandlerChain(file = "annotation/handlers1.xml")            // Ignored by Geronimo at the class-level
+public class HandlerChainAnnotationTest {
+
+    @WebServiceRef(name = "WebServiceRef1",
+                   value = javax.xml.ws.Service.class,
+                   wsdlLocation = "WEB-INF/wsdl/WebServiceRef1.wsdl",
+                   mappedName = "mappedName")
+    @HandlerChain(file = "annotation/handlers2.xml")
+    int annotatedField1;
+
+    @WebServiceRef(name = "WebServiceRef2",
+                   value = javax.xml.ws.Service.class,
+                   wsdlLocation = "WEB-INF/wsdl/WebServiceRef2.wsdl",
+                   mappedName = "mappedName")
+    @HandlerChain(file = "annotation/handlers3.xml")
+    boolean annotatedField2;
+
+    //------------------------------------------------------------------------------------------
+    // Method name (for setter-based injection) must follow JavaBeans conventions:
+    // -- Must start with "set"
+    // -- Have one parameter
+    // -- Return void
+    //------------------------------------------------------------------------------------------
+    @WebServiceRef(name = "WebServiceRef3",
+                   value = javax.xml.ws.Service.class,
+                   wsdlLocation = "WEB-INF/wsdl/WebServiceRef3.wsdl",
+                   mappedName = "mappedName")
+    @HandlerChain(file = "annotation/handlers4.xml")
+    public void setAnnotatedMethod1(String string) {
+    }
+
+    @WebServiceRef(name = "WebServiceRef4",
+                   value = javax.xml.ws.Service.class,
+                   wsdlLocation = "WEB-INF/wsdl/WebServiceRef4.wsdl",
+                   mappedName = "mappedName")
+    @HandlerChain(file = "annotation/handlers5.xml")
+    public void setAnnotatedMethod2(int ii) {
+    }
+
+}

Propchange: geronimo/server/trunk/modules/geronimo-j2ee-builder/src/test/java/org/apache/geronimo/j2ee/deployment/annotation/HandlerChainAnnotationTest.java
------------------------------------------------------------------------------
    svn:eol-style = native

Propchange: geronimo/server/trunk/modules/geronimo-j2ee-builder/src/test/java/org/apache/geronimo/j2ee/deployment/annotation/HandlerChainAnnotationTest.java
------------------------------------------------------------------------------
    svn:keywords = Date Revision

Propchange: geronimo/server/trunk/modules/geronimo-j2ee-builder/src/test/java/org/apache/geronimo/j2ee/deployment/annotation/HandlerChainAnnotationTest.java
------------------------------------------------------------------------------
    svn:mime-type = text/plain

Added: geronimo/server/trunk/modules/geronimo-j2ee-builder/src/test/java/org/apache/geronimo/j2ee/deployment/annotation/PersistenceContextAnnotationTest.java
URL: http://svn.apache.org/viewvc/geronimo/server/trunk/modules/geronimo-j2ee-builder/src/test/java/org/apache/geronimo/j2ee/deployment/annotation/PersistenceContextAnnotationTest.java?view=auto&rev=525609
==============================================================================
--- geronimo/server/trunk/modules/geronimo-j2ee-builder/src/test/java/org/apache/geronimo/j2ee/deployment/annotation/PersistenceContextAnnotationTest.java (added)
+++ geronimo/server/trunk/modules/geronimo-j2ee-builder/src/test/java/org/apache/geronimo/j2ee/deployment/annotation/PersistenceContextAnnotationTest.java Wed Apr  4 14:20:03 2007
@@ -0,0 +1,70 @@
+/**
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+
+package org.apache.geronimo.j2ee.deployment.annotation;
+
+import javax.persistence.PersistenceContext;
+import javax.persistence.PersistenceContexts;
+import javax.persistence.PersistenceContextType;
+import javax.persistence.PersistenceProperty;
+
+@PersistenceContexts ({
+                          @PersistenceContext(name = "PersistenceContext1",
+                                              properties={@PersistenceProperty(name="property1", value="value1"),
+                                                  @PersistenceProperty(name="property2", value="value2")},
+                                              type = PersistenceContextType.TRANSACTION),
+                          @PersistenceContext(name = "PersistenceContext2",
+                                              unitName = "unitName2",
+                                              properties={@PersistenceProperty(name="property3", value="value3"),
+                                                  @PersistenceProperty(name="property4", value="value4")},
+                                              type = PersistenceContextType.EXTENDED)
+                      })
+public class PersistenceContextAnnotationTest {
+
+    @PersistenceContext(name = "PersistenceContext3",
+                        properties={@PersistenceProperty(name="property5", value="value5"),
+                            @PersistenceProperty(name="property6", value="value6")},
+                        type = PersistenceContextType.TRANSACTION)
+    String annotatedField1;
+
+    @PersistenceContext(name = "PersistenceContext3",
+                        unitName = "unitName4",
+                        type = PersistenceContextType.EXTENDED)
+    String annotatedField2;
+
+    //------------------------------------------------------------------------------------------
+    // Method name (for setter-based injection) must follow JavaBeans conventions:
+    // -- Must start with "set"
+    // -- Have one parameter
+    // -- Return void
+    //------------------------------------------------------------------------------------------
+    @PersistenceContext(name = "PersistenceContext4",
+                        unitName = "unitName5",
+                        properties={@PersistenceProperty(name="property9", value="value9"),
+                            @PersistenceProperty(name="property10", value="value10")},
+                        type = PersistenceContextType.TRANSACTION)
+    public void setAnnotatedMethod1(String string) {
+    }
+
+    @PersistenceContext
+    public void setAnnotatedMethod2(String string) {
+    }
+
+}
+

Propchange: geronimo/server/trunk/modules/geronimo-j2ee-builder/src/test/java/org/apache/geronimo/j2ee/deployment/annotation/PersistenceContextAnnotationTest.java
------------------------------------------------------------------------------
    svn:eol-style = native

Propchange: geronimo/server/trunk/modules/geronimo-j2ee-builder/src/test/java/org/apache/geronimo/j2ee/deployment/annotation/PersistenceContextAnnotationTest.java
------------------------------------------------------------------------------
    svn:keywords = Date Revision

Propchange: geronimo/server/trunk/modules/geronimo-j2ee-builder/src/test/java/org/apache/geronimo/j2ee/deployment/annotation/PersistenceContextAnnotationTest.java
------------------------------------------------------------------------------
    svn:mime-type = text/plain

Added: geronimo/server/trunk/modules/geronimo-j2ee-builder/src/test/java/org/apache/geronimo/j2ee/deployment/annotation/PersistenceUnitAnnotationTest.java
URL: http://svn.apache.org/viewvc/geronimo/server/trunk/modules/geronimo-j2ee-builder/src/test/java/org/apache/geronimo/j2ee/deployment/annotation/PersistenceUnitAnnotationTest.java?view=auto&rev=525609
==============================================================================
--- geronimo/server/trunk/modules/geronimo-j2ee-builder/src/test/java/org/apache/geronimo/j2ee/deployment/annotation/PersistenceUnitAnnotationTest.java (added)
+++ geronimo/server/trunk/modules/geronimo-j2ee-builder/src/test/java/org/apache/geronimo/j2ee/deployment/annotation/PersistenceUnitAnnotationTest.java Wed Apr  4 14:20:03 2007
@@ -0,0 +1,58 @@
+/**
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+
+package org.apache.geronimo.j2ee.deployment.annotation;
+
+import javax.persistence.PersistenceUnit;
+import javax.persistence.PersistenceUnits;
+
+@PersistenceUnits ({
+                       @PersistenceUnit(name = "PersistenceUnit1",
+                                        unitName = "unitName1"),
+                       @PersistenceUnit(name = "PersistenceUnit2",
+                                        unitName = "unitName2"),
+                       @PersistenceUnit( unitName = "unitName3"),
+                       @PersistenceUnit(name = "PersistenceUnit4")
+                   })
+public class PersistenceUnitAnnotationTest {
+
+    @PersistenceUnit(name = "PersistenceUnit5",
+                     unitName = "unitName5")
+    long annotatedField1;
+
+    @PersistenceUnit
+    String annotatedField2;
+
+    //------------------------------------------------------------------------------------------
+    // Method name (for setter-based injection) must follow JavaBeans conventions:
+    // -- Must start with "set"
+    // -- Have one parameter
+    // -- Return void
+    //------------------------------------------------------------------------------------------
+    @PersistenceUnit(name = "PersistenceUnit7",
+                     unitName = "unitName7")
+    public void setAnnotatedMethod1(int ii) {
+    }
+
+    @PersistenceUnit(name = "PersistenceUnit8",
+                     unitName = "unitName8")
+    public void setAnnotatedMethod2(boolean bool) {
+    }
+
+}

Propchange: geronimo/server/trunk/modules/geronimo-j2ee-builder/src/test/java/org/apache/geronimo/j2ee/deployment/annotation/PersistenceUnitAnnotationTest.java
------------------------------------------------------------------------------
    svn:eol-style = native

Propchange: geronimo/server/trunk/modules/geronimo-j2ee-builder/src/test/java/org/apache/geronimo/j2ee/deployment/annotation/PersistenceUnitAnnotationTest.java
------------------------------------------------------------------------------
    svn:keywords = Date Revision

Propchange: geronimo/server/trunk/modules/geronimo-j2ee-builder/src/test/java/org/apache/geronimo/j2ee/deployment/annotation/PersistenceUnitAnnotationTest.java
------------------------------------------------------------------------------
    svn:mime-type = text/plain

Added: geronimo/server/trunk/modules/geronimo-j2ee-builder/src/test/java/org/apache/geronimo/j2ee/deployment/annotation/WebServiceRefAnnotationTest.java
URL: http://svn.apache.org/viewvc/geronimo/server/trunk/modules/geronimo-j2ee-builder/src/test/java/org/apache/geronimo/j2ee/deployment/annotation/WebServiceRefAnnotationTest.java?view=auto&rev=525609
==============================================================================
--- geronimo/server/trunk/modules/geronimo-j2ee-builder/src/test/java/org/apache/geronimo/j2ee/deployment/annotation/WebServiceRefAnnotationTest.java (added)
+++ geronimo/server/trunk/modules/geronimo-j2ee-builder/src/test/java/org/apache/geronimo/j2ee/deployment/annotation/WebServiceRefAnnotationTest.java Wed Apr  4 14:20:03 2007
@@ -0,0 +1,67 @@
+/**
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+
+package org.apache.geronimo.j2ee.deployment.annotation;
+
+import javax.xml.ws.WebServiceRef;
+import javax.xml.ws.WebServiceRefs;
+
+@WebServiceRefs ({
+                     @WebServiceRef(name = "WebServiceRef10",
+                                    type = javax.xml.ws.Service.class,
+                                    value = javax.xml.ws.Service.class,
+                                    wsdlLocation = "WEB-INF/wsdl/WebServiceRef10.wsdl"),
+                     @WebServiceRef(name = "WebServiceRef11",
+                                    type = javax.xml.ws.Service.class,
+                                    value = javax.xml.ws.Service.class,
+                                    wsdlLocation = "WEB-INF/wsdl/WebServiceRef11.wsdl",
+                                    mappedName = "mappedName11")
+                 })
+public class WebServiceRefAnnotationTest {
+
+    @WebServiceRef(name = "WebServiceRef12",
+                   type = javax.xml.ws.Service.class,
+                   value = javax.xml.ws.Service.class,
+                   mappedName = "mappedName12")
+    String annotatedField1;
+
+    @WebServiceRef
+    int annotatedField2;
+
+    //------------------------------------------------------------------------------------------
+    // Method name (for setter-based injection) must follow JavaBeans conventions:
+    // -- Must start with "set"
+    // -- Have one parameter
+    // -- Return void
+    //------------------------------------------------------------------------------------------
+    @WebServiceRef(name = "WebServiceRef14",
+                   value = java.lang.Object.class,
+                   wsdlLocation = "WEB-INF/wsdl/WebServiceRef14.wsdl",
+                   mappedName = "mappedName14")
+    public void setAnnotatedMethod1(boolean bool) {
+    }
+
+    @WebServiceRef(name = "WebServiceRef15",
+                   value = javax.xml.ws.Service.class,
+                   wsdlLocation = "WEB-INF/wsdl/WebServiceRef15.wsdl",
+                   mappedName = "mappedName15")
+    public void setAnnotatedMethod2(String string) {
+    }
+
+}

Propchange: geronimo/server/trunk/modules/geronimo-j2ee-builder/src/test/java/org/apache/geronimo/j2ee/deployment/annotation/WebServiceRefAnnotationTest.java
------------------------------------------------------------------------------
    svn:eol-style = native

Propchange: geronimo/server/trunk/modules/geronimo-j2ee-builder/src/test/java/org/apache/geronimo/j2ee/deployment/annotation/WebServiceRefAnnotationTest.java
------------------------------------------------------------------------------
    svn:keywords = Date Revision

Propchange: geronimo/server/trunk/modules/geronimo-j2ee-builder/src/test/java/org/apache/geronimo/j2ee/deployment/annotation/WebServiceRefAnnotationTest.java
------------------------------------------------------------------------------
    svn:mime-type = text/plain

Added: geronimo/server/trunk/modules/geronimo-j2ee-builder/src/test/resources/annotation/ejb-expected.xml
URL: http://svn.apache.org/viewvc/geronimo/server/trunk/modules/geronimo-j2ee-builder/src/test/resources/annotation/ejb-expected.xml?view=auto&rev=525609
==============================================================================
--- geronimo/server/trunk/modules/geronimo-j2ee-builder/src/test/resources/annotation/ejb-expected.xml (added)
+++ geronimo/server/trunk/modules/geronimo-j2ee-builder/src/test/resources/annotation/ejb-expected.xml Wed Apr  4 14:20:03 2007
@@ -0,0 +1,72 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+   Licensed to the Apache Software Foundation (ASF) under one or more
+   contributor license agreements.  See the NOTICE file distributed with
+   this work for additional information regarding copyright ownership.
+   The ASF licenses this file to You under the Apache License, Version 2.0
+   (the "License"); you may not use this file except in compliance with
+   the License.  You may obtain a copy of the License at
+
+      http://www.apache.org/licenses/LICENSE-2.0
+
+   Unless required by applicable law or agreed to in writing, software
+   distributed under the License is distributed on an "AS IS" BASIS,
+   WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+   See the License for the specific language governing permissions and
+   limitations under the License.
+-->
+
+<web-app xmlns="http://java.sun.com/xml/ns/javaee"
+   xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
+   xsi:schemaLocation="http://java.sun.com/xml/ns/javaee http://java.sun.com/xml/ns/javaee/web-app_2_5.xsd"
+   version="2.5" >
+
+    <display-name>Empty web application</display-name>
+    <description>Empty web application</description>
+    <ejb-ref>
+        <description>description1</description>
+        <ejb-ref-name>EJB1</ejb-ref-name>
+        <remote>javax.ejb.EJBHome</remote>
+        <ejb-link>beanName1</ejb-link>
+        <mapped-name>mappedName1</mapped-name>
+    </ejb-ref>
+    <ejb-local-ref>
+        <description>description2</description>
+        <ejb-ref-name>EJB2</ejb-ref-name>
+        <local>javax.ejb.EJBLocalHome</local>
+        <ejb-link>beanName2</ejb-link>
+        <mapped-name>mappedName2</mapped-name>
+    </ejb-local-ref>
+    <ejb-local-ref>
+        <description>description4</description>
+        <ejb-ref-name>EJB4</ejb-ref-name>
+        <local>javax.ejb.EJBLocalHome</local>
+        <ejb-link>beanName4</ejb-link>
+        <mapped-name>mappedName4</mapped-name>
+    </ejb-local-ref>
+    <ejb-ref>
+        <description>description5</description>
+        <ejb-ref-name>EJB5</ejb-ref-name>
+        <remote>javax.ejb.EJBHome</remote>
+        <ejb-link>beanName5</ejb-link>
+        <mapped-name>mappedName5</mapped-name>
+    </ejb-ref>
+    <ejb-local-ref>
+        <description>description6</description>
+        <ejb-ref-name>EJB6</ejb-ref-name>
+        <local>javax.ejb.EJBLocalHome</local>
+        <ejb-link>beanName6</ejb-link>
+        <mapped-name>mappedName6</mapped-name>
+    </ejb-local-ref>
+    <ejb-local-ref>
+        <description>description10</description>
+        <ejb-ref-name>EJB10</ejb-ref-name>
+        <local>javax.ejb.EJBLocalHome</local>
+        <mapped-name>mappedName10</mapped-name>
+        <injection-target>
+            <injection-target-class>org.apache.geronimo.j2ee.deployment.annotation.EJBAnnotationTest</injection-target-class>
+            <injection-target-name>AnnotatedMethod1</injection-target-name>
+        </injection-target>
+    </ejb-local-ref>
+
+</web-app>

Propchange: geronimo/server/trunk/modules/geronimo-j2ee-builder/src/test/resources/annotation/ejb-expected.xml
------------------------------------------------------------------------------
    svn:eol-style = native

Propchange: geronimo/server/trunk/modules/geronimo-j2ee-builder/src/test/resources/annotation/ejb-expected.xml
------------------------------------------------------------------------------
    svn:keywords = Date Revision

Propchange: geronimo/server/trunk/modules/geronimo-j2ee-builder/src/test/resources/annotation/ejb-expected.xml
------------------------------------------------------------------------------
    svn:mime-type = text/xml

Added: geronimo/server/trunk/modules/geronimo-j2ee-builder/src/test/resources/annotation/empty-web-src.xml
URL: http://svn.apache.org/viewvc/geronimo/server/trunk/modules/geronimo-j2ee-builder/src/test/resources/annotation/empty-web-src.xml?view=auto&rev=525609
==============================================================================
--- geronimo/server/trunk/modules/geronimo-j2ee-builder/src/test/resources/annotation/empty-web-src.xml (added)
+++ geronimo/server/trunk/modules/geronimo-j2ee-builder/src/test/resources/annotation/empty-web-src.xml Wed Apr  4 14:20:03 2007
@@ -0,0 +1,27 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+   Licensed to the Apache Software Foundation (ASF) under one or more
+   contributor license agreements.  See the NOTICE file distributed with
+   this work for additional information regarding copyright ownership.
+   The ASF licenses this file to You under the Apache License, Version 2.0
+   (the "License"); you may not use this file except in compliance with
+   the License.  You may obtain a copy of the License at
+
+      http://www.apache.org/licenses/LICENSE-2.0
+
+   Unless required by applicable law or agreed to in writing, software
+   distributed under the License is distributed on an "AS IS" BASIS,
+   WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+   See the License for the specific language governing permissions and
+   limitations under the License.
+-->
+
+<web-app xmlns="http://java.sun.com/xml/ns/javaee"
+   xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
+   xsi:schemaLocation="http://java.sun.com/xml/ns/javaee http://java.sun.com/xml/ns/javaee/web-app_2_5.xsd"
+   version="2.5" >
+
+    <display-name>Empty web application</display-name>
+    <description>Empty web application</description>
+
+</web-app>

Propchange: geronimo/server/trunk/modules/geronimo-j2ee-builder/src/test/resources/annotation/empty-web-src.xml
------------------------------------------------------------------------------
    svn:eol-style = native

Propchange: geronimo/server/trunk/modules/geronimo-j2ee-builder/src/test/resources/annotation/empty-web-src.xml
------------------------------------------------------------------------------
    svn:keywords = Date Revision

Propchange: geronimo/server/trunk/modules/geronimo-j2ee-builder/src/test/resources/annotation/empty-web-src.xml
------------------------------------------------------------------------------
    svn:mime-type = text/xml

Added: geronimo/server/trunk/modules/geronimo-j2ee-builder/src/test/resources/annotation/handler-chain-expected.xml
URL: http://svn.apache.org/viewvc/geronimo/server/trunk/modules/geronimo-j2ee-builder/src/test/resources/annotation/handler-chain-expected.xml?view=auto&rev=525609
==============================================================================
--- geronimo/server/trunk/modules/geronimo-j2ee-builder/src/test/resources/annotation/handler-chain-expected.xml (added)
+++ geronimo/server/trunk/modules/geronimo-j2ee-builder/src/test/resources/annotation/handler-chain-expected.xml Wed Apr  4 14:20:03 2007
@@ -0,0 +1,105 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+   Licensed to the Apache Software Foundation (ASF) under one or more
+   contributor license agreements.  See the NOTICE file distributed with
+   this work for additional information regarding copyright ownership.
+   The ASF licenses this file to You under the Apache License, Version 2.0
+   (the "License"); you may not use this file except in compliance with
+   the License.  You may obtain a copy of the License at
+
+      http://www.apache.org/licenses/LICENSE-2.0
+
+   Unless required by applicable law or agreed to in writing, software
+   distributed under the License is distributed on an "AS IS" BASIS,
+   WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+   See the License for the specific language governing permissions and
+   limitations under the License.
+-->
+
+<web-app xmlns="http://java.sun.com/xml/ns/javaee"
+   xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
+   xsi:schemaLocation="http://java.sun.com/xml/ns/javaee http://java.sun.com/xml/ns/javaee/web-app_2_5.xsd"
+   version="2.5" >
+
+    <display-name>HandlerChain web application</display-name>
+    <description>HandlerChain web application</description>
+    <service-ref>
+        <service-ref-name>WebServiceRef1</service-ref-name>
+        <service-interface>javax.xml.ws.Service</service-interface>
+        <service-ref-type>javax.xml.ws.Service</service-ref-type>
+        <wsdl-file>WEB-INF/wsdl/WebServiceRef1.wsdl</wsdl-file>
+        <handler-chains>
+            <handler-chain>
+                <handler>
+                    <handler-name>WebService5</handler-name>
+                    <handler-class>org.apache.handler.WebServiceHandler5</handler-class>
+                </handler>
+            </handler-chain>
+        </handler-chains>
+    </service-ref>
+    <service-ref>
+        <service-ref-name>WebServiceRef2</service-ref-name>
+        <service-interface>javax.xml.ws.Service</service-interface>
+        <service-ref-type>javax.xml.ws.Service</service-ref-type>
+        <wsdl-file>WEB-INF/wsdl/WebServiceRef1.wsdl</wsdl-file>
+        <handler-chains>
+            <handler-chain>
+                <handler>
+                    <handler-name>WebService4</handler-name>
+                    <handler-class>org.apache.handler.WebServiceHandler4</handler-class>
+                </handler>
+            </handler-chain>
+        </handler-chains>
+        <mapped-name>mappedName2</mapped-name>
+    </service-ref>
+    <service-ref>
+        <service-ref-name>WebServiceRef5</service-ref-name>
+        <service-interface>boolean</service-interface>
+        <service-ref-type>boolean</service-ref-type>
+        <wsdl-file>WEB-INF/wsdl/WebServiceRef5.wsdl</wsdl-file>
+        <mapped-name>mappedName5</mapped-name>
+        <injection-target>
+            <injection-target-class>org.apache.geronimo.j2ee.deployment.annotation.WebServiceRefAnnotationTest</injection-target-class>
+            <injection-target-name>annotatedMethod1</injection-target-name>
+        </injection-target>
+    </service-ref>
+    <service-ref>
+        <service-ref-name>WebServiceRef6</service-ref-name>
+        <service-interface>javax.xml.ws.Service</service-interface>
+        <service-ref-type>java.lang.String</service-ref-type>
+        <wsdl-file>WEB-INF/wsdl/WebServiceRef6.wsdl</wsdl-file>
+        <mapped-name>mappedName6</mapped-name>
+        <injection-target>
+            <injection-target-class>org.apache.geronimo.j2ee.deployment.annotation.WebServiceRefAnnotationTest</injection-target-class>
+            <injection-target-name>annotatedMethod2</injection-target-name>
+        </injection-target>
+    </service-ref>
+    <service-ref>
+        <service-ref-name>WebServiceRef3</service-ref-name>
+        <service-interface>javax.xml.ws.Service</service-interface>
+        <service-ref-type>javax.xml.ws.Service</service-ref-type>
+        <handler-chains>
+            <handler-chain>
+                <handler>
+                    <handler-name>WebService3</handler-name>
+                    <handler-class>org.apache.handler.WebServiceHandler3</handler-class>
+                </handler>
+            </handler-chain>
+        </handler-chains>
+        <mapped-name>mappedName3</mapped-name>
+        <injection-target>
+            <injection-target-class>org.apache.geronimo.j2ee.deployment.annotation.WebServiceRefAnnotationTest</injection-target-class>
+            <injection-target-name>annotatedField1</injection-target-name>
+        </injection-target>
+    </service-ref>
+    <service-ref>
+        <service-ref-name>org.apache.geronimo.j2ee.deployment.annotation.WebServiceRefAnnotationTest/annotatedField2</service-ref-name>
+        <service-interface>int</service-interface>
+        <service-ref-type>int</service-ref-type>
+        <injection-target>
+            <injection-target-class>org.apache.geronimo.j2ee.deployment.annotation.WebServiceRefAnnotationTest</injection-target-class>
+            <injection-target-name>annotatedField2</injection-target-name>
+        </injection-target>
+    </service-ref>
+
+</web-app>

Propchange: geronimo/server/trunk/modules/geronimo-j2ee-builder/src/test/resources/annotation/handler-chain-expected.xml
------------------------------------------------------------------------------
    svn:eol-style = native

Propchange: geronimo/server/trunk/modules/geronimo-j2ee-builder/src/test/resources/annotation/handler-chain-expected.xml
------------------------------------------------------------------------------
    svn:keywords = Date Revision

Propchange: geronimo/server/trunk/modules/geronimo-j2ee-builder/src/test/resources/annotation/handler-chain-expected.xml
------------------------------------------------------------------------------
    svn:mime-type = text/xml

Added: geronimo/server/trunk/modules/geronimo-j2ee-builder/src/test/resources/annotation/handler-chain-src.xml
URL: http://svn.apache.org/viewvc/geronimo/server/trunk/modules/geronimo-j2ee-builder/src/test/resources/annotation/handler-chain-src.xml?view=auto&rev=525609
==============================================================================
--- geronimo/server/trunk/modules/geronimo-j2ee-builder/src/test/resources/annotation/handler-chain-src.xml (added)
+++ geronimo/server/trunk/modules/geronimo-j2ee-builder/src/test/resources/annotation/handler-chain-src.xml Wed Apr  4 14:20:03 2007
@@ -0,0 +1,81 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+   Licensed to the Apache Software Foundation (ASF) under one or more
+   contributor license agreements.  See the NOTICE file distributed with
+   this work for additional information regarding copyright ownership.
+   The ASF licenses this file to You under the Apache License, Version 2.0
+   (the "License"); you may not use this file except in compliance with
+   the License.  You may obtain a copy of the License at
+
+      http://www.apache.org/licenses/LICENSE-2.0
+
+   Unless required by applicable law or agreed to in writing, software
+   distributed under the License is distributed on an "AS IS" BASIS,
+   WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+   See the License for the specific language governing permissions and
+   limitations under the License.
+-->
+
+<web-app xmlns="http://java.sun.com/xml/ns/javaee"
+   xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
+   xsi:schemaLocation="http://java.sun.com/xml/ns/javaee http://java.sun.com/xml/ns/javaee/web-app_2_5.xsd"
+   version="2.5" >
+
+    <display-name>HandlerChain web application</display-name>
+    <description>HandlerChain web application</description>
+    <service-ref>
+        <service-ref-name>WebServiceRef1</service-ref-name>
+        <service-interface>javax.xml.ws.Service</service-interface>
+        <service-ref-type>javax.xml.ws.Service</service-ref-type>
+        <wsdl-file>WEB-INF/wsdl/WebServiceRef1.wsdl</wsdl-file>
+    </service-ref>
+    <service-ref>
+        <service-ref-name>WebServiceRef2</service-ref-name>
+        <service-interface>javax.xml.ws.Service</service-interface>
+        <service-ref-type>javax.xml.ws.Service</service-ref-type>
+        <wsdl-file>WEB-INF/wsdl/WebServiceRef1.wsdl</wsdl-file>
+        <mapped-name>mappedName2</mapped-name>
+    </service-ref>
+    <service-ref>
+        <service-ref-name>WebServiceRef5</service-ref-name>
+        <service-interface>boolean</service-interface>
+        <service-ref-type>boolean</service-ref-type>
+        <wsdl-file>WEB-INF/wsdl/WebServiceRef5.wsdl</wsdl-file>
+        <mapped-name>mappedName5</mapped-name>
+        <injection-target>
+            <injection-target-class>org.apache.geronimo.j2ee.deployment.annotation.WebServiceRefAnnotationTest</injection-target-class>
+            <injection-target-name>annotatedMethod1</injection-target-name>
+        </injection-target>
+    </service-ref>
+    <service-ref>
+        <service-ref-name>WebServiceRef6</service-ref-name>
+        <service-interface>javax.xml.ws.Service</service-interface>
+        <service-ref-type>java.lang.String</service-ref-type>
+        <wsdl-file>WEB-INF/wsdl/WebServiceRef6.wsdl</wsdl-file>
+        <mapped-name>mappedName6</mapped-name>
+        <injection-target>
+            <injection-target-class>org.apache.geronimo.j2ee.deployment.annotation.WebServiceRefAnnotationTest</injection-target-class>
+            <injection-target-name>annotatedMethod2</injection-target-name>
+        </injection-target>
+    </service-ref>
+    <service-ref>
+        <service-ref-name>WebServiceRef3</service-ref-name>
+        <service-interface>javax.xml.ws.Service</service-interface>
+        <service-ref-type>javax.xml.ws.Service</service-ref-type>
+        <mapped-name>mappedName3</mapped-name>
+        <injection-target>
+            <injection-target-class>org.apache.geronimo.j2ee.deployment.annotation.WebServiceRefAnnotationTest</injection-target-class>
+            <injection-target-name>annotatedField1</injection-target-name>
+        </injection-target>
+    </service-ref>
+    <service-ref>
+        <service-ref-name>org.apache.geronimo.j2ee.deployment.annotation.WebServiceRefAnnotationTest/annotatedField2</service-ref-name>
+        <service-interface>int</service-interface>
+        <service-ref-type>int</service-ref-type>
+        <injection-target>
+            <injection-target-class>org.apache.geronimo.j2ee.deployment.annotation.WebServiceRefAnnotationTest</injection-target-class>
+            <injection-target-name>annotatedField2</injection-target-name>
+        </injection-target>
+    </service-ref>
+
+</web-app>

Propchange: geronimo/server/trunk/modules/geronimo-j2ee-builder/src/test/resources/annotation/handler-chain-src.xml
------------------------------------------------------------------------------
    svn:eol-style = native

Propchange: geronimo/server/trunk/modules/geronimo-j2ee-builder/src/test/resources/annotation/handler-chain-src.xml
------------------------------------------------------------------------------
    svn:keywords = Date Revision

Propchange: geronimo/server/trunk/modules/geronimo-j2ee-builder/src/test/resources/annotation/handler-chain-src.xml
------------------------------------------------------------------------------
    svn:mime-type = text/xml

Added: geronimo/server/trunk/modules/geronimo-j2ee-builder/src/test/resources/annotation/handlers1.xml
URL: http://svn.apache.org/viewvc/geronimo/server/trunk/modules/geronimo-j2ee-builder/src/test/resources/annotation/handlers1.xml?view=auto&rev=525609
==============================================================================
--- geronimo/server/trunk/modules/geronimo-j2ee-builder/src/test/resources/annotation/handlers1.xml (added)
+++ geronimo/server/trunk/modules/geronimo-j2ee-builder/src/test/resources/annotation/handlers1.xml Wed Apr  4 14:20:03 2007
@@ -0,0 +1,9 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<jws:handler-chains xmlns:jws="http://java.sun.com/xml/ns/javaee">
+  <jws:handler-chain>
+    <jws:handler>
+      <jws:handler-name>WebService1</jws:handler-name>
+      <jws:handler-class>org.apache.handler.WebServiceHandler1</jws:handler-class>
+    </jws:handler>
+  </jws:handler-chain>
+</jws:handler-chains>

Propchange: geronimo/server/trunk/modules/geronimo-j2ee-builder/src/test/resources/annotation/handlers1.xml
------------------------------------------------------------------------------
    svn:eol-style = native

Propchange: geronimo/server/trunk/modules/geronimo-j2ee-builder/src/test/resources/annotation/handlers1.xml
------------------------------------------------------------------------------
    svn:keywords = Date Revision

Propchange: geronimo/server/trunk/modules/geronimo-j2ee-builder/src/test/resources/annotation/handlers1.xml
------------------------------------------------------------------------------
    svn:mime-type = text/xml

Added: geronimo/server/trunk/modules/geronimo-j2ee-builder/src/test/resources/annotation/handlers2.xml
URL: http://svn.apache.org/viewvc/geronimo/server/trunk/modules/geronimo-j2ee-builder/src/test/resources/annotation/handlers2.xml?view=auto&rev=525609
==============================================================================
--- geronimo/server/trunk/modules/geronimo-j2ee-builder/src/test/resources/annotation/handlers2.xml (added)
+++ geronimo/server/trunk/modules/geronimo-j2ee-builder/src/test/resources/annotation/handlers2.xml Wed Apr  4 14:20:03 2007
@@ -0,0 +1,9 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<jws:handler-chains xmlns:jws="http://java.sun.com/xml/ns/javaee">
+  <jws:handler-chain>
+    <jws:handler>
+      <jws:handler-name>WebService5</jws:handler-name>
+      <jws:handler-class>org.apache.handler.WebServiceHandler5</jws:handler-class>
+    </jws:handler>
+  </jws:handler-chain>
+</jws:handler-chains>

Propchange: geronimo/server/trunk/modules/geronimo-j2ee-builder/src/test/resources/annotation/handlers2.xml
------------------------------------------------------------------------------
    svn:eol-style = native

Propchange: geronimo/server/trunk/modules/geronimo-j2ee-builder/src/test/resources/annotation/handlers2.xml
------------------------------------------------------------------------------
    svn:keywords = Date Revision

Propchange: geronimo/server/trunk/modules/geronimo-j2ee-builder/src/test/resources/annotation/handlers2.xml
------------------------------------------------------------------------------
    svn:mime-type = text/xml

Added: geronimo/server/trunk/modules/geronimo-j2ee-builder/src/test/resources/annotation/handlers3.xml
URL: http://svn.apache.org/viewvc/geronimo/server/trunk/modules/geronimo-j2ee-builder/src/test/resources/annotation/handlers3.xml?view=auto&rev=525609
==============================================================================
--- geronimo/server/trunk/modules/geronimo-j2ee-builder/src/test/resources/annotation/handlers3.xml (added)
+++ geronimo/server/trunk/modules/geronimo-j2ee-builder/src/test/resources/annotation/handlers3.xml Wed Apr  4 14:20:03 2007
@@ -0,0 +1,9 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<jws:handler-chains xmlns:jws="http://java.sun.com/xml/ns/javaee">
+  <jws:handler-chain>
+    <jws:handler>
+      <jws:handler-name>WebService4</jws:handler-name>
+      <jws:handler-class>org.apache.handler.WebServiceHandler4</jws:handler-class>
+    </jws:handler>
+  </jws:handler-chain>
+</jws:handler-chains>

Propchange: geronimo/server/trunk/modules/geronimo-j2ee-builder/src/test/resources/annotation/handlers3.xml
------------------------------------------------------------------------------
    svn:eol-style = native

Propchange: geronimo/server/trunk/modules/geronimo-j2ee-builder/src/test/resources/annotation/handlers3.xml
------------------------------------------------------------------------------
    svn:keywords = Date Revision

Propchange: geronimo/server/trunk/modules/geronimo-j2ee-builder/src/test/resources/annotation/handlers3.xml
------------------------------------------------------------------------------
    svn:mime-type = text/xml

Added: geronimo/server/trunk/modules/geronimo-j2ee-builder/src/test/resources/annotation/handlers4.xml
URL: http://svn.apache.org/viewvc/geronimo/server/trunk/modules/geronimo-j2ee-builder/src/test/resources/annotation/handlers4.xml?view=auto&rev=525609
==============================================================================
--- geronimo/server/trunk/modules/geronimo-j2ee-builder/src/test/resources/annotation/handlers4.xml (added)
+++ geronimo/server/trunk/modules/geronimo-j2ee-builder/src/test/resources/annotation/handlers4.xml Wed Apr  4 14:20:03 2007
@@ -0,0 +1,9 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<jws:handler-chains xmlns:jws="http://java.sun.com/xml/ns/javaee">
+  <jws:handler-chain>
+    <jws:handler>
+      <jws:handler-name>WebService3</jws:handler-name>
+      <jws:handler-class>org.apache.handler.WebServiceHandler3</jws:handler-class>
+    </jws:handler>
+  </jws:handler-chain>
+</jws:handler-chains>

Propchange: geronimo/server/trunk/modules/geronimo-j2ee-builder/src/test/resources/annotation/handlers4.xml
------------------------------------------------------------------------------
    svn:eol-style = native

Propchange: geronimo/server/trunk/modules/geronimo-j2ee-builder/src/test/resources/annotation/handlers4.xml
------------------------------------------------------------------------------
    svn:keywords = Date Revision

Propchange: geronimo/server/trunk/modules/geronimo-j2ee-builder/src/test/resources/annotation/handlers4.xml
------------------------------------------------------------------------------
    svn:mime-type = text/xml

Added: geronimo/server/trunk/modules/geronimo-j2ee-builder/src/test/resources/annotation/handlers5.xml
URL: http://svn.apache.org/viewvc/geronimo/server/trunk/modules/geronimo-j2ee-builder/src/test/resources/annotation/handlers5.xml?view=auto&rev=525609
==============================================================================
--- geronimo/server/trunk/modules/geronimo-j2ee-builder/src/test/resources/annotation/handlers5.xml (added)
+++ geronimo/server/trunk/modules/geronimo-j2ee-builder/src/test/resources/annotation/handlers5.xml Wed Apr  4 14:20:03 2007
@@ -0,0 +1,9 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<jws:handler-chains xmlns:jws="http://java.sun.com/xml/ns/javaee">
+  <jws:handler-chain>
+    <jws:handler>
+      <jws:handler-name>WebService2</jws:handler-name>
+      <jws:handler-class>org.apache.handler.WebServiceHandler2</jws:handler-class>
+    </jws:handler>
+  </jws:handler-chain>
+</jws:handler-chains>

Propchange: geronimo/server/trunk/modules/geronimo-j2ee-builder/src/test/resources/annotation/handlers5.xml
------------------------------------------------------------------------------
    svn:eol-style = native

Propchange: geronimo/server/trunk/modules/geronimo-j2ee-builder/src/test/resources/annotation/handlers5.xml
------------------------------------------------------------------------------
    svn:keywords = Date Revision

Propchange: geronimo/server/trunk/modules/geronimo-j2ee-builder/src/test/resources/annotation/handlers5.xml
------------------------------------------------------------------------------
    svn:mime-type = text/xml

Added: geronimo/server/trunk/modules/geronimo-j2ee-builder/src/test/resources/annotation/persistence-context-expected.xml
URL: http://svn.apache.org/viewvc/geronimo/server/trunk/modules/geronimo-j2ee-builder/src/test/resources/annotation/persistence-context-expected.xml?view=auto&rev=525609
==============================================================================
--- geronimo/server/trunk/modules/geronimo-j2ee-builder/src/test/resources/annotation/persistence-context-expected.xml (added)
+++ geronimo/server/trunk/modules/geronimo-j2ee-builder/src/test/resources/annotation/persistence-context-expected.xml Wed Apr  4 14:20:03 2007
@@ -0,0 +1,97 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+   Licensed to the Apache Software Foundation (ASF) under one or more
+   contributor license agreements.  See the NOTICE file distributed with
+   this work for additional information regarding copyright ownership.
+   The ASF licenses this file to You under the Apache License, Version 2.0
+   (the "License"); you may not use this file except in compliance with
+   the License.  You may obtain a copy of the License at
+
+      http://www.apache.org/licenses/LICENSE-2.0
+
+   Unless required by applicable law or agreed to in writing, software
+   distributed under the License is distributed on an "AS IS" BASIS,
+   WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+   See the License for the specific language governing permissions and
+   limitations under the License.
+-->
+
+<web-app xmlns="http://java.sun.com/xml/ns/javaee"
+   xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
+   xsi:schemaLocation="http://java.sun.com/xml/ns/javaee http://java.sun.com/xml/ns/javaee/web-app_2_5.xsd"
+   version="2.5" >
+
+    <display-name>Empty web application</display-name>
+    <description>Empty web application</description>
+    <persistence-context-ref>
+        <persistence-context-ref-name>PersistenceContext1</persistence-context-ref-name>
+        <persistence-context-type>Transaction</persistence-context-type>
+        <persistence-property>
+            <name>property1</name>
+            <value>value1</value>
+        </persistence-property>
+        <persistence-property>
+            <name>property2</name>
+            <value>value2</value>
+        </persistence-property>
+    </persistence-context-ref>
+    <persistence-context-ref>
+        <persistence-context-ref-name>PersistenceContext2</persistence-context-ref-name>
+        <persistence-unit-name>unitName2</persistence-unit-name>
+        <persistence-context-type>Extended</persistence-context-type>
+        <persistence-property>
+            <name>property3</name>
+            <value>value3</value>
+        </persistence-property>
+        <persistence-property>
+            <name>property4</name>
+            <value>value4</value>
+        </persistence-property>
+    </persistence-context-ref>
+    <persistence-context-ref>
+        <persistence-context-ref-name>PersistenceContext4</persistence-context-ref-name>
+        <persistence-unit-name>unitName5</persistence-unit-name>
+        <persistence-context-type>Transaction</persistence-context-type>
+        <persistence-property>
+            <name>property9</name>
+            <value>value9</value>
+        </persistence-property>
+        <persistence-property>
+            <name>property10</name>
+            <value>value10</value>
+        </persistence-property>
+        <injection-target>
+            <injection-target-class>org.apache.geronimo.j2ee.deployment.annotation.PersistenceContextAnnotationTest</injection-target-class>
+            <injection-target-name>annotatedMethod1</injection-target-name>
+        </injection-target>
+    </persistence-context-ref>
+    <persistence-context-ref>
+        <persistence-context-ref-name>org.apache.geronimo.j2ee.deployment.annotation.PersistenceContextAnnotationTest/annotatedMethod2</persistence-context-ref-name>
+        <persistence-context-type>Transaction</persistence-context-type>
+        <injection-target>
+            <injection-target-class>org.apache.geronimo.j2ee.deployment.annotation.PersistenceContextAnnotationTest</injection-target-class>
+            <injection-target-name>annotatedMethod2</injection-target-name>
+        </injection-target>
+    </persistence-context-ref>
+    <persistence-context-ref>
+        <persistence-context-ref-name>PersistenceContext3</persistence-context-ref-name>
+        <persistence-context-type>Transaction</persistence-context-type>
+        <persistence-property>
+            <name>property5</name>
+            <value>value5</value>
+        </persistence-property>
+        <persistence-property>
+            <name>property6</name>
+            <value>value6</value>
+        </persistence-property>
+        <injection-target>
+            <injection-target-class>org.apache.geronimo.j2ee.deployment.annotation.PersistenceContextAnnotationTest</injection-target-class>
+            <injection-target-name>annotatedField1</injection-target-name>
+        </injection-target>
+        <injection-target>
+            <injection-target-class>org.apache.geronimo.j2ee.deployment.annotation.PersistenceContextAnnotationTest</injection-target-class>
+            <injection-target-name>annotatedField2</injection-target-name>
+        </injection-target>
+    </persistence-context-ref>
+
+</web-app>

Propchange: geronimo/server/trunk/modules/geronimo-j2ee-builder/src/test/resources/annotation/persistence-context-expected.xml
------------------------------------------------------------------------------
    svn:eol-style = native

Propchange: geronimo/server/trunk/modules/geronimo-j2ee-builder/src/test/resources/annotation/persistence-context-expected.xml
------------------------------------------------------------------------------
    svn:keywords = Date Revision

Propchange: geronimo/server/trunk/modules/geronimo-j2ee-builder/src/test/resources/annotation/persistence-context-expected.xml
------------------------------------------------------------------------------
    svn:mime-type = text/xml

Added: geronimo/server/trunk/modules/geronimo-j2ee-builder/src/test/resources/annotation/persistence-unit-expected.xml
URL: http://svn.apache.org/viewvc/geronimo/server/trunk/modules/geronimo-j2ee-builder/src/test/resources/annotation/persistence-unit-expected.xml?view=auto&rev=525609
==============================================================================
--- geronimo/server/trunk/modules/geronimo-j2ee-builder/src/test/resources/annotation/persistence-unit-expected.xml (added)
+++ geronimo/server/trunk/modules/geronimo-j2ee-builder/src/test/resources/annotation/persistence-unit-expected.xml Wed Apr  4 14:20:03 2007
@@ -0,0 +1,73 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+   Licensed to the Apache Software Foundation (ASF) under one or more
+   contributor license agreements.  See the NOTICE file distributed with
+   this work for additional information regarding copyright ownership.
+   The ASF licenses this file to You under the Apache License, Version 2.0
+   (the "License"); you may not use this file except in compliance with
+   the License.  You may obtain a copy of the License at
+
+      http://www.apache.org/licenses/LICENSE-2.0
+
+   Unless required by applicable law or agreed to in writing, software
+   distributed under the License is distributed on an "AS IS" BASIS,
+   WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+   See the License for the specific language governing permissions and
+   limitations under the License.
+-->
+
+<web-app xmlns="http://java.sun.com/xml/ns/javaee"
+   xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
+   xsi:schemaLocation="http://java.sun.com/xml/ns/javaee http://java.sun.com/xml/ns/javaee/web-app_2_5.xsd"
+   version="2.5" >
+
+    <display-name>Empty web application</display-name>
+    <description>Empty web application</description>
+    <persistence-unit-ref>
+        <persistence-unit-ref-name>PersistenceUnit1</persistence-unit-ref-name>
+        <persistence-unit-name>unitName1</persistence-unit-name>
+    </persistence-unit-ref>
+    <persistence-unit-ref>
+        <persistence-unit-ref-name>PersistenceUnit2</persistence-unit-ref-name>
+        <persistence-unit-name>unitName2</persistence-unit-name>
+    </persistence-unit-ref>
+    <persistence-unit-ref>
+        <persistence-unit-ref-name/>
+        <persistence-unit-name>unitName3</persistence-unit-name>
+    </persistence-unit-ref>
+    <persistence-unit-ref>
+        <persistence-unit-ref-name>PersistenceUnit4</persistence-unit-ref-name>
+    </persistence-unit-ref>
+    <persistence-unit-ref>
+        <persistence-unit-ref-name>PersistenceUnit7</persistence-unit-ref-name>
+        <persistence-unit-name>unitName7</persistence-unit-name>
+        <injection-target>
+            <injection-target-class>org.apache.geronimo.j2ee.deployment.annotation.PersistenceUnitAnnotationTest</injection-target-class>
+            <injection-target-name>annotatedMethod1</injection-target-name>
+        </injection-target>
+    </persistence-unit-ref>
+    <persistence-unit-ref>
+        <persistence-unit-ref-name>PersistenceUnit8</persistence-unit-ref-name>
+        <persistence-unit-name>unitName8</persistence-unit-name>
+        <injection-target>
+            <injection-target-class>org.apache.geronimo.j2ee.deployment.annotation.PersistenceUnitAnnotationTest</injection-target-class>
+            <injection-target-name>annotatedMethod2</injection-target-name>
+        </injection-target>
+    </persistence-unit-ref>
+    <persistence-unit-ref>
+        <persistence-unit-ref-name>PersistenceUnit5</persistence-unit-ref-name>
+        <persistence-unit-name>unitName5</persistence-unit-name>
+        <injection-target>
+            <injection-target-class>org.apache.geronimo.j2ee.deployment.annotation.PersistenceUnitAnnotationTest</injection-target-class>
+            <injection-target-name>annotatedField1</injection-target-name>
+        </injection-target>
+    </persistence-unit-ref>
+    <persistence-unit-ref>
+        <persistence-unit-ref-name>org.apache.geronimo.j2ee.deployment.annotation.PersistenceUnitAnnotationTest/annotatedField2</persistence-unit-ref-name>
+        <injection-target>
+            <injection-target-class>org.apache.geronimo.j2ee.deployment.annotation.PersistenceUnitAnnotationTest</injection-target-class>
+            <injection-target-name>annotatedField2</injection-target-name>
+        </injection-target>
+    </persistence-unit-ref>
+
+</web-app>

Propchange: geronimo/server/trunk/modules/geronimo-j2ee-builder/src/test/resources/annotation/persistence-unit-expected.xml
------------------------------------------------------------------------------
    svn:eol-style = native

Propchange: geronimo/server/trunk/modules/geronimo-j2ee-builder/src/test/resources/annotation/persistence-unit-expected.xml
------------------------------------------------------------------------------
    svn:keywords = Date Revision

Propchange: geronimo/server/trunk/modules/geronimo-j2ee-builder/src/test/resources/annotation/persistence-unit-expected.xml
------------------------------------------------------------------------------
    svn:mime-type = text/xml

Added: geronimo/server/trunk/modules/geronimo-j2ee-builder/src/test/resources/annotation/webservice-ref-expected.xml
URL: http://svn.apache.org/viewvc/geronimo/server/trunk/modules/geronimo-j2ee-builder/src/test/resources/annotation/webservice-ref-expected.xml?view=auto&rev=525609
==============================================================================
--- geronimo/server/trunk/modules/geronimo-j2ee-builder/src/test/resources/annotation/webservice-ref-expected.xml (added)
+++ geronimo/server/trunk/modules/geronimo-j2ee-builder/src/test/resources/annotation/webservice-ref-expected.xml Wed Apr  4 14:20:03 2007
@@ -0,0 +1,125 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+   Licensed to the Apache Software Foundation (ASF) under one or more
+   contributor license agreements.  See the NOTICE file distributed with
+   this work for additional information regarding copyright ownership.
+   The ASF licenses this file to You under the Apache License, Version 2.0
+   (the "License"); you may not use this file except in compliance with
+   the License.  You may obtain a copy of the License at
+
+      http://www.apache.org/licenses/LICENSE-2.0
+
+   Unless required by applicable law or agreed to in writing, software
+   distributed under the License is distributed on an "AS IS" BASIS,
+   WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+   See the License for the specific language governing permissions and
+   limitations under the License.
+-->
+
+<web-app xmlns="http://java.sun.com/xml/ns/javaee"
+   xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
+   xsi:schemaLocation="http://java.sun.com/xml/ns/javaee http://java.sun.com/xml/ns/javaee/web-app_2_5.xsd"
+   version="2.5" >
+
+    <display-name>Empty web application</display-name>
+    <description>Empty web application</description>
+    <service-ref>
+        <service-ref-name>WebServiceRef10</service-ref-name>
+        <service-interface>javax.xml.ws.Service</service-interface>
+        <service-ref-type>javax.xml.ws.Service</service-ref-type>
+        <wsdl-file>WEB-INF/wsdl/WebServiceRef10.wsdl</wsdl-file>
+    </service-ref>
+    <service-ref>
+        <service-ref-name>WebServiceRef11</service-ref-name>
+        <service-interface>javax.xml.ws.Service</service-interface>
+        <service-ref-type>javax.xml.ws.Service</service-ref-type>
+        <wsdl-file>WEB-INF/wsdl/WebServiceRef11.wsdl</wsdl-file>
+        <mapped-name>mappedName11</mapped-name>
+    </service-ref>
+    <service-ref>
+        <service-ref-name>WebServiceRef3</service-ref-name>
+        <service-interface>javax.xml.ws.Service</service-interface>
+        <service-ref-type>java.lang.String</service-ref-type>
+        <wsdl-file>WEB-INF/wsdl/WebServiceRef3.wsdl</wsdl-file>
+        <mapped-name>mappedName</mapped-name>
+        <injection-target>
+            <injection-target-class>org.apache.geronimo.j2ee.deployment.annotation.HandlerChainAnnotationTest</injection-target-class>
+            <injection-target-name>annotatedMethod1</injection-target-name>
+        </injection-target>
+    </service-ref>
+    <service-ref>
+        <service-ref-name>WebServiceRef4</service-ref-name>
+        <service-interface>javax.xml.ws.Service</service-interface>
+        <service-ref-type>int</service-ref-type>
+        <wsdl-file>WEB-INF/wsdl/WebServiceRef4.wsdl</wsdl-file>
+        <mapped-name>mappedName</mapped-name>
+        <injection-target>
+            <injection-target-class>org.apache.geronimo.j2ee.deployment.annotation.HandlerChainAnnotationTest</injection-target-class>
+            <injection-target-name>annotatedMethod2</injection-target-name>
+        </injection-target>
+    </service-ref>
+    <service-ref>
+        <service-ref-name>WebServiceRef14</service-ref-name>
+        <service-interface>boolean</service-interface>
+        <service-ref-type>boolean</service-ref-type>
+        <wsdl-file>WEB-INF/wsdl/WebServiceRef14.wsdl</wsdl-file>
+        <mapped-name>mappedName14</mapped-name>
+        <injection-target>
+            <injection-target-class>org.apache.geronimo.j2ee.deployment.annotation.WebServiceRefAnnotationTest</injection-target-class>
+            <injection-target-name>annotatedMethod1</injection-target-name>
+        </injection-target>
+    </service-ref>
+    <service-ref>
+        <service-ref-name>WebServiceRef15</service-ref-name>
+        <service-interface>javax.xml.ws.Service</service-interface>
+        <service-ref-type>java.lang.String</service-ref-type>
+        <wsdl-file>WEB-INF/wsdl/WebServiceRef15.wsdl</wsdl-file>
+        <mapped-name>mappedName15</mapped-name>
+        <injection-target>
+            <injection-target-class>org.apache.geronimo.j2ee.deployment.annotation.WebServiceRefAnnotationTest</injection-target-class>
+            <injection-target-name>annotatedMethod2</injection-target-name>
+        </injection-target>
+    </service-ref>
+    <service-ref>
+        <service-ref-name>WebServiceRef1</service-ref-name>
+        <service-interface>javax.xml.ws.Service</service-interface>
+        <service-ref-type>int</service-ref-type>
+        <wsdl-file>WEB-INF/wsdl/WebServiceRef1.wsdl</wsdl-file>
+        <mapped-name>mappedName</mapped-name>
+        <injection-target>
+            <injection-target-class>org.apache.geronimo.j2ee.deployment.annotation.HandlerChainAnnotationTest</injection-target-class>
+            <injection-target-name>annotatedField1</injection-target-name>
+        </injection-target>
+    </service-ref>
+    <service-ref>
+        <service-ref-name>WebServiceRef2</service-ref-name>
+        <service-interface>javax.xml.ws.Service</service-interface>
+        <service-ref-type>boolean</service-ref-type>
+        <wsdl-file>WEB-INF/wsdl/WebServiceRef2.wsdl</wsdl-file>
+        <mapped-name>mappedName</mapped-name>
+        <injection-target>
+            <injection-target-class>org.apache.geronimo.j2ee.deployment.annotation.HandlerChainAnnotationTest</injection-target-class>
+            <injection-target-name>annotatedField2</injection-target-name>
+        </injection-target>
+    </service-ref>
+    <service-ref>
+        <service-ref-name>WebServiceRef12</service-ref-name>
+        <service-interface>javax.xml.ws.Service</service-interface>
+        <service-ref-type>javax.xml.ws.Service</service-ref-type>
+        <mapped-name>mappedName12</mapped-name>
+        <injection-target>
+            <injection-target-class>org.apache.geronimo.j2ee.deployment.annotation.WebServiceRefAnnotationTest</injection-target-class>
+            <injection-target-name>annotatedField1</injection-target-name>
+        </injection-target>
+    </service-ref>
+    <service-ref>
+        <service-ref-name>org.apache.geronimo.j2ee.deployment.annotation.WebServiceRefAnnotationTest/annotatedField2</service-ref-name>
+        <service-interface>int</service-interface>
+        <service-ref-type>int</service-ref-type>
+        <injection-target>
+            <injection-target-class>org.apache.geronimo.j2ee.deployment.annotation.WebServiceRefAnnotationTest</injection-target-class>
+            <injection-target-name>annotatedField2</injection-target-name>
+        </injection-target>
+    </service-ref>
+
+</web-app>

Propchange: geronimo/server/trunk/modules/geronimo-j2ee-builder/src/test/resources/annotation/webservice-ref-expected.xml
------------------------------------------------------------------------------
    svn:eol-style = native

Propchange: geronimo/server/trunk/modules/geronimo-j2ee-builder/src/test/resources/annotation/webservice-ref-expected.xml
------------------------------------------------------------------------------
    svn:keywords = Date Revision

Propchange: geronimo/server/trunk/modules/geronimo-j2ee-builder/src/test/resources/annotation/webservice-ref-expected.xml
------------------------------------------------------------------------------
    svn:mime-type = text/xml

Modified: geronimo/server/trunk/modules/geronimo-naming-builder/src/main/java/org/apache/geronimo/naming/deployment/EnvironmentEntryBuilder.java
URL: http://svn.apache.org/viewvc/geronimo/server/trunk/modules/geronimo-naming-builder/src/main/java/org/apache/geronimo/naming/deployment/EnvironmentEntryBuilder.java?view=diff&rev=525609&r1=525608&r2=525609
==============================================================================
--- geronimo/server/trunk/modules/geronimo-naming-builder/src/main/java/org/apache/geronimo/naming/deployment/EnvironmentEntryBuilder.java (original)
+++ geronimo/server/trunk/modules/geronimo-naming-builder/src/main/java/org/apache/geronimo/naming/deployment/EnvironmentEntryBuilder.java Wed Apr  4 14:20:03 2007
@@ -128,7 +128,7 @@
         return QNameSet.EMPTY;
     }
 
-    static class EnvEntryRefProcessor extends ResourceAnnotationHelper.ResourceProcessor {
+    public static class EnvEntryRefProcessor extends ResourceAnnotationHelper.ResourceProcessor {
 
         public static final EnvEntryRefProcessor INSTANCE = new EnvEntryRefProcessor();
 
@@ -185,8 +185,12 @@
                         }
 
                         // env-entry-value
-                        XsdStringType value = envEntry.addNewEnvEntryValue();
-                        value.setStringValue(annotation.mappedName());
+                        String mappdedNameAnnotation = annotation.mappedName();
+                        if (!mappdedNameAnnotation.equals("")) {
+                            XsdStringType value = envEntry.addNewEnvEntryValue();
+                            value.setStringValue(mappdedNameAnnotation);
+                            envEntry.setMappedName(value);
+                        }
 
                         //------------------------------------------------------------------------------
                         // <env-entry> optional elements:



Mime
View raw message