[GRADLE-2960] JacocoReport tasks don't have dependencies on tasks that produce coverage data Created: 20/Nov/13 Updated: 09/May/14 Resolved: 09/May/14 |
|
Status: | Resolved |
Project: | Gradle |
Affects Version/s: | None |
Fix Version/s: | None |
Type: | Task | ||
Reporter: | Gradle Forums | Assignee: | Szczepan Faber |
Resolution: | Won't Fix | Votes: | 0 |
Description |
I noticed today that the JacocoReport tasks use `mustRunAfter` ordering rules instead of task dependencies for the `executionData` added via a task. Here's the [commit]([1]https://github.com/gradle/gradle/comm...) where it was changed. `mustRunAfter` only makes sense when the task can be run in a meaningful way without the other task's output. What good is a Jacoco report to me if I don't have any data in it? |
Comments |
Comment by Gradle Forums [ 20/Nov/13 ] |
Please see this issue here, which describes the same problem: [1]http://issues.gradle.org/browse/GRADL... |
Comment by Gradle Forums [ 20/Nov/13 ] |
Andrew, The idea is that you can generate coverage for a subset of tasks. This means you need to specify which coverage producing tasks to run, and the report task. |
Comment by Gradle Forums [ 20/Nov/13 ] |
How common is that use case? Just from my experience:
|
Comment by Gradle Forums [ 20/Nov/13 ] |
Unsure. I'm assuming that the current situation is an interim step until we get finalizers. In that case you will just run the coverage producing task(s) that will be finalized by the report task. Finalizers may be in 1.7. |
Comment by Szczepan Faber [ 09/May/14 ] |
We haven't reached a consensus about this story. I believe that we should use dependsOn, Adam prefers the current state of things (mustRunAfter) and we haven't got any other votes We are not planning on changing this behavior at the moment hence I'm closing this ticket. Feel free to comment or chip in to the discussion on the dev list. |