[seam-commits] Seam SVN: r14579 - in branches/community/Seam_2_3/examples-ee6/dvdstore: dvdstore-ejb/src/main/java/com/jboss/dvd/seam and 2 other directories.

seam-commits at lists.jboss.org seam-commits at lists.jboss.org
Fri Apr 13 12:02:37 EDT 2012


Author: maschmid
Date: 2012-04-13 12:02:36 -0400 (Fri, 13 Apr 2012)
New Revision: 14579

Added:
   branches/community/Seam_2_3/examples-ee6/dvdstore/dvdstore-tests/src/test/resources-integration/web.xml
Modified:
   branches/community/Seam_2_3/examples-ee6/dvdstore/dvdstore-ear/src/main/application/META-INF/jboss-deployment-structure.xml
   branches/community/Seam_2_3/examples-ee6/dvdstore/dvdstore-ejb/src/main/java/com/jboss/dvd/seam/Product.java
   branches/community/Seam_2_3/examples-ee6/dvdstore/dvdstore-tests/src/test/java/com/jboss/dvd/seam/test/BestSellersTest.java
   branches/community/Seam_2_3/examples-ee6/dvdstore/dvdstore-tests/src/test/java/com/jboss/dvd/seam/test/OrderTest.java
   branches/community/Seam_2_3/examples-ee6/dvdstore/dvdstore-tests/src/test/java/com/jboss/dvd/seam/test/ProductUnitTest.java
   branches/community/Seam_2_3/examples-ee6/dvdstore/dvdstore-tests/src/test/java/com/jboss/dvd/seam/test/SearchTest.java
   branches/community/Seam_2_3/examples-ee6/dvdstore/dvdstore-tests/src/test/java/com/jboss/dvd/seam/test/StoreManagerTest.java
Log:
dvdstore testsuite fixes


Modified: branches/community/Seam_2_3/examples-ee6/dvdstore/dvdstore-ear/src/main/application/META-INF/jboss-deployment-structure.xml
===================================================================
--- branches/community/Seam_2_3/examples-ee6/dvdstore/dvdstore-ear/src/main/application/META-INF/jboss-deployment-structure.xml	2012-04-13 15:48:58 UTC (rev 14578)
+++ branches/community/Seam_2_3/examples-ee6/dvdstore/dvdstore-ear/src/main/application/META-INF/jboss-deployment-structure.xml	2012-04-13 16:02:36 UTC (rev 14579)
@@ -2,7 +2,6 @@
   <deployment>
         <dependencies>
           <module name="org.apache.log4j" export="true"/>
-          <module name="org.dom4j" export="true"/>
           <module name="org.apache.commons.logging" export="true"/>
           <module name="org.apache.commons.collections" export="true"/>
           <module name="org.slf4j" export="true"/>

Modified: branches/community/Seam_2_3/examples-ee6/dvdstore/dvdstore-ejb/src/main/java/com/jboss/dvd/seam/Product.java
===================================================================
--- branches/community/Seam_2_3/examples-ee6/dvdstore/dvdstore-ejb/src/main/java/com/jboss/dvd/seam/Product.java	2012-04-13 15:48:58 UTC (rev 14578)
+++ branches/community/Seam_2_3/examples-ee6/dvdstore/dvdstore-ejb/src/main/java/com/jboss/dvd/seam/Product.java	2012-04-13 16:02:36 UTC (rev 14579)
@@ -15,6 +15,7 @@
 import javax.persistence.Entity;
 import javax.persistence.FetchType;
 import javax.persistence.GeneratedValue;
+import javax.persistence.GenerationType;
 import javax.persistence.Id;
 import javax.persistence.JoinColumn;
 import javax.persistence.JoinTable;
@@ -61,7 +62,7 @@
     Set<Category> categories;
     Inventory inventory;
 
-    @Id @GeneratedValue
+    @Id @GeneratedValue(strategy = GenerationType.IDENTITY)
     @Column(name="PROD_ID")
     @DocumentId
     public long getProductId() {

Modified: branches/community/Seam_2_3/examples-ee6/dvdstore/dvdstore-tests/src/test/java/com/jboss/dvd/seam/test/BestSellersTest.java
===================================================================
--- branches/community/Seam_2_3/examples-ee6/dvdstore/dvdstore-tests/src/test/java/com/jboss/dvd/seam/test/BestSellersTest.java	2012-04-13 15:48:58 UTC (rev 14578)
+++ branches/community/Seam_2_3/examples-ee6/dvdstore/dvdstore-tests/src/test/java/com/jboss/dvd/seam/test/BestSellersTest.java	2012-04-13 16:02:36 UTC (rev 14579)
@@ -31,6 +31,10 @@
       EnterpriseArchive er = ShrinkWrap.create(ZipImporter.class, "seam-dvdstore.ear").importFrom(new File("../dvdstore-ear/target/seam-dvdstore.ear")).as(EnterpriseArchive.class);
       WebArchive web = er.getAsType(WebArchive.class, "dvdstore-web.war");
       web.addClasses(BestSellersTest.class);
+      
+   // Install org.jboss.seam.mock.MockSeamListener
+      web.delete("/WEB-INF/web.xml");
+      web.addAsWebInfResource("web.xml");
 
       return er;
    }

