kordamp / kordamp-gradle-plugins

A collection of Gradle plugins
https://kordamp.org/kordamp-gradle-plugins/
Apache License 2.0
138 stars 25 forks source link

[Jacoco] Failed tests in one module stops build and report aggregation #535

Open Wrdle opened 7 months ago

Wrdle commented 7 months ago

Hi there,

At the moment I am facing an issue where upon running the aggregateJacocoReport from the main project if tests in module fail it causes the build to fail and following tests in other modules to not run and the report not generated.

Project structure looks like:

In terms of kordamp gradle plugins I am only using org.kordamp.gradle.jacoco version 0.54.0.

For tests each project applies the official jacoco plugin and configures the test task:

tasks.test {
    useJUnitPlatform()
}

If I configure ignoreFailures=true the tests continue through all modules to run and generate a aggregated report, however, without this property the tests in other modules are never run. Ideally I need the "build" to fail but all tests run and generate the aggregated report.

It looks like this may have been addressed here but not sure if its the same issue.

I understand this is more of a help question than an issue so I really appreciate your time and effort.

aalmiray commented 7 months ago

If this is your first time using the Kordamp Gradle Plugin suite to aggregate JaCoCo reports then I'd suggest you move on and use JaCoCo directly. I believe Gradle 7 or 8 added the behavior you seek. This plugin suite was created at a time where Gradle lacked lots of desirable behavior, such JaCoCo report aggregation.