I did this recently with Marc's solution, You don't need to change Jacoco itself, instead create session ids per test and dump the data.
Only limitation here with this solution is that we can't run tests in parallel. I'm not sure anyone has other solutions which can solve the parallel run problem. Thanks, Hunk On Wed, Sep 20, 2023 at 7:59 PM 'Lu Junliang' via JaCoCo and EclEmma Users < [email protected]> wrote: > Hi Hoffmann, > > Thank you for taking time to reply. i will try to develop on Eclipse. > > By the way, maybe i didn't explain "test case" clearly before. In my > project, test case are created and stored in automated testing platform, > which will be > used to do functional testing. > > when application run with jacoco agent, whether auto testing request from > quality assurance mates or regular request from others arrives will > change specific probes status, so i want to distinguish these request to > make auto testing coverage more credible. > > Thank you again for your reply > Best wishes > > On Thu, Sep 21, 2023 at 3:59 AM Marc Hoffmann <[email protected]> > wrote: > >> Hi junliang, >> >> while it should be possible to do JaCoCo development with IntelliJ the >> repository has all configuration files für Eclipse. So if you import the >> project into Eclipse with M2E installed everything should be set for >> development. >> >> JaCoCo is fully unit tested. So for every piece of code you can play with >> the respective tests to understand the behaviour. >> >> Also documentation contains some chapters about the architecture and some >> implementation details: >> >> * https://www.jacoco.org/jacoco/trunk/doc/implementation.html >> <https://urldefense.proofpoint.com/v2/url?u=https-3A__www.jacoco.org_jacoco_trunk_doc_implementation.html&d=DwMFaQ&c=R1GFtfTqKXCFH-lgEPXWwic6stQkW4U7uVq33mt-crw&r=HuYYfbK5_OTdgeAzuMSp99iGTWXW4X5RJzNePnT6ALU&m=g1r5XZFs8BCHySnPlPURil_PGWRDDGi8g1N0ITuvIfxpuL3eYhUNViMPRc44JWvS&s=DkTIUqRKD1AsDjyRoE-WUV53LciHfSaBAy5wdXUUuS4&e=> >> * https://www.jacoco.org/jacoco/trunk/doc/flow.html >> <https://urldefense.proofpoint.com/v2/url?u=https-3A__www.jacoco.org_jacoco_trunk_doc_flow.html&d=DwMFaQ&c=R1GFtfTqKXCFH-lgEPXWwic6stQkW4U7uVq33mt-crw&r=HuYYfbK5_OTdgeAzuMSp99iGTWXW4X5RJzNePnT6ALU&m=g1r5XZFs8BCHySnPlPURil_PGWRDDGi8g1N0ITuvIfxpuL3eYhUNViMPRc44JWvS&s=-BqdBNshROM9wevMGRW27aCU_Dq-kMkTCOg5L8m4jC8&e=> >> >> What you want to do has been implemented before without modifying JaCoCo: >> The approach was to hook into test framework (e.g. JUnit) and use JaCoCo’s >> runtime API to dump execution data after every test. Not that in any case >> the amount created data is enormous. >> >> Best regards, >> -marc >> >> >> >> On 20. Sep 2023, at 15:42, 'Lu Junliang' via JaCoCo and EclEmma Users < >> [email protected]> wrote: >> >> Hi guys, >> >> Before elobrating my question, please allow me introduce some background >> about my requirements >> >> i want to combine Jacoco coverage dections with test case in order to >> make testing more accurate. >> So I want to change one-dimensional boolean probes records to >> two-dimensional probes records, such as Map<String, boolean[]> , it can >> find the accurate >> test case which cover the code. >> >> i've clone jacoco from github to IDEA, how can i start to debug jacoco >> project and do some development? >> want to knows how probes init and insert, helping complete my >> requirements >> >> So any tips? >> >> Thx >> >> junliang >> >> >> -- >> 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/346fcc5b-b015-4509-ab7d-acaafa2b9efcn%40googlegroups.com >> <https://urldefense.proofpoint.com/v2/url?u=https-3A__groups.google.com_d_msgid_jacoco_346fcc5b-2Db015-2D4509-2Dab7d-2Dacaafa2b9efcn-2540googlegroups.com-3Futm-5Fmedium-3Demail-26utm-5Fsource-3Dfooter&d=DwMFaQ&c=R1GFtfTqKXCFH-lgEPXWwic6stQkW4U7uVq33mt-crw&r=HuYYfbK5_OTdgeAzuMSp99iGTWXW4X5RJzNePnT6ALU&m=g1r5XZFs8BCHySnPlPURil_PGWRDDGi8g1N0ITuvIfxpuL3eYhUNViMPRc44JWvS&s=KwT_tt4F0r0c9qe9ovewfL8MqRli4I-0U5998e4avAY&e=> >> . >> >> >> -- >> 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/guMiC5leLsc/unsubscribe >> <https://urldefense.proofpoint.com/v2/url?u=https-3A__groups.google.com_d_topic_jacoco_guMiC5leLsc_unsubscribe&d=DwMFaQ&c=R1GFtfTqKXCFH-lgEPXWwic6stQkW4U7uVq33mt-crw&r=HuYYfbK5_OTdgeAzuMSp99iGTWXW4X5RJzNePnT6ALU&m=g1r5XZFs8BCHySnPlPURil_PGWRDDGi8g1N0ITuvIfxpuL3eYhUNViMPRc44JWvS&s=AfAMFbkLy_WyBaQcKxzVGzNgo9A_RPwXNsRo_r2wKos&e=> >> . >> To unsubscribe from this group and all its topics, send an email to >> [email protected]. >> To view this discussion on the web visit >> https://groups.google.com/d/msgid/jacoco/6DD3CECC-25DF-42CF-8D67-0E56FF18D1B5%40mountainminds.com >> <https://urldefense.proofpoint.com/v2/url?u=https-3A__groups.google.com_d_msgid_jacoco_6DD3CECC-2D25DF-2D42CF-2D8D67-2D0E56FF18D1B5-2540mountainminds.com-3Futm-5Fmedium-3Demail-26utm-5Fsource-3Dfooter&d=DwMFaQ&c=R1GFtfTqKXCFH-lgEPXWwic6stQkW4U7uVq33mt-crw&r=HuYYfbK5_OTdgeAzuMSp99iGTWXW4X5RJzNePnT6ALU&m=g1r5XZFs8BCHySnPlPURil_PGWRDDGi8g1N0ITuvIfxpuL3eYhUNViMPRc44JWvS&s=nGt6aoWtu4GaELSkLQ92GF8iDRikFTxeUE0U8xrCbU8&e=> >> . >> > -- > 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/CA%2B_C4nyjNPHwZH76w%3DyLNb_y8MweJO%2BnOWmVLzRob4mZdCf3TA%40mail.gmail.com > <https://groups.google.com/d/msgid/jacoco/CA%2B_C4nyjNPHwZH76w%3DyLNb_y8MweJO%2BnOWmVLzRob4mZdCf3TA%40mail.gmail.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/CA%2BCrKLf1Uqf4xqMRi%3Dzz0LoKN36ZNy7-PC%2BdV%3DTmFo9TnXDtoA%40mail.gmail.com.
