[seam-commits] Seam SVN: r13652 - in examples/trunk/javaee-booking/src/test/java/org/jboss/seam/examples/booking: inventory and 1 other directory.
seam-commits at lists.jboss.org
seam-commits at lists.jboss.org
Fri Aug 27 17:10:29 EDT 2010
Author: dan.j.allen
Date: 2010-08-27 17:10:29 -0400 (Fri, 27 Aug 2010)
New Revision: 13652
Modified:
examples/trunk/javaee-booking/src/test/java/org/jboss/seam/examples/booking/booking/BookingAgentTest.java
examples/trunk/javaee-booking/src/test/java/org/jboss/seam/examples/booking/inventory/HotelSearchTest.java
Log:
migrate to latest ShrinkWrap API
Modified: examples/trunk/javaee-booking/src/test/java/org/jboss/seam/examples/booking/booking/BookingAgentTest.java
===================================================================
--- examples/trunk/javaee-booking/src/test/java/org/jboss/seam/examples/booking/booking/BookingAgentTest.java 2010-08-27 21:09:46 UTC (rev 13651)
+++ examples/trunk/javaee-booking/src/test/java/org/jboss/seam/examples/booking/booking/BookingAgentTest.java 2010-08-27 21:10:29 UTC (rev 13652)
@@ -22,8 +22,8 @@
import org.jboss.seam.examples.booking.support.NoOpLogger;
import org.jboss.shrinkwrap.api.Archive;
import org.jboss.shrinkwrap.api.ShrinkWrap;
+import org.jboss.shrinkwrap.api.asset.ByteArrayAsset;
import org.jboss.shrinkwrap.api.spec.WebArchive;
-import org.jboss.shrinkwrap.impl.base.asset.ByteArrayAsset;
import org.jboss.weld.context.api.ContextualInstance;
import org.jboss.weld.context.api.helpers.AbstractMapBackedBeanStore;
import org.junit.Assert;
@@ -36,7 +36,7 @@
@Deployment
public static Archive<?> createTestArchive()
{
- WebArchive war = ShrinkWrap.create("test.war", WebArchive.class)
+ WebArchive war = ShrinkWrap.create(WebArchive.class, "test")
.addPackage(Hotel.class.getPackage())
.addClasses(BookingAgent.class, BookingAgent.class, Confirmed.class,
Authenticated.class, NoOpLogger.class)
Modified: examples/trunk/javaee-booking/src/test/java/org/jboss/seam/examples/booking/inventory/HotelSearchTest.java
===================================================================
--- examples/trunk/javaee-booking/src/test/java/org/jboss/seam/examples/booking/inventory/HotelSearchTest.java 2010-08-27 21:09:46 UTC (rev 13651)
+++ examples/trunk/javaee-booking/src/test/java/org/jboss/seam/examples/booking/inventory/HotelSearchTest.java 2010-08-27 21:10:29 UTC (rev 13652)
@@ -1,21 +1,22 @@
package org.jboss.seam.examples.booking.inventory;
import java.util.List;
+
import javax.enterprise.inject.Instance;
import javax.inject.Inject;
import javax.persistence.EntityManager;
import javax.persistence.PersistenceContext;
import javax.transaction.UserTransaction;
+
import org.jboss.arquillian.api.Deployment;
import org.jboss.arquillian.junit.Arquillian;
+import org.jboss.seam.examples.booking.model.Hotel;
import org.jboss.seam.examples.booking.support.MavenArtifactResolver;
-import org.jboss.seam.examples.booking.model.Hotel;
import org.jboss.seam.examples.booking.support.NoOpLogger;
import org.jboss.shrinkwrap.api.Archive;
import org.jboss.shrinkwrap.api.ShrinkWrap;
-import org.jboss.shrinkwrap.api.spec.JavaArchive;
+import org.jboss.shrinkwrap.api.asset.ByteArrayAsset;
import org.jboss.shrinkwrap.api.spec.WebArchive;
-import org.jboss.shrinkwrap.impl.base.asset.ByteArrayAsset;
import org.junit.Assert;
import org.junit.Test;
import org.junit.runner.RunWith;
@@ -33,7 +34,7 @@
// .addManifestResource(new ByteArrayAsset(new byte[0]), "beans.xml");
// return jar;
// WebArchive does work in all cases (except JBoss AS still breaks with EJBs)
- WebArchive war = ShrinkWrap.create("test.war", WebArchive.class)
+ WebArchive war = ShrinkWrap.create(WebArchive.class, "test")
.addPackage(HotelSearch.class.getPackage())
.addPackage(Hotel.class.getPackage())
.addClasses(NoOpLogger.class)
More information about the seam-commits
mailing list