You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@maven.apache.org by "Marcin Kuthan (JIRA)" <ji...@codehaus.org> on 2010/12/16 12:11:57 UTC

[jira] Created: (SUREFIRE-666) Aggregate report is empty for multimodule build.

Aggregate report is empty for multimodule build.
------------------------------------------------

                 Key: SUREFIRE-666
                 URL: http://jira.codehaus.org/browse/SUREFIRE-666
             Project: Maven Surefire
          Issue Type: Bug
          Components: Maven Surefire Report Plugin
    Affects Versions: 2.6
         Environment: Maven 2.2.1
            Reporter: Marcin Kuthan


When the report aggregation is enabled:

1. On module level empty surefire report page is generated
2. On top level surefire report with 0 tests is generated

Surefire report plugin configuration:
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-surefire-report-plugin</artifactId>
<version>${plugins.surefireVersion}</version>
<configuration>
<reportsDirectories>
<reportsDirectory>${project.build.directory}/surefire-reports/</reportsDirectory>
<reportsDirectory>${project.build.directory}/failsafe-reports/</reportsDirectory>
</reportsDirectories>
</configuration>
<reportSets>
<reportSet>
<reports>
<report>report-only</report>
</reports>
</reportSet>
</reportSets>
</plugin>

To reproduce the issue:
1. svn checkout http://m4enterprise.googlecode.com/svn/trunk/ m4enterprise-read-only
2. call "mvn install" against corporate-pom and modular-war modules.
3. call "mvn site:stage -Daggregate=true" against modular-war.
4. check the reports in modular-war/target/stage directory.

