Fine Tuning Reports

53 views
Skip to first unread message

joe.d...@gmail.com

unread,
Apr 1, 2014, 5:26:31 PM4/1/14
to jac...@googlegroups.com
Our functional testing is currently generating code coverage reports, for all our projects. Some of our code base contains auto-generated code. This generated code contains some lines of code that we cannot reach via our functional testing. We are looking for a way exclude those lines of code from our code coverage reports.
Any ideas would be greatly appreciated.

Marc R. Hoffmann

unread,
Apr 2, 2014, 12:21:46 AM4/2/14
to jac...@googlegroups.com
Hi,

filtering single lines from reports is currently not supported in
JaCoCo. Future versions of JaCoCo might provide diffeent kind of filters
to do so, we described use cases here:
https://github.com/jacoco/jacoco/wiki/FilteringOptions

Best regards,
-marc

joe.d...@gmail.com

unread,
Apr 2, 2014, 11:10:05 AM4/2/14
to jac...@googlegroups.com
We would happily implement our own filtering, is there a particular class we should be overriding or modifying?
The reporting examples perform three steps:
- loading the execution data
- analysis
- report generation

If there are particular source code patterns that we want to ignore, what class(es) should be modified to implement the ability to ignore that code.

Marc R. Hoffmann

unread,
Apr 2, 2014, 5:01:29 PM4/2/14
to jac...@googlegroups.com
Hi,

to be honest: If I could answer your questions filtering would have
already been implemented ;-)

JaCoCo does not process any source code, it only works on class files. I
would prefer to stick with this paradim also for filters.

Best regards,
-marc

Joe Damore

unread,
Apr 2, 2014, 5:14:23 PM4/2/14
to jac...@googlegroups.com

If we come up with anything,  I'll let you know.

--
You received this message because you are subscribed to a topic in the Google Groups "JaCoCo and EclEmma Users" group.
To unsubscribe from this topic, visit https://groups.google.com/d/topic/jacoco/9RNKpkcDO4E/unsubscribe.
To unsubscribe from this group and all its topics, send an email to jacoco+unsubscribe@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

joe.d...@gmail.com

unread,
Nov 12, 2014, 12:55:08 PM11/12/14
to jac...@googlegroups.com
We have been able to update the Line Counts in CoverageBuilder.visitCoverage
We use the coverage object to get the line counter, and increment accordingly. However in the html report the missed lines total is still unchanged, even though the the values for each row in the table is correct.
How are these totals generated?
Is there another counter to update.

Marc R. Hoffmann

unread,
Nov 13, 2014, 1:45:01 AM11/13/14
to jac...@googlegroups.com
All totals are created with the CoverageNodeImpl.increment() methods.

Regards,
-marc

Joe Damore

unread,
Nov 13, 2014, 1:10:59 PM11/13/14
to jac...@googlegroups.com
Thanks, we'll give it a try .

Joe Damore

unread,
Dec 1, 2014, 4:02:41 PM12/1/14
to jac...@googlegroups.com
In CoverageBuilder.visitCoverage( final IClassCoverage coverage )  , can I get access to CoverageNodeImpl ?

Marc Hoffmann

unread,
Dec 8, 2014, 2:43:13 AM12/8/14
to jac...@googlegroups.com
You can create a copy for your own purposes:

CoverageNodeImpl mynode = new
CoverageNodeImpl(coverage.getElementType(), coverage.getName());
mynode.increment(coverage);

Best regards,
-marc
> https://groups.google.com/d/topic/jacoco/9RNKpkcDO4E/unsubscribe [1].
> To unsubscribe from this group and all its topics, send an email to
> jacoco+un...@googlegroups.com.
> For more options, visit https://groups.google.com/d/optout [2].
>
> --
> 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 jacoco+un...@googlegroups.com.
> To view this discussion on the web visit
> https://groups.google.com/d/msgid/jacoco/CAD14M4jN8q-DxfEH0ppxgKnxLc%2B5Nx6UezdPRm52RxdSN%2BV%2Big%40mail.gmail.com
> [3].
> For more options, visit https://groups.google.com/d/optout [2].
>
>
> Links:
> ------
> [1] https://groups.google.com/d/topic/jacoco/9RNKpkcDO4E/unsubscribe
> [2] https://groups.google.com/d/optout
> [3]
> https://groups.google.com/d/msgid/jacoco/CAD14M4jN8q-DxfEH0ppxgKnxLc%2B5Nx6UezdPRm52RxdSN%2BV%2Big%40mail.gmail.com?utm_medium=email&utm_source=footer
Reply all
Reply to author
Forward
This conversation is locked
You cannot reply and perform actions on locked conversations.
0 new messages