Well the question you really will want to know is: "do I want any other modules to depend on the integration tests being successful?"
If the answer is "yes" then you will most likely need to deploy something (<packaging>pom</packaging>) and that may require adding the missing bindings into the lifecycle. If the answer is "no" then you will just configure the integration test module with <plugin><artifactId>maven-deploy-plugin</artifactId></configuration><skip>true</skip></configuration></plugin> On 9 October 2014 09:23, Robert Mark Bram < [email protected]> wrote: > My parent POM declares this Selenium project in a profile. > <profile> > <id>default-build</id> > <!-- This profile will be active if another profile isn't triggered > --> > <activation> > <activeByDefault>true</activeByDefault> > </activation> > <modules> > <module>FooProject-Model</module> > <module>FooProject-Thermal</module> > <module>FooProject-ViewController</module> > <module>FooProject-API-V1</module> > <module>FooProject-Monitoring</module> > <module>FooProject-ADF</module> > <module>FooProject-BIRT</module> > <module>FooProject-Selenium</module> > </modules> > </profile> > > And the Selenium pom (sub-module) has the following: > > Packaging > <packaging>jar</packaging> > > Depend on the ear being built and deployed from another sub-module project. > <dependencies> > <dependency> > <groupId>${project.groupId}</groupId> > <artifactId>FooProject-ADF</artifactId> > <version>1.0</version> > <type>ear</type> > </dependency> > > Run integration tests. > </dependencies> > <build> > <plugins> > <plugin> > <groupId>org.apache.maven.plugins</groupId> > <artifactId>maven-failsafe-plugin</artifactId> > <version>2.17</version> > <configuration> > <forkMode>once</forkMode> > </configuration> > <executions> > <execution> > <goals> > <goal>integration-test</goal> > <goal>verify</goal> > </goals> > </execution> > </executions> > </plugin> > </plugins> > </build> > > The build (run from parent pom) is failing with this error: > [ERROR] Failed to execute goal > org.apache.maven.plugins:maven-deploy-plugin:2.7:deploy > (default-deploy) on project FooProject-Selenium: Deployment failed: > repository element was not specified in the POM inside > distributionManagement element or in > -DaltDeploymentRepository=id::layout::url parameter -> [Help 1] > > I understand this is because by specifying package as jar, Mavan wants > to know where I want to put the FooProject-Selenium jar, and of course > I don't want to generate a jar at all. > > I have ready suggestions that I should use the pom packaging statement > and http://stackoverflow.com/a/8845858/257233 says that if I do that, > I will have to explicitly call my goals with > mvn clean compiler:testCompile surefire:test > But I don't want this - I need the parent pom to be able to be able to > co-ordinate the entire build. > > So.. what is the best way to deal with this? > > Rob > :) > > --------------------------------------------------------------------- > To unsubscribe, e-mail: [email protected] > For additional commands, e-mail: [email protected] > >
