You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@ws.apache.org by ve...@apache.org on 2013/01/10 00:00:50 UTC

svn commit: r1431133 - in /webservices/commons/trunk/modules/axiom/systests/jboss-tests: pom.xml src/test/java/org/apache/axiom/systest/jboss/DialectTest.java

Author: veithen
Date: Wed Jan  9 23:00:49 2013
New Revision: 1431133

URL: http://svn.apache.org/viewvc?rev=1431133&view=rev
Log:
Work around an Arquillian issue.

Modified:
    webservices/commons/trunk/modules/axiom/systests/jboss-tests/pom.xml
    webservices/commons/trunk/modules/axiom/systests/jboss-tests/src/test/java/org/apache/axiom/systest/jboss/DialectTest.java

Modified: webservices/commons/trunk/modules/axiom/systests/jboss-tests/pom.xml
URL: http://svn.apache.org/viewvc/webservices/commons/trunk/modules/axiom/systests/jboss-tests/pom.xml?rev=1431133&r1=1431132&r2=1431133&view=diff
==============================================================================
--- webservices/commons/trunk/modules/axiom/systests/jboss-tests/pom.xml (original)
+++ webservices/commons/trunk/modules/axiom/systests/jboss-tests/pom.xml Wed Jan  9 23:00:49 2013
@@ -72,7 +72,22 @@
                 <artifactId>maven-dependency-plugin</artifactId>
                 <executions>
                     <execution>
-                        <id>unpack</id>
+                        <!-- Copy the dependencies that will be included in the WAR deployed
+                             to JBoss. This is necessary because Arquillian's Maven dependency
+                             resolution doesn't work correctly if some of the dependencies are
+                             snapshots from the current reactor. -->
+                        <id>copy-deps</id>
+                        <phase>generate-test-resources</phase>
+                        <goals>
+                            <goal>copy-dependencies</goal>
+                        </goals>
+                        <configuration>
+                            <includeArtifactIds>axiom-api,axiom-impl,woodstox-core-asl,stax2-api</includeArtifactIds>
+                            <outputDirectory>${project.build.directory}/deps</outputDirectory>
+                        </configuration>
+                    </execution>
+                    <execution>
+                        <id>unpack-jboss</id>
                         <phase>process-test-classes</phase>
                         <goals>
                             <goal>unpack</goal>

Modified: webservices/commons/trunk/modules/axiom/systests/jboss-tests/src/test/java/org/apache/axiom/systest/jboss/DialectTest.java
URL: http://svn.apache.org/viewvc/webservices/commons/trunk/modules/axiom/systests/jboss-tests/src/test/java/org/apache/axiom/systest/jboss/DialectTest.java?rev=1431133&r1=1431132&r2=1431133&view=diff
==============================================================================
--- webservices/commons/trunk/modules/axiom/systests/jboss-tests/src/test/java/org/apache/axiom/systest/jboss/DialectTest.java (original)
+++ webservices/commons/trunk/modules/axiom/systests/jboss-tests/src/test/java/org/apache/axiom/systest/jboss/DialectTest.java Wed Jan  9 23:00:49 2013
@@ -21,6 +21,7 @@ package org.apache.axiom.systest.jboss;
 import static org.junit.Assert.assertEquals;
 import static org.junit.Assert.assertFalse;
 
+import java.io.File;
 import java.io.StringReader;
 
 import javax.xml.stream.XMLInputFactory;
@@ -34,8 +35,6 @@ import org.jboss.arquillian.container.te
 import org.jboss.arquillian.junit.Arquillian;
 import org.jboss.shrinkwrap.api.ShrinkWrap;
 import org.jboss.shrinkwrap.api.spec.WebArchive;
-import org.jboss.shrinkwrap.resolver.api.DependencyResolvers;
-import org.jboss.shrinkwrap.resolver.api.maven.MavenDependencyResolver;
 import org.junit.Test;
 import org.junit.runner.RunWith;
 
@@ -44,8 +43,7 @@ public class DialectTest {
     @Deployment
     public static WebArchive createDeployment() {
         return ShrinkWrap.create(WebArchive.class, "dialect-test.war")
-                .addAsLibraries(DependencyResolvers.use(MavenDependencyResolver.class).loadMetadataFromPom("pom.xml").goOffline()
-                        .artifact("org.apache.ws.commons.axiom:axiom-impl").resolveAsFiles());
+                .addAsLibraries(new File("target/deps").listFiles());
     }
     
     /**