I was looking for description how to configure surefire and failsafe together for multi module project. No luck :-(

Thanks,
Marcin

-- 
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: http://jira.codehaus.org/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

[jira] Closed: (SUREFIRE-666) Aggregate report is empty for multimodule build.

Posted by "Kristian Rosenvold (JIRA)" <ji...@codehaus.org>.
     [ http://jira.codehaus.org/browse/SUREFIRE-666?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Kristian Rosenvold closed SUREFIRE-666.
---------------------------------------

    Resolution: Duplicate

This issue duplicated SUREFIRE-570 as decribed in the original issue text. The "mee too" section seems to describe a different issue.

> Aggregate report is empty for multimodule build.
> ------------------------------------------------
>
>                 Key: SUREFIRE-666
>                 URL: http://jira.codehaus.org/browse/SUREFIRE-666
>             Project: Maven Surefire
>          Issue Type: Bug
>          Components: Maven Surefire Report Plugin
>    Affects Versions: 2.6
>         Environment: Maven 2.2.1
>            Reporter: Marcin Kuthan
>         Attachments: core.png, parent.png
>
>
> When the report aggregation is enabled:
> 1. On module level empty surefire report page is generated
> 2. On top level surefire report with 0 tests is generated
> Surefire report plugin configuration:
> <plugin>
> <groupId>org.apache.maven.plugins</groupId>
> <artifactId>maven-surefire-report-plugin</artifactId>
> <version>${plugins.surefireVersion}</version>
> <configuration>
> <reportsDirectories>
> <reportsDirectory>${project.build.directory}/surefire-reports/</reportsDirectory>
> <reportsDirectory>${project.build.directory}/failsafe-reports/</reportsDirectory>
> </reportsDirectories>
> </configuration>
> <reportSets>
> <reportSet>
> <reports>
> <report>report-only</report>
> </reports>
> </reportSet>
> </reportSets>
> </plugin>
> To reproduce the issue:
> 1. svn checkout http://m4enterprise.googlecode.com/svn/trunk/ m4enterprise-read-only
> 2. call "mvn install" against corporate-pom and modular-war modules.
> 3. call "mvn site:stage -Daggregate=true" against modular-war.
> 4. check the reports in modular-war/target/stage directory.
> I was looking for description how to configure surefire and failsafe together for multi module project. No luck :-(
> Thanks,
> Marcin

-- 
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: http://jira.codehaus.org/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

[jira] Updated: (SUREFIRE-666) Aggregate report is empty for multimodule build.

Posted by "Marcin Kuthan (JIRA)" <ji...@codehaus.org>.
     [ http://jira.codehaus.org/browse/SUREFIRE-666?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Marcin Kuthan updated SUREFIRE-666:
-----------------------------------

    Attachment: parent.png
                core.png

Screenshot with surefire report pages.

> Aggregate report is empty for multimodule build.
> ------------------------------------------------
>
>                 Key: SUREFIRE-666
>                 URL: http://jira.codehaus.org/browse/SUREFIRE-666
>             Project: Maven Surefire
>          Issue Type: Bug
>          Components: Maven Surefire Report Plugin
>    Affects Versions: 2.6
>         Environment: Maven 2.2.1
>            Reporter: Marcin Kuthan
>         Attachments: core.png, parent.png
>
>
> When the report aggregation is enabled:
> 1. On module level empty surefire report page is generated
> 2. On top level surefire report with 0 tests is generated
> Surefire report plugin configuration:
> <plugin>
> <groupId>org.apache.maven.plugins</groupId>
> <artifactId>maven-surefire-report-plugin</artifactId>
> <version>${plugins.surefireVersion}</version>
> <configuration>
> <reportsDirectories>
> <reportsDirectory>${project.build.directory}/surefire-reports/</reportsDirectory>
> <reportsDirectory>${project.build.directory}/failsafe-reports/</reportsDirectory>
> </reportsDirectories>
> </configuration>
> <reportSets>
> <reportSet>
> <reports>
> <report>report-only</report>
> </reports>
> </reportSet>
> </reportSets>
> </plugin>
> To reproduce the issue:
> 1. svn checkout http://m4enterprise.googlecode.com/svn/trunk/ m4enterprise-read-only
> 2. call "mvn install" against corporate-pom and modular-war modules.
> 3. call "mvn site:stage -Daggregate=true" against modular-war.
> 4. check the reports in modular-war/target/stage directory.
> I was looking for description how to configure surefire and failsafe together for multi module project. No luck :-(
> Thanks,
> Marcin

-- 
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: http://jira.codehaus.org/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

[jira] Commented: (SUREFIRE-666) Aggregate report is empty for multimodule build.

Posted by "Martin Ackermann (JIRA)" <ji...@codehaus.org>.
    [ http://jira.codehaus.org/browse/SUREFIRE-666?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=250865#action_250865 ] 

Martin Ackermann commented on SUREFIRE-666:
-------------------------------------------

I'm struggling with the same problem. I'm using Maven 3.0.1, Surefire 2.7.1 and Site 3.0-beta-3 and "mvn site-deploy", but the problem is the same. The problem seems to be that the aggregate surefire report for the parent is generated before the surefire plugin runs the tests for the child modules. So the aggregate surefire report doesn't find any surefire test results for the child modules. The indication is in the log: "[INFO] Generating 'Surefire Report' report" for the parent occurs before "[INFO] Building <child module>".

If I run "mvn clean mvn site-deploy; mvn site-deploy", the resulting aggregate surefire report is correct. The reason might be that the second site-deploy run collects the surefire results for the child modules from the previous run. "mvn clean test; mvn site-deploy" works as well. These workarounds only work under the condition, that "<inherited>" is not set to "false" for the surefire report plugin in the reporting section of the parent pom.

(In contrast, "mvn clean site-deploy site-deploy" and "mvn clean test site-deploy" behave different and don't provide the correct surefire results when working on previously cleaned target directories.)

Marcin, did you try "mvn clean mvn site:stage -Daggregate=true; mvn site:stage -Daggregate=true" as workaround?

My question to the experts: Why does the surefire report plugin not immediately descend to the child modules, compile and test them while executing the aggregate report for the parent module?

Kind regards, Martin.

BTW: Marcin, you set "Affects Version/s" to 2.6, but in your corporate pom.xml, you specify 2.7. Maybe the pom.xml in your svn repository has evolved meanwhile...


> Aggregate report is empty for multimodule build.
> ------------------------------------------------
>
>                 Key: SUREFIRE-666
>                 URL: http://jira.codehaus.org/browse/SUREFIRE-666
>             Project: Maven Surefire
>          Issue Type: Bug
>          Components: Maven Surefire Report Plugin
>    Affects Versions: 2.6
>         Environment: Maven 2.2.1
>            Reporter: Marcin Kuthan
>         Attachments: core.png, parent.png
>
>
> When the report aggregation is enabled:
> 1. On module level empty surefire report page is generated
> 2. On top level surefire report with 0 tests is generated
> Surefire report plugin configuration:
> <plugin>
> <groupId>org.apache.maven.plugins</groupId>
> <artifactId>maven-surefire-report-plugin</artifactId>
> <version>${plugins.surefireVersion}</version>
> <configuration>
> <reportsDirectories>
> <reportsDirectory>${project.build.directory}/surefire-reports/</reportsDirectory>
> <reportsDirectory>${project.build.directory}/failsafe-reports/</reportsDirectory>
> </reportsDirectories>
> </configuration>
> <reportSets>
> <reportSet>
> <reports>
> <report>report-only</report>
> </reports>
> </reportSet>
> </reportSets>
> </plugin>
> To reproduce the issue:
> 1. svn checkout http://m4enterprise.googlecode.com/svn/trunk/ m4enterprise-read-only
> 2. call "mvn install" against corporate-pom and modular-war modules.
> 3. call "mvn site:stage -Daggregate=true" against modular-war.
> 4. check the reports in modular-war/target/stage directory.
> I was looking for description how to configure surefire and failsafe together for multi module project. No luck :-(
> Thanks,
> Marcin

-- 
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: http://jira.codehaus.org/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira