[seam-commits] Seam SVN: r15129 - in branches/community/Seam_2_3: jboss-seam-gen/dist and 4 other directories.

seam-commits at lists.jboss.org seam-commits at lists.jboss.org
Wed Sep 12 11:51:41 EDT 2012


Author: manaRH
Date: 2012-09-12 11:51:40 -0400 (Wed, 12 Sep 2012)
New Revision: 15129

Removed:
   branches/community/Seam_2_3/jboss-seam-gen/dist/resources/META-INF/jboss-app.xml
   branches/community/Seam_2_3/jboss-seam-gen/dist/resources/WEB-INF/jboss-web.xml
Modified:
   branches/community/Seam_2_3/distribution/get-arquillian-libs.xml
   branches/community/Seam_2_3/jboss-seam-gen/dist/build.xml
   branches/community/Seam_2_3/jboss-seam-gen/dist/ide-project-files/eclipse/.classpath
   branches/community/Seam_2_3/jboss-seam-gen/dist/test/ActionTest.java
   branches/community/Seam_2_3/jboss-seam-gen/dist/test/Deployments.java
   branches/community/Seam_2_3/jboss-seam-gen/dist/test/FormTest.java
Log:
JBSEAM-5034

Modified: branches/community/Seam_2_3/distribution/get-arquillian-libs.xml
===================================================================
--- branches/community/Seam_2_3/distribution/get-arquillian-libs.xml	2012-09-12 15:51:25 UTC (rev 15128)
+++ branches/community/Seam_2_3/distribution/get-arquillian-libs.xml	2012-09-12 15:51:40 UTC (rev 15129)
@@ -14,6 +14,7 @@
 		    <aether:dependencies>
 		        <aether:dependency groupid="org.jboss.as" artifactid="jboss-as-arquillian-container-remote" version="${version.jboss-as7}" />
 		    	<aether:dependency groupid="org.jboss.arquillian.junit" artifactid="arquillian-junit-container" version="${version.arquillian-junit}" />
+		    	<aether:dependency groupid="org.jboss.arquillian.protocol" artifactid="arquillian-protocol-servlet" version="${version.arquillian-junit}" />
 		    </aether:dependencies>
 		    <files dir="${test.lib.dir}"  layout="{artifactId}-{version}-{classifier}.{extension}" />
 		</aether:resolve>

Modified: branches/community/Seam_2_3/jboss-seam-gen/dist/build.xml
===================================================================
--- branches/community/Seam_2_3/jboss-seam-gen/dist/build.xml	2012-09-12 15:51:25 UTC (rev 15128)
+++ branches/community/Seam_2_3/jboss-seam-gen/dist/build.xml	2012-09-12 15:51:40 UTC (rev 15129)
@@ -951,10 +951,10 @@
         <replace file="${project.home}/resources/META-INF/persistence-dev.xml">
             <replacefilter token="&lt;jta-data-source&gt;java:/" value="&lt;jta-data-source&gt;"/>
         </replace>
-
+    	<!-- JBoss AS 7 doesn't require this
         <replace dir="${project.home}/resources">
             <include name="WEB-INF/web.xml" if="project.war"/>
-            <replacetoken><![CDATA[</web-app>]]></replacetoken>
+           <replacetoken><![CDATA[</web-app>]]></replacetoken>
             <replacevalue><![CDATA[   <persistence-unit-ref>
       <persistence-unit-ref-name>@projectName@/pu</persistence-unit-ref-name>
       <persistence-unit-name>@projectName@</persistence-unit-name>
@@ -962,7 +962,7 @@
 
 </web-app>]]></replacevalue>
 
-        </replace>
+        </replace>-->
 
         <replace dir="${project.home}/resources">
             <include name="WEB-INF/web.xml" if="project.ear"/>
@@ -977,18 +977,18 @@
    </ejb-local-ref>
    -->
 
-   <!-- Add entries for each EJB session bean which is also a Seam component (not required on JBoss AS) -->
+   <!-- Add entries for each EJB session bean which is also a Seam component (not required on JBoss AS) --> 
 
-   <persistence-unit-ref>
+   <!-- <persistence-unit-ref>
       <persistence-unit-ref-name>@projectName@/pu</persistence-unit-ref-name>
