Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Allows the report mojo to reference binary/source files in other modules #217

Closed
wants to merge 2 commits into from
Closed

Allows the report mojo to reference binary/source files in other modules #217

wants to merge 2 commits into from

Conversation

chrisruffalo
Copy link

I've been working with a multi-module report where I wanted the ability to create coverage reports based on the merged reports. I've really only been able to find good ways of doing this that all involve hacks.

So here's my counter-hack.

I'm not sure this would be accepted cleanly but I would appreciate some feedback.

Thanks!

…r module (allows for easy integration with merge module)

AbstractReportMojo : accepts source and binary classes from other modules
BundleCreator : can now accept compiled (binary) file locations from other modules
@chrisruffalo
Copy link
Author

I see the other pull request (#97) but I don't see any movement on it and wanted to maybe take a crack at doing it in a more simple way.

@marchof
Copy link
Member

marchof commented May 30, 2014

For multi-module reporting I would prefer to have a separate report bundle for every module. Not just merging all classes in into one bundle. Why?

  • Better scalibility for hughe report (bundes are internally processed one after the other)
  • The module structure is reflected in the report
  • Different classes with the same name possible

@chrisruffalo
Copy link
Author

My current understanding is that JaCoCo can only report, within a single module, on the test coverage produced by that module. If a class receives more test coverage (say from a separate integration-test module) then that test coverage would not appear as cumulative in the report.

Unless I'm mistaken about how it works.

So this change request is intended to address the use case where someone has merged test execution results (for example, using the merge goal) from multiple different modules or test executions.

This change replaces none of the old capability (which it should not based exactly on the reasons you gave) but augments it to allow for more diverse configurations.

Again, unless I'm missing some feature of the report generator that allows me to gain the type of report I'm looking for. I know that there is an aggregate-report feature but didn't see any direct references in the maven plugin code.

@marchof
Copy link
Member

marchof commented May 30, 2014

You're right: This is not yet there in the Maven code. The Ant task allows to create groups.

@chrisruffalo
Copy link
Author

I see that you're working on that over in #97 but I didn't see any recent progress. This is more of an easy stopgap, I'll readily admit this is not the best solution.

@marchof
Copy link
Member

marchof commented May 30, 2014

Unfortunatelly this is a current restriction at the JaCoCo project: Due to the very limited resources we're very reluctant to add partial solutions where we expect more trouble afterwards.

@Godin Godin added this to the Maven multi-module projects milestone Mar 24, 2015
@Godin Godin self-assigned this Mar 24, 2015
@marchof
Copy link
Member

marchof commented Mar 23, 2016

We will go with a more generic solution as proposed in #97 or #388.

@marchof marchof closed this Mar 23, 2016
@Godin Godin modified the milestones: 0.7.7, Maven multi-module projects Jun 10, 2016
@jacoco jacoco locked and limited conversation to collaborators Jan 11, 2017
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants