0

I have a jacoco code coverage report which gets generated by using EclEmma plugin in eclipse , now i want to exclude some classes and packages from that report, is there a way i can exclude classes from that report.

Any help will be appeciated

Monis Majeed
  • 1,358
  • 14
  • 21

1 Answers1

0

If you have already constructed HTML report, then there is no easy way to exclude something from it.

Speaking about exclusion from the HTML report prior to its construction, let me quote an answer on another your question about exclusions in EclEmma:

Unfortunately currently EclEmma does not support exclusions from the report as stated in https://github.com/jacoco/eclemma/issues/84 (where by the way you received the same answer).

However, apart EclEmma there are plenty of other ways to use JaCoCo which allow exclusions - see for example documentation of Ant Tasks or Maven Plugin.

Community
  • 1
  • 1
Godin
  • 9,801
  • 2
  • 39
  • 76
  • finally i was able to solve , i agree EclEmma does not support exclusions, but yes there is way to exclude something from .exec file and not from html report – Monis Majeed Jan 11 '17 at 17:11
  • @MonisMajeed your question is about how to exclude from report, ".exec" file is not a report, so I don't see how exclusion "from .exec and not from html report" can be considered as answer ("solution") on your question ;) – Godin Jan 11 '17 at 17:35
  • @MonisMajeed moreover to be a good StackOverflow citizen: if you found a solution on your question, then please post it here or remove question completely – Godin Jan 11 '17 at 17:39
  • Yes my intention was to exclude the classes and get the actual coverage,So using EclEmma plugin in Eclipse, which gives us the report or exec file which doesn't have exclusion yet, so i take the exec file and used jacoco plugin in jenkin and gave the exclusion list there and re generated the report from exec file, which gives me the actual code coverage report with exclusion of classes/package as well – Monis Majeed Jan 12 '17 at 09:45