4 Replies Latest reply on Nov 20, 2011 4:09 PM by mcgin

    What would cause this error: Could not invoke deployment method: public static org.jboss.shrinkwrap.api.spec.JavaArchive

    mcgin Newbie

      I tried to add Arquillian to one of my projects this weekend.  I'm getting a strange error that seems to be related to Shrinkwrap, I'm guessing it is something to do with the wrong versions in the dependency tree, but for the life of me I can't resolve it.

       

      The error I'm getting is:

       

      Tests in error:

        com.test.service.ServiceTest: Could not invoke deployment method: public static org.jboss.shrinkwrap.api.spec.JavaArchive com.test.service.ServiceTest.createTestArchive()

       

      Relevant pom contents:

      <profile>

                  <activation>

                      <activeByDefault>true</activeByDefault>

                  </activation>

                  <id>jbossas-remote-7</id>

                  <dependencies>

                      <dependency>

                          <groupId>org.jboss.as</groupId>

                          <artifactId>jboss-as-arquillian-container-remote</artifactId>

                          <version>${jbossas.version}</version>

                          <scope>test</scope>

                      </dependency>

                      <dependency>

                          <groupId>org.jboss.arquillian.junit</groupId>

                          <artifactId>arquillian-junit-container</artifactId>

                          <version>${arquillian.version}</version>

                          <scope>test</scope>

                      </dependency>

                      <dependency><!-- This one conflicts with Arquillian tests so keep at the bottom -->

                          <groupId>javax</groupId>

                          <artifactId>javaee-api</artifactId>

                          <version>6.0</version>

                          <scope>provided</scope>

                      </dependency>

                  </dependencies>

              </profile>

       

      And this is the complete dependency tree from Maven running in debug mode:

       

      [DEBUG] com.test:test:war:1.0-SNAPSHOT

      [DEBUG]    org.apache.httpcomponents:httpclient:jar:4.1.2:compile

      [DEBUG]       org.apache.httpcomponents:httpcore:jar:4.1.2:compile

      [DEBUG]       commons-logging:commons-logging:jar:1.1.1:compile

      [DEBUG]       commons-codec:commons-codec:jar:1.4:compile

      [DEBUG]    org.eclipse.persistence:eclipselink:jar:2.2.0:compile

      [DEBUG]    org.eclipse.persistence:javax.persistence:jar:2.0.3:compile

      [DEBUG]    org.eclipse.persistence:org.eclipse.persistence.jpa.modelgen.processor:jar:2.2.0:provided

      [DEBUG]    net.sf.opencsv:opencsv:jar:2.3:compile

      [DEBUG]    com.vaadin:vaadin:jar:6.5.0:compile

      [DEBUG]    org.slf4j:slf4j-api:jar:1.6.4:compile

      [DEBUG]    org.slf4j:slf4j-log4j12:jar:1.6.4:compile

      [DEBUG]       log4j:log4j:jar:1.2.16:compile

      [DEBUG]    junit:junit:jar:4.8.1:test

      [DEBUG]    org.jboss.as:jboss-as-arquillian-container-remote:jar:7.0.2.Final:test

      [DEBUG]       org.jboss.as:jboss-as-arquillian-common:jar:7.0.2.Final:test

      [DEBUG]          org.jboss.arquillian.container:arquillian-container-osgi:jar:1.0.0.CR4:test

      [DEBUG]          org.jboss.arquillian.testenricher:arquillian-testenricher-cdi:jar:1.0.0.CR4:test

      [DEBUG]          org.jboss.arquillian.testenricher:arquillian-testenricher-ejb:jar:1.0.0.CR4:test

      [DEBUG]          org.jboss.arquillian.testenricher:arquillian-testenricher-initialcontext:jar:1.0.0.CR4:test

      [DEBUG]          org.jboss.arquillian.testenricher:arquillian-testenricher-osgi:jar:1.0.0.CR4:test

      [DEBUG]             javax.inject:javax.inject:jar:1:test

      [DEBUG]          org.jboss.arquillian.testenricher:arquillian-testenricher-resource:jar:1.0.0.CR4:test

      [DEBUG]          org.jboss.as:jboss-as-arquillian-testenricher-msc:jar:7.0.2.Final:test

      [DEBUG]             org.jboss.logging:jboss-logging:jar:3.0.1.GA:test

      [DEBUG]             org.jboss.msc:jboss-msc:jar:1.0.1.GA:test

      [DEBUG]          org.jboss.as:jboss-as-controller-client:jar:7.0.2.Final:test

      [DEBUG]             org.jboss.as:jboss-as-protocol:jar:7.0.2.Final:test

      [DEBUG]                org.jboss.logmanager:jboss-logmanager:jar:1.2.0.GA:test

      [DEBUG]                org.jboss.remoting3:jboss-remoting:jar:3.2.0.Beta2:test

      [DEBUG]                   org.jboss.xnio:xnio-api:jar:3.0.0.Beta2:test

      [DEBUG]                org.jboss.sasl:jboss-sasl:jar:1.0.0.Beta2:test

      [DEBUG]                org.jboss.xnio:xnio-nio:jar:3.0.0.Beta3:test

      [DEBUG]             org.jboss:jboss-dmr:jar:1.0.0.Final:test

      [DEBUG]             org.jboss.threads:jboss-threads:jar:2.0.0.GA:test

      [DEBUG]          org.jboss.as:jboss-as-jmx:jar:7.0.2.Final:test

      [DEBUG]             org.jboss:jboss-common-core:jar:2.2.17.GA:test

      [DEBUG]             org.jboss.as:jboss-as-server:jar:7.0.2.Final:test

      [DEBUG]                org.jboss.as:jboss-as-controller:jar:7.0.2.Final:test

      [DEBUG]                   org.jboss:staxmapper:jar:1.0.0.Final:test

      [DEBUG]                org.jboss.as:jboss-as-domain-http-api:jar:7.0.2.Final:test

      [DEBUG]                   org.jboss.as:jboss-as-domain-management:jar:7.0.2.Final:test

      [DEBUG]                   org.jboss.com.sun.httpserver:httpserver:jar:1.0.0.Beta2:test

      [DEBUG]                   org.jboss.as:jboss-as-console:jar:resources:1.0.0.Beta17:test

      [DEBUG]                org.jboss.as:jboss-as-deployment-repository:jar:7.0.2.Final:test

      [DEBUG]                org.jboss.as:jboss-as-embedded:jar:7.0.2.Final:test

      [DEBUG]                org.jboss.as:jboss-as-platform-mbean:jar:7.0.2.Final:test

      [DEBUG]                org.jboss.as:jboss-as-process-controller:jar:7.0.2.Final:test

      [DEBUG]                   system:jdk-tools:jar:jdk:system

      [DEBUG]                org.jboss.as:jboss-as-remoting:jar:7.0.2.Final:test

      [DEBUG]                   org.jboss.as:jboss-as-network:jar:7.0.2.Final:test

      [DEBUG]                   org.jboss.as:jboss-as-threads:jar:7.0.2.Final:test

      [DEBUG]                org.jboss:jandex:jar:1.0.3.Final:test

      [DEBUG]                org.jboss.invocation:jboss-invocation:jar:1.1.0.Final:test

      [DEBUG]                org.jboss.logmanager:jboss-logmanager-log4j:jar:1.0.0.GA:test

      [DEBUG]                org.jboss.stdio:jboss-stdio:jar:1.0.0.GA:test

      [DEBUG]                org.jboss:jboss-vfs:jar:3.0.1.GA:test

      [DEBUG]          org.jboss.shrinkwrap:shrinkwrap-api:jar:1.0.0-beta-5:test

      [DEBUG]          org.jboss.shrinkwrap.resolver:shrinkwrap-resolver-impl-maven:jar:1.0.0-beta-5:test

      [DEBUG]             org.jboss.shrinkwrap.resolver:shrinkwrap-resolver-api:jar:1.0.0-beta-5:test

      [DEBUG]             org.jboss.shrinkwrap.resolver:shrinkwrap-resolver-api-maven:jar:1.0.0-beta-5:test

      [DEBUG]          org.jboss.osgi.spi:jbosgi-spi:jar:1.0.28:test

      [DEBUG]             org.jboss.osgi.vfs:jbosgi-vfs:jar:1.0.5:test

      [DEBUG]          org.osgi:org.osgi.core:jar:4.2.0:test

      [DEBUG]       org.jboss.as:jboss-as-arquillian-protocol-jmx:jar:7.0.2.Final:test

      [DEBUG]          org.jboss.as:jboss-as-osgi-service:jar:7.0.2.Final:test

      [DEBUG]             org.jboss.as:jboss-as-ee:jar:7.0.2.Final:test

      [DEBUG]                javax.validation:validation-api:jar:1.0.0.GA:test

      [DEBUG]                org.hibernate:hibernate-validator:jar:4.2.0.Final:test

      [DEBUG]                org.jboss.interceptor:jboss-interceptor-spi:jar:2.0.0.Alpha3:test

      [DEBUG]                org.jboss.metadata:jboss-metadata-common:jar:7.0.0.Beta11:test

      [DEBUG]                   org.jboss.spec.javax.ejb:jboss-ejb-api_3.1_spec:jar:1.0.0.Final:test

      [DEBUG]                      javax.xml:jaxrpc-api:jar:1.1:test

      [DEBUG]                   org.jboss.spec.javax.annotation:jboss-annotations-api_1.1_spec:jar:1.0.0.Final:test

      [DEBUG]                org.jboss.metadata:jboss-metadata-ear:jar:7.0.0.Beta11:test

      [DEBUG]                org.jboss.spec.javax.transaction:jboss-transaction-api_1.1_spec:jar:1.0.0.Final:test

      [DEBUG]                org.jboss.spec.javax.interceptor:jboss-interceptors-api_1.1_spec:jar:1.0.0.Final:test

      [DEBUG]             org.jboss.as:jboss-as-naming:jar:7.0.2.Final:test

      [DEBUG]             org.jboss.modules:jboss-modules:jar:1.0.2.GA:test

      [DEBUG]             org.jboss.osgi.deployment:jbosgi-deployment:jar:1.0.10:test

      [DEBUG]             org.jboss.osgi.framework:jbosgi-framework-core:jar:1.0.0.CR8:test

      [DEBUG]                org.jboss.osgi.resolver:jbosgi-resolver-felix:jar:1.0.9:test

      [DEBUG]                   org.jboss.osgi.resolver:jbosgi-resolver-spi:jar:1.0.9:test

      [DEBUG]                org.jboss.osgi.vfs:jbosgi-vfs30:jar:1.0.6:test

      [DEBUG]             org.jboss.osgi.resolver:jbosgi-resolver-api:jar:1.0.9:test

      [DEBUG]                org.jboss.osgi.resolver:jbosgi-resolver-metadata:jar:1.0.9:test

      [DEBUG]             org.osgi:org.osgi.compendium:jar:4.2.0:test

      [DEBUG]          org.jboss.arquillian.core:arquillian-core-spi:jar:1.0.0.CR4:test

      [DEBUG]          org.jboss.arquillian.protocol:arquillian-protocol-jmx:jar:1.0.0.CR4:test

      [DEBUG]       org.jboss.marshalling:jboss-marshalling-river:jar:1.3.0.GA:test

      [DEBUG]          org.jboss.marshalling:jboss-marshalling:jar:1.3.0.GA:test

      [DEBUG]       org.jboss.arquillian.core:arquillian-core-api:jar:1.0.0.CR4:test

      [DEBUG]       org.jboss.as:jboss-as-build-config:jar:7.0.2.Final:test

      [DEBUG]    org.jboss.arquillian.junit:arquillian-junit-container:jar:1.0.0.CR5:test

      [DEBUG]       org.jboss.arquillian.junit:arquillian-junit-core:jar:1.0.0.CR5:test

      [DEBUG]       org.jboss.arquillian.test:arquillian-test-api:jar:1.0.0.CR5:test

      [DEBUG]       org.jboss.arquillian.test:arquillian-test-spi:jar:1.0.0.CR5:test

      [DEBUG]       org.jboss.arquillian.container:arquillian-container-test-api:jar:1.0.0.CR5:test

      [DEBUG]       org.jboss.arquillian.container:arquillian-container-test-spi:jar:1.0.0.CR5:test

      [DEBUG]          org.jboss.arquillian.container:arquillian-container-spi:jar:1.0.0.CR5:test

      [DEBUG]             org.jboss.shrinkwrap.descriptors:shrinkwrap-descriptors-api:jar:1.1.0-beta-1:test

      [DEBUG]       org.jboss.arquillian.core:arquillian-core-impl-base:jar:1.0.0.CR5:test

      [DEBUG]       org.jboss.arquillian.test:arquillian-test-impl-base:jar:1.0.0.CR5:test

      [DEBUG]       org.jboss.arquillian.container:arquillian-container-impl-base:jar:1.0.0.CR5:test

      [DEBUG]          org.jboss.arquillian.config:arquillian-config-api:jar:1.0.0.CR5:test

      [DEBUG]          org.jboss.arquillian.config:arquillian-config-impl-base:jar:1.0.0.CR5:test

      [DEBUG]             org.jboss.shrinkwrap.descriptors:shrinkwrap-descriptors-spi:jar:1.1.0-beta-1:test

      [DEBUG]       org.jboss.arquillian.container:arquillian-container-test-impl-base:jar:1.0.0.CR5:test

      [DEBUG]       org.jboss.shrinkwrap:shrinkwrap-impl-base:jar:1.0.0-beta-5:test

      [DEBUG]          org.jboss.shrinkwrap:shrinkwrap-spi:jar:1.0.0-beta-5:test

      [DEBUG]    javax:javaee-api:jar:6.0:provided