-      <persistence-unit-name>../@projectName at .jar#@projectName@</persistence-unit-name>
+      <persistence-unit-name>../@projectName at .jar#@projectName@</persistence-unit-name> -->
       <!-- The relative reference doesn't work on GlassFish. Instead, set the <persistence-unit-name> to "@projectName@",
            package persistence.xml in the WAR, and add a <jar-file> element in persistence.xml with value "../../@projectName at .jar".
       <persistence-unit-name>@projectName@</persistence-unit-name>
       -->
-   </persistence-unit-ref>
+   <!--</persistence-unit-ref>
 
-</web-app>]]></replacevalue>
+</web-app>-->]]></replacevalue>
 
         </replace>
 

Modified: branches/community/Seam_2_3/jboss-seam-gen/dist/ide-project-files/eclipse/.classpath
===================================================================
--- branches/community/Seam_2_3/jboss-seam-gen/dist/ide-project-files/eclipse/.classpath	2012-09-12 15:51:25 UTC (rev 15128)
+++ branches/community/Seam_2_3/jboss-seam-gen/dist/ide-project-files/eclipse/.classpath	2012-09-12 15:51:40 UTC (rev 15129)
@@ -177,19 +177,13 @@
     <classpathentry kind="lib" path="lib/test/aether-impl-1.8.jar"/>
     <classpathentry kind="lib" path="lib/test/aether-spi-1.8.jar"/>
     <classpathentry kind="lib" path="lib/test/aether-util-1.8.jar"/>
-<classpathentry kind="lib" path="lib/test/arquillian-config-api-1.0.0.CR7.jar"/>
 <classpathentry kind="lib" path="lib/test/arquillian-config-api-1.0.1.Final.jar"/>
-<classpathentry kind="lib" path="lib/test/arquillian-config-impl-base-1.0.0.CR7.jar"/>
 <classpathentry kind="lib" path="lib/test/arquillian-config-impl-base-1.0.1.Final.jar"/>
 <classpathentry kind="lib" path="lib/test/arquillian-container-impl-base-1.0.1.Final.jar"/>
 <classpathentry kind="lib" path="lib/test/arquillian-container-osgi-1.0.2.Final.jar"/>
-<classpathentry kind="lib" path="lib/test/arquillian-container-spi-1.0.0.CR7.jar"/>
 <classpathentry kind="lib" path="lib/test/arquillian-container-spi-1.0.1.Final.jar"/>
-<classpathentry kind="lib" path="lib/test/arquillian-container-test-api-1.0.0.CR7.jar"/>
 <classpathentry kind="lib" path="lib/test/arquillian-container-test-api-1.0.1.Final.jar"/>
-<classpathentry kind="lib" path="lib/test/arquillian-container-test-impl-base-1.0.0.CR7.jar"/>
 <classpathentry kind="lib" path="lib/test/arquillian-container-test-impl-base-1.0.1.Final.jar"/>
-<classpathentry kind="lib" path="lib/test/arquillian-container-test-spi-1.0.0.CR7.jar"/>
 <classpathentry kind="lib" path="lib/test/arquillian-container-test-spi-1.0.1.Final.jar"/>
 <classpathentry kind="lib" path="lib/test/arquillian-core-api-1.0.0.CR7.jar"/>
 <classpathentry kind="lib" path="lib/test/arquillian-core-impl-base-1.0.1.Final.jar"/>
@@ -197,7 +191,7 @@
 <classpathentry kind="lib" path="lib/test/arquillian-junit-container-1.0.1.Final.jar"/>
 <classpathentry kind="lib" path="lib/test/arquillian-junit-core-1.0.1.Final.jar"/>
 <classpathentry kind="lib" path="lib/test/arquillian-protocol-jmx-1.0.0.CR7.jar"/>
-<classpathentry kind="lib" path="lib/test/arquillian-test-api-1.0.0.CR7.jar"/>
+<classpathentry kind="lib" path="lib/test/arquillian-protocol-servlet-1.0.1.Final.jar"/>
 <classpathentry kind="lib" path="lib/test/arquillian-test-api-1.0.1.Final.jar"/>
 <classpathentry kind="lib" path="lib/test/arquillian-testenricher-cdi-1.0.0.CR7.jar"/>
 <classpathentry kind="lib" path="lib/test/arquillian-testenricher-ejb-1.0.0.CR7.jar"/>