Modified: branches/community/Seam_2_3/examples-ee6/dvdstore/dvdstore-tests/src/test/java/com/jboss/dvd/seam/test/OrderTest.java
===================================================================
--- branches/community/Seam_2_3/examples-ee6/dvdstore/dvdstore-tests/src/test/java/com/jboss/dvd/seam/test/OrderTest.java	2012-04-13 15:48:58 UTC (rev 14578)
+++ branches/community/Seam_2_3/examples-ee6/dvdstore/dvdstore-tests/src/test/java/com/jboss/dvd/seam/test/OrderTest.java	2012-04-13 16:02:36 UTC (rev 14579)
@@ -39,6 +39,10 @@
       EnterpriseArchive er = ShrinkWrap.create(ZipImporter.class, "seam-dvdstore.ear").importFrom(new File("../dvdstore-ear/target/seam-dvdstore.ear")).as(EnterpriseArchive.class);
       WebArchive web = er.getAsType(WebArchive.class, "dvdstore-web.war");
       web.addClasses(OrderTest.class);
+      
+      // Install org.jboss.seam.mock.MockSeamListener
+      web.delete("/WEB-INF/web.xml");
+      web.addAsWebInfResource("web.xml");
 
       return er;
    }

Modified: branches/community/Seam_2_3/examples-ee6/dvdstore/dvdstore-tests/src/test/java/com/jboss/dvd/seam/test/ProductUnitTest.java
===================================================================
--- branches/community/Seam_2_3/examples-ee6/dvdstore/dvdstore-tests/src/test/java/com/jboss/dvd/seam/test/ProductUnitTest.java	2012-04-13 15:48:58 UTC (rev 14578)
+++ branches/community/Seam_2_3/examples-ee6/dvdstore/dvdstore-tests/src/test/java/com/jboss/dvd/seam/test/ProductUnitTest.java	2012-04-13 16:02:36 UTC (rev 14579)
@@ -32,6 +32,10 @@
       EnterpriseArchive er = ShrinkWrap.create(ZipImporter.class, "seam-dvdstore.ear").importFrom(new File("../dvdstore-ear/target/seam-dvdstore.ear")).as(EnterpriseArchive.class);
       WebArchive web = er.getAsType(WebArchive.class, "dvdstore-web.war");
       web.addClasses(ProductUnitTest.class);
+      
+      // Install org.jboss.seam.mock.MockSeamListener
+      web.delete("/WEB-INF/web.xml");
+      web.addAsWebInfResource("web.xml");
 
       return er;
    }

Modified: branches/community/Seam_2_3/examples-ee6/dvdstore/dvdstore-tests/src/test/java/com/jboss/dvd/seam/test/SearchTest.java
===================================================================
--- branches/community/Seam_2_3/examples-ee6/dvdstore/dvdstore-tests/src/test/java/com/jboss/dvd/seam/test/SearchTest.java	2012-04-13 15:48:58 UTC (rev 14578)
+++ branches/community/Seam_2_3/examples-ee6/dvdstore/dvdstore-tests/src/test/java/com/jboss/dvd/seam/test/SearchTest.java	2012-04-13 16:02:36 UTC (rev 14579)
@@ -32,6 +32,10 @@
       EnterpriseArchive er = ShrinkWrap.create(ZipImporter.class, "seam-dvdstore.ear").importFrom(new File("../dvdstore-ear/target/seam-dvdstore.ear")).as(EnterpriseArchive.class);
       WebArchive web = er.getAsType(WebArchive.class, "dvdstore-web.war");
       web.addClasses(SearchTest.class);
+      
+      // Install org.jboss.seam.mock.MockSeamListener
+      web.delete("/WEB-INF/web.xml");
+      web.addAsWebInfResource("web.xml");
 
       return er;
    }

Modified: branches/community/Seam_2_3/examples-ee6/dvdstore/dvdstore-tests/src/test/java/com/jboss/dvd/seam/test/StoreManagerTest.java
===================================================================
--- branches/community/Seam_2_3/examples-ee6/dvdstore/dvdstore-tests/src/test/java/com/jboss/dvd/seam/test/StoreManagerTest.java	2012-04-13 15:48:58 UTC (rev 14578)
+++ branches/community/Seam_2_3/examples-ee6/dvdstore/dvdstore-tests/src/test/java/com/jboss/dvd/seam/test/StoreManagerTest.java	2012-04-13 16:02:36 UTC (rev 14579)
@@ -30,6 +30,10 @@
       EnterpriseArchive er = ShrinkWrap.create(ZipImporter.class, "seam-dvdstore.ear").importFrom(new File("../dvdstore-ear/target/seam-dvdstore.ear")).as(EnterpriseArchive.class);
       WebArchive web = er.getAsType(WebArchive.class, "dvdstore-web.war");
       web.addClasses(StoreManagerTest.class);
+      
+      // Install org.jboss.seam.mock.MockSeamListener
+      web.delete("/WEB-INF/web.xml");
+      web.addAsWebInfResource("web.xml");
 
       return er;
    }

Added: branches/community/Seam_2_3/examples-ee6/dvdstore/dvdstore-tests/src/test/resources-integration/web.xml
===================================================================
--- branches/community/Seam_2_3/examples-ee6/dvdstore/dvdstore-tests/src/test/resources-integration/web.xml	                        (rev 0)
+++ branches/community/Seam_2_3/examples-ee6/dvdstore/dvdstore-tests/src/test/resources-integration/web.xml	2012-04-13 16:02:36 UTC (rev 14579)
@@ -0,0 +1,12 @@
+<?xml version="1.0" ?>
+
+<web-app version="3.0"
+         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_3_0.xsd">
+         
+    <listener>
+        <listener-class>org.jboss.seam.mock.MockSeamListener</listener-class>
+    </listener>
+
+</web-app>



More information about the seam-commits mailing list