Hi, I'm getting multiple executions of all tests when adding the surefire 
report and the cobertura report plugins to my pom. Is it possible to have all 
the plugins collect info from only one test run?

I'm running 2.0.4. To reproduce:

1.Try
mvn archetype:create -DgroupId=com.mycompany.app -DartifactId=my-app

2. Add these lines to the pom:
   <reporting>
        <plugins>
            <plugin>
                <groupId>org.apache.maven.plugins</groupId>
                <artifactId>maven-surefire-report-plugin</artifactId>
            </plugin>
            <plugin>
                <groupId>org.codehaus.mojo</groupId>
                <artifactId>cobertura-maven-plugin</artifactId>
                <version>2.0</version>
            </plugin>
        </plugins>
    </reporting>

3. Run this command:
mvn clean package site

You get that the tests runs three times. One for packaging and one for each 
reporting plugin used.

BR
/Peter

Reply via email to