2 Replies Latest reply on Aug 28, 2011 7:25 AM by kpiwko

    Possible regression in artifact arquillian-container-impl-base

    vineet.reynolds

      I just noticed that v1.0.0.CR1 of arquillian-container-impl-base contains the following dependencies in it's POM:

       

             <dependency>

                  <groupId>org.jboss.shrinkwrap.resolver</groupId>

                  <artifactId>shrinkwrap-resolver-api</artifactId>

              </dependency>

              <dependency>

                  <groupId>org.jboss.shrinkwrap.resolver</groupId>

                  <artifactId>shrinkwrap-resolver-api-maven</artifactId>

              </dependency>

              <dependency>

                  <groupId>org.jboss.shrinkwrap.resolver</groupId>

                  <artifactId>shrinkwrap-resolver-impl-maven</artifactId>

              </dependency>

       

      while the same is absent since 1.0.0.CR2 onwards (until CR4). This necessitates adding these dependencies along with the required artifact: arquillian-junit-container to allow Arquillian tests have access to classes like DependencyResolvers and MavenDependencyResolver from the ShrinkWrap API. And this might turn out to be a bit messy, because the versions specified in a project's POM might be different from the one tested for an Arquillian release.

       

      Is this a regression? Or is it something that needs to be documented (possibly in a migration guide to CR2 and beyond)?

        • 1. Re: Possible regression in artifact arquillian-container-impl-base
          vineet.reynolds

          Ok, here's what I found - [ARQ-570|https://issues.jboss.org/browse/ARQ-470] was the bug that was originally fixed, where the ShrinkWrap Maven Resolver API usage was moved from Arquillian Core. The dependencies are now declared in the Arquillian BOM project, and here's how I fixed this in my project POM:

           

          {code:xml}

              <properties>

                  <arquillian.version>1.0.0.CR4</arquillian.version>

              </properties>

           

              <dependencyManagement>

                  <dependencies>

                      <!-- Dependencies for Arquillian -->

                      <dependency>

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

                          <artifactId>arquillian-bom</artifactId>

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

                          <type>pom</type>

                          <scope>import</scope>

                      </dependency>

                  </dependencies>

              </dependencyManagement>

           

              <dependencies>

                  <!-- Dependencies for Arquillian. Version is from Arquillian BOM -->

                  <dependency>

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

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

                      <scope>test</scope>

                  </dependency>

                  <!-- Add dependencies to shrinkwrap-resolver APIs from the Arquillian BOM.

                      Version is declared in BOM. -->

                  <dependency>

                      <groupId>org.jboss.shrinkwrap.resolver</groupId>

                      <artifactId>shrinkwrap-resolver-api</artifactId>

                      <scope>test</scope>

                  </dependency>

                  <dependency>

                      <groupId>org.jboss.shrinkwrap.resolver</groupId>

                      <artifactId>shrinkwrap-resolver-api-maven</artifactId>

                      <scope>test</scope>

                  </dependency>

                  <dependency>

                      <groupId>org.jboss.shrinkwrap.resolver</groupId>

                      <artifactId>shrinkwrap-resolver-impl-maven</artifactId>

                      <scope>test</scope>

                  </dependency>

              </dependencies>

          {code}

          • 2. Re: Possible regression in artifact arquillian-container-impl-base
            kpiwko

            Hi Vineet,

             

            you have found the right jira . ShrinkWrap Dependency Resolver is no longer a direct dependency of arquillian-container-impl-base. The main reason is to keep the dependency tree simpler, the other is that the resolver has been given it's own development cycle, so decoupling it from arquillian-container-impl-base will allow us to let it grow mature.

             

            User who wants to use the SW Resolver, has to specify the dependency himself, exactly the way you did.

             

            By the way, for most of the usages it should be sufficient to include shrinkwrap-resolver-impl-maven.