« first day (4265 days earlier)      last day (906 days later) » 

10:00
Greetings everyone. Hope you're doing well. Has anyone ever integrated jacoco in an android project with/without hilt?
I have tried few workarounds, but all in vain
1
Q: Classes in bundle 'app' do not match with execution data - Android

NightFuryAlthough similar questions are already present on internet, but I am unable to find any proper solution to this problem. My project has multiple product flavors and uses kotlin and hilt. I believe this issue is only against kotlin byte code processed by Jacoco. Jacoco itself is now the part of gr...

10:36
Based on the quick browse, you have couple of options
What workarounds exist to deal with runtime-modified classes?
If classes get modified at runtime in your setup there are some workarounds to make JaCoCo work anyways:

If you use another Java agent make sure the JaCoCo agent is specified at first in the command line. This way the JaCoCo agent should see the original class files.
Specify the classdumpdir option of the JaCoCo agent and use the dumped classes at report generation. Note that only loaded classes will be dumped, i.e. classes not executed at all will not show-up in your report
Also there seems to be an easy fix here as well
https://github.com/google/dagger/issues/1982 (@see last comment)
Thanks for reply Ivan. Yes, I did found these but didn't understand the way to apply them to android gradle. Having access to jacoco agent is the key here, which currently seems missing to me.
Do you think Hilt modify original byte code with code generation?
@IvanMilisavljevic this answer is for android instrumentation unit tests
In a simple new android project with one kotlin class and unit test written against it. Jacoco is producing perfect code coverage report. There is something else which is causing turbulence I guess
Yeah from the stuff ive seen there seems to be a problem with AGP + Hilt
or in your case hilt specifically
I believe Hilt is doing some kind of transformations under the hood, but im not sure what kind
10:59
Thank you for the insight
 
5 hours later…
15:46
@Mauker THONK. WHAT? IS THAT A THING?
o/
dead room
hows it going Adam?
16:25
@AdamMc331 Yes 😃 Did it work?
@MwBakker It's thanks to bb's absence
 
5 hours later…
21:40
Next step, gradle text fixtures and adt with gradle managed devices
 
1 hour later…
22:43
@Mauker idk I already went with a different, much hackier solution, but I can try it to see.

« first day (4265 days earlier)      last day (906 days later) »