Recursive report aggregation in maven

12 views
Skip to first unread message

Timo Abele

unread,
Jun 16, 2025, 4:18:21 AMJun 16
to JaCoCo and EclEmma Users
I'm trying to generate an aggregate report for https://github.com/assertj/assertj which has the following module structure:

AssertJ
├── assertj-core
├── assertj-guava
├── assertj-parent
└── assertj-tests
    ├── assertj-integration-tests
    │   ├── assertj-core-groovy
    │   ├── assertj-core-tests
    │   ├── assertj-guava-tests
    │   └── ...
    └── assertj-performance-tests

The integration tests are two levels down from the modules that they reference. I'm trying to solve this on a smaller scale by playing around with this project from the reference: https://github.com/jacoco/jacoco/tree/master/jacoco-maven-plugin.test/it/it-report-aggregate.
My fork has the structure

it-report-aggregate
├── a-core
── a-tests
    
── integration-tests
        
── a-core-tests

When I add a top level report module and directly reference a-core-tests in the pom.xml
and execute 
cd jacoco-maven-plugin.test/it/it-report-aggregate
mvn clean verify
 a report is generated at report/target/site/jacoco-aggregate/index.html.

But it feels wrong to explicitly list the test subsubmodules (which in the target project are many) outside of a-tests. So I would like a-tests to create its own "sub report" and then aggregate that sub report along with the other top level reports.
I've pushed my attempt at this to debug/recursive-reporting. The module structure is:
it-report-aggregate
├── a-core
── a-tests
│   └
── integration-tests
│       
── a-core-tests
│       
── ...
│       └── test-report
── report

where report depends on a-core and test-report, and test-report depends on all the modules in integration-tests.
But when I execute mvn clean verify (-pl a-tests/integration-tests) there, no sub report is generated (much less aggregated). Actually, cd a-tests/integration-tests; mvn clean verify does generate a report, but it is empty (Missed Instructions: 0 of 0).

Is it possible to aggregate aggregated reports? How would I do that?
Reply all
Reply to author
Forward
0 new messages