@@ -205,7 +199,6 @@
 <classpathentry kind="lib" path="lib/test/arquillian-testenricher-osgi-1.0.2.Final.jar"/>
 <classpathentry kind="lib" path="lib/test/arquillian-testenricher-resource-1.0.0.CR7.jar"/>
 <classpathentry kind="lib" path="lib/test/arquillian-test-impl-base-1.0.1.Final.jar"/>
-<classpathentry kind="lib" path="lib/test/arquillian-test-spi-1.0.0.CR7.jar"/>
 <classpathentry kind="lib" path="lib/test/arquillian-test-spi-1.0.1.Final.jar"/>    
     <classpathentry kind="lib" path="lib/test/google-collections-1.0.jar"/>
     <classpathentry kind="lib" path="lib/test/hibernate-validator-4.2.0.Final.jar"/>
@@ -257,13 +250,11 @@
     <classpathentry kind="lib" path="lib/test/jboss-logmanager-log4j-1.0.0.GA.jar"/>
     <classpathentry kind="lib" path="lib/test/jboss-logmanager-1.2.2.GA.jar"/>
     <classpathentry kind="lib" path="lib/test/jboss-marshalling-river-1.3.11.GA.jar"/>
-    <classpathentry kind="lib" path="lib/test/jboss-marshalling-1.3.9.GA.jar"/>
     <classpathentry kind="lib" path="lib/test/jboss-metadata-common-7.0.1.Final.jar"/>
     <classpathentry kind="lib" path="lib/test/jboss-metadata-ear-7.0.1.Final.jar"/>
     <classpathentry kind="lib" path="lib/test/jboss-modules-1.1.1.GA.jar"/>
     <classpathentry kind="lib" path="lib/test/jboss-msc-1.0.2.GA.jar"/>
     <classpathentry kind="lib" path="lib/test/jboss-remote-naming-1.0.2.Final.jar"/>
-    <classpathentry kind="lib" path="lib/test/jboss-remoting-3.2.3.GA.jar"/>
     <classpathentry kind="lib" path="lib/test/jboss-sasl-1.0.0.Final.jar"/>
     <classpathentry kind="lib" path="lib/test/jboss-stdio-1.0.1.GA.jar"/>
     <classpathentry kind="lib" path="lib/test/jboss-threads-2.0.0.GA.jar"/>
@@ -291,13 +282,9 @@
     <classpathentry kind="lib" path="lib/test/plexus-utils-2.0.4.jar"/>
     <classpathentry kind="lib" path="lib/test/remoting-jmx-1.0.2.Final.jar"/>
     <classpathentry kind="lib" path="lib/test/shrinkwrap-api-1.0.0-cr-1.jar"/>
-    <classpathentry kind="lib" path="lib/test/shrinkwrap-descriptors-api-1.1.0-beta-1.jar"/>
-    <classpathentry kind="lib" path="lib/test/shrinkwrap-descriptors-spi-1.1.0-beta-1.jar"/>
-    <classpathentry kind="lib" path="lib/test/shrinkwrap-impl-base-1.0.0-cr-1.jar"/>
     <classpathentry kind="lib" path="lib/test/shrinkwrap-resolver-api-maven-1.0.0-beta-5.jar"/>
     <classpathentry kind="lib" path="lib/test/shrinkwrap-resolver-api-1.0.0-beta-5.jar"/>
     <classpathentry kind="lib" path="lib/test/shrinkwrap-resolver-impl-maven-1.0.0-beta-5.jar"/>
-    <classpathentry kind="lib" path="lib/test/shrinkwrap-spi-1.0.0-cr-1.jar"/>
     <classpathentry kind="lib" path="lib/test/slf4j-api-1.6.1.jar"/>
     <classpathentry kind="lib" path="lib/test/staxmapper-1.1.0.Final.jar"/>
     <classpathentry kind="lib" path="lib/test/validation-api-1.0.0.GA.jar"/>
