One more scenario: for unit test we use the mvn command line and jacoco-maven-plugin in pom.xml file. We do defined '<excludes>' in pom.xml, but it seemed to only affect the 'report' part; the generated .exec files were not affected. How can we include or exclude when dumping .exec files? I looked at the doc and seems prepare-agent can do this... is that true? If ture, where can I find some examples?
Thanks. --huafeng On Friday, November 15, 2019 at 8:17:48 PM UTC+8, [email protected] wrote: > > But maybe I can use 'includes' or 'excludes' when dumping so that A.exec > won't include infomation about B? > --huafeng > > On Friday, November 15, 2019 at 8:12:55 PM UTC+8, [email protected] wrote: >> >> For example, I have two modules A and B, and two exec files A.exec and >> B.exec. The problem is that, A.exec also contains some info about B, but >> when generating the report, I only want the info about B from B.exec. So I >> don't want to merge A.exec and B.exec. >> Any workaround? Thanks. >> --huafeng >> >> On Friday, November 15, 2019 at 7:35:13 PM UTC+8, Marc R. Hoffmann wrote: >>> >>> Hi Huafeng, >>> >>> no, this is not supported. >>> >>> Why can’t you provide all .exec files for the overall report? Due to >>> unique class ids used by JaCoCo only classes in the respective group will >>> pick-up their data. So there shouldn’t be a difference. >>> >>> Regards, >>> -marc >>> >>> >>> >>> On 15. Nov 2019, at 12:24, [email protected] wrote: >>> >>> Hi guys, >>> can I put the 'executiondata' elememt inside a 'group', as shown below? >>> I have different .exec files for different groups. >>> Ant complains 'group doesn't support the nested "executiondata" >>> element.' But is there a approach to use different .exec files for >>> different groups? I do need this badly. >>> >>> <target name="report"> >>> <jacoco:report> >>> <structure name="JaCoCo-Report"> >>> <group name="XXX-api"> >>> <executiondata> >>> <file file="${jacocoExecPath}/XXX-api.exec"/> >>> </executiondata> >>> <group name="XXX-component-1"> >>> <sourcefiles encoding="UTF-8"> >>> <fileset >>> dir="${classFilePath}/XXX/WEB-INF/classes"/> >>> </sourcefiles> >>> <classfiles> >>> <fileset >>> dir="${classFilePath}/XXX/WEB-INF/classes"/> >>> </classfiles> >>> </group> >>> ... >>> >>> Thanks! >>> --huafeng >>> >>> -- >>> 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/c13f4c95-1126-4b0e-84a1-6928ceb94349%40googlegroups.com >>> >>> <https://groups.google.com/d/msgid/jacoco/c13f4c95-1126-4b0e-84a1-6928ceb94349%40googlegroups.com?utm_medium=email&utm_source=footer> >>> . >>> >>> >>> -- 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/5f7e76b8-53bd-4bb3-ac39-132ea66033ff%40googlegroups.com.
