On Wednesday, August 2, 2017 at 10:49:29 AM UTC+2, Andrew Iyer wrote:
>
> Thanks for this - so aside from the git repo, there isn't any 
> documentation for using java code to generate merged reports? 
>

As was said earlier - there are plenty docs at 
http://www.jacoco.org/jacoco/trunk/doc/ , please read them.

Among others there are JavaDoc for all APIs 
- http://www.jacoco.org/jacoco/trunk/doc/api/index.html
and API Usage Examples - http://www.jacoco.org/jacoco/trunk/doc/api.html
 

> I've never been very good with maven, and I couldn't really see how to 
> take *already existing* exec files and merge them in maven, all I saw was 
> how to generate and then merge the files, which isn't what I want to do.
>

Again as was said earlier - there is "Merge" Maven Goal ( 
http://www.jacoco.org/jacoco/trunk/doc/merge-mojo.html ) that allows to 
merge *already existing* exec files.
And there is "Merge" Ant Task ( 
http://www.jacoco.org/jacoco/trunk/doc/ant.html ) and not yet released 
"Merge" command in command line interface ( 
http://www.jacoco.org/jacoco/trunk/doc/cli.html ). 

 

> On Sunday, July 23, 2017 at 12:31:12 PM UTC+1, Evgeny Mandrikov wrote:
>>
>> Please read the documentation http://www.jacoco.org/jacoco/trunk/doc/
>> There is "Merge" Ant Task ( 
>> http://www.jacoco.org/jacoco/trunk/doc/ant.html ), "Merge" Maven Goal ( 
>> http://www.jacoco.org/jacoco/trunk/doc/merge-mojo.html ) and not yet 
>> released "Merge" command in command line interface ( 
>> http://www.jacoco.org/jacoco/trunk/doc/cli.html ).
>> All code of their implementation is available - 
>> https://github.com/jacoco/jacoco
>> Please note that execution data is merged only for the same classes ( 
>> http://www.jacoco.org/jacoco/trunk/doc/classids.html ), i.e. common 
>> classes used by your Application A and by Application B should be the same 
>> and exact same classes should be used during creation of a report.
>>
>> On Saturday, July 22, 2017 at 7:20:05 PM UTC+2, Andrew Iyer wrote:
>>>
>>>
>>> I have four applications that run using the same codebase.
>>>
>>> I have instrumented all of them successfully.
>>>
>>> The problem is that Application A uses half of the codebase of package 
>>> X, and Application B uses the *other* half of package X.
>>>
>>> So, for example, one Application will call the "initialize" function, 
>>> the other application will be sent this, say, and then call the "toString" 
>>> function to save it to a db.
>>>
>>> When I look at my jacoco report, given this pattern of usage, I see only 
>>> an average of 20% coverage, whereas I suspect the *actual* coverage is 
>>> closer to 60%.
>>>
>>> I'm using (pretty much, the code sample isn't complete but you get the 
>>> idea) the same code from here:
>>> https://stackoverflow.com/a/31250878/1061426
>>>
>>> thanks
>>>
>>

-- 
You received this message because you are subscribed to the Google Groups 
"JaCoCo and EclEmma Users" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
To view this discussion on the web visit 
https://groups.google.com/d/msgid/jacoco/faf632ab-4061-4701-acd9-cd44e41d216c%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

Reply via email to