@@ -306,7 +293,6 @@
     <classpathentry kind="lib" path="lib/test/wagon-http-shared-1.0-beta-7.jar"/>
     <classpathentry kind="lib" path="lib/test/wagon-provider-api-1.0-beta-7.jar"/>
     <classpathentry kind="lib" path="lib/test/xbean-reflect-3.4.jar"/>
-    <classpathentry kind="lib" path="lib/test/xnio-api-3.0.0.GA.jar"/>
     <classpathentry kind="lib" path="lib/test/xnio-nio-3.0.3.GA.jar"/>
     <classpathentry kind="lib" path="lib/urlrewritefilter.jar"/>
     <classpathentry kind="lib" path="lib/validation-api.jar"/>

Deleted: branches/community/Seam_2_3/jboss-seam-gen/dist/resources/META-INF/jboss-app.xml
===================================================================
--- branches/community/Seam_2_3/jboss-seam-gen/dist/resources/META-INF/jboss-app.xml	2012-09-12 15:51:25 UTC (rev 15128)
+++ branches/community/Seam_2_3/jboss-seam-gen/dist/resources/META-INF/jboss-app.xml	2012-09-12 15:51:40 UTC (rev 15129)
@@ -1,10 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-  <!DOCTYPE jboss-app
-    PUBLIC "-//JBoss//DTD J2EE Application 4.2//EN"
-    "http://www.jboss.org/j2ee/dtd/jboss-app_4_2.dtd">
-
-<jboss-app>
-   <loader-repository> 
-      seam.jboss.org:loader=@projectName@
-   </loader-repository> 
-</jboss-app> 
\ No newline at end of file

Deleted: branches/community/Seam_2_3/jboss-seam-gen/dist/resources/WEB-INF/jboss-web.xml
===================================================================
--- branches/community/Seam_2_3/jboss-seam-gen/dist/resources/WEB-INF/jboss-web.xml	2012-09-12 15:51:25 UTC (rev 15128)
+++ branches/community/Seam_2_3/jboss-seam-gen/dist/resources/WEB-INF/jboss-web.xml	2012-09-12 15:51:40 UTC (rev 15129)
@@ -1,11 +0,0 @@
-<!DOCTYPE jboss-web PUBLIC
-    "-//JBoss//DTD Web Application 4.2//EN"
-    "http://www.jboss.org/j2ee/dtd/jboss-web_4_2.dtd">
-<jboss-web>  
-    <class-loading java2ClassLoadingCompliance="false">
-        <loader-repository>
-            seam.jboss.org:loader=@projectName@
-            <loader-repository-config>java2ParentDelegation=false</loader-repository-config>
-        </loader-repository>
-    </class-loading>
-</jboss-web>

Modified: branches/community/Seam_2_3/jboss-seam-gen/dist/test/ActionTest.java
===================================================================
--- branches/community/Seam_2_3/jboss-seam-gen/dist/test/ActionTest.java	2012-09-12 15:51:25 UTC (rev 15128)
+++ branches/community/Seam_2_3/jboss-seam-gen/dist/test/ActionTest.java	2012-09-12 15:51:40 UTC (rev 15129)
@@ -6,7 +6,8 @@
 import org.jboss.arquillian.junit.Arquillian;
 import org.jboss.seam.mock.JUnitSeamTest;
 import @testPackage at .Deployments;
-import  @actionPackage at .@interfaceName@;
+import @actionPackage at .@interfaceName@;
+import @actionPackage at .@beanName@;
 import org.jboss.shrinkwrap.api.spec.WebArchive;
 import org.junit.runner.RunWith;
 
@@ -17,10 +18,9 @@
    @OverProtocol("Servlet 3.0") 
    public static WebArchive createDeployment()
    {
-      // use in case jbpm is required in test deployment
-      // return Deployments.jbpmSeamDeployment().addClasses(ProcessComponent.class);
-      return Deployments.defaultWarDeployment()
-            .addClasses(@interfaceName at .class);
+      return Deployments.defaultDeployment()
+            .addClasses(@interfaceName at .class, @beanName at .class)
+            .addAsResource("seam.properties");
    }
    
    

Modified: branches/community/Seam_2_3/jboss-seam-gen/dist/test/Deployments.java
===================================================================
--- branches/community/Seam_2_3/jboss-seam-gen/dist/test/Deployments.java	2012-09-12 15:51:25 UTC (rev 15128)
+++ branches/community/Seam_2_3/jboss-seam-gen/dist/test/Deployments.java	2012-09-12 15:51:40 UTC (rev 15129)
@@ -2,23 +2,32 @@
 
 import java.io.File;
 
-import org.jboss.shrinkwrap.api.ArchivePath;
+import org.jboss.shrinkwrap.api.Filters;
+import org.jboss.shrinkwrap.api.GenericArchive;
 import org.jboss.shrinkwrap.api.ShrinkWrap;
-import org.jboss.shrinkwrap.api.asset.StringAsset;
-import org.jboss.shrinkwrap.api.importer.ZipImporter;
+import org.jboss.shrinkwrap.api.importer.ExplodedImporter;
 import org.jboss.shrinkwrap.api.spec.WebArchive;
 
-package org.jboss.seam.example.booking.test;
-
-import java.io.File;
-
-import org.jboss.shrinkwrap.api.ShrinkWrap;
-import org.jboss.shrinkwrap.api.spec.EnterpriseArchive;
-import org.jboss.shrinkwrap.api.importer.ZipImporter;
-
 public class Deployments {
-   public static EnterpriseArchive bookingDeployment() {
-      return ShrinkWrap.create(ZipImporter.class, "${project.name}.${project.type}").importFrom(new File("${workspace.home/dist/${project.name}.${project.type}"))
-            .as(EnterpriseArchive.class);
+   
+   public static final String WEBAPP_SRC = "@workspaceHome@/@projectName@/test-build";
+   
+   public static WebArchive defaultDeployment() {
+      
+      WebArchive war = ShrinkWrap.create(WebArchive.class, "test.war");
+      war.merge(ShrinkWrap.create(GenericArchive.class).as(ExplodedImporter.class)
+          .importDirectory(WEBAPP_SRC).as(GenericArchive.class),
+          "/", Filters.includeAll());
+      for (File f : new File("@workspaceHome@/@projectName@/lib/").listFiles()) 
+      {
+         if (f.isFile())
+         {
+            war.addAsLibrary(f);
+         }
+      } 
+      
+      return war;
+               
    }
+   
 }
\ No newline at end of file

Modified: branches/community/Seam_2_3/jboss-seam-gen/dist/test/FormTest.java
===================================================================
--- branches/community/Seam_2_3/jboss-seam-gen/dist/test/FormTest.java	2012-09-12 15:51:25 UTC (rev 15128)
+++ branches/community/Seam_2_3/jboss-seam-gen/dist/test/FormTest.java	2012-09-12 15:51:40 UTC (rev 15129)
@@ -7,21 +7,21 @@
 import org.jboss.arquillian.container.test.api.OverProtocol;
 import org.jboss.arquillian.junit.Arquillian;
 import org.jboss.seam.mock.JUnitSeamTest;
-import org.jboss.shrinkwrap.api.Archive;
+import org.jboss.shrinkwrap.api.spec.WebArchive;
 import org.junit.runner.RunWith;
-import  @actionPackage at .@interfaceName@;
+import @actionPackage at .@interfaceName@;
+import @actionPackage at .@beanName@;
 
 @RunWith(Arquillian.class)
 public class @interfaceName at Test extends JUnitSeamTest {
 
    @Deployment(name="@interfaceName at Test")
    @OverProtocol("Servlet 3.0") 
-   public static Archive<?> createDeployment()
+   public static WebArchive createDeployment()
    {
-      // use in case jbpm is required in test deployment
-      // return Deployments.jbpmSeamDeployment().addClasses(ProcessComponent.class);
-      return Deployments.defaultWarDeployment()
-            .addClasses(@interfaceName at .class);
+      return Deployments.defaultDeployment()
+            .addClasses(@interfaceName at .class, @beanName at .class)
+            .addAsResource("seam.properties");
    }
    
 	@Test



More information about the seam-commits mailing list