Hi Sam,

AFAIK apk archive already contain dex files (not class files). JaCoCo only 
works in class files.

I think indeed with offline instrumentation it is possible to instrument class 
files before dex files and the apk are created. As I’m not a Android developer 
I can’t tell you details about the setup. A quick google search results in 
several blogs from people who use JaCoCo for Android.

Regards,
-marc



> On 14. Jan 2020, at 19:22, [email protected] wrote:
> 
> The testing tool only uses the android apk, not the source code. Can I still 
> use the Java agent? If so, how do I instrument the apk using Java agent? 
> Is there any sample project available that used java agent to instrument the 
> apk? I am really sorry if I am asking dumb questions.
> 
> Regards,
> Sam  
> 
> On Monday, January 13, 2020 at 11:20:26 PM UTC-6, Marc R. Hoffmann wrote:
> Hi,
> 
> why do you think you need offline instrumentation? Using the JaCoCo Java 
> agent is very convenient and documented here:
> 
> https://www.jacoco.org/jacoco/trunk/doc/agent.html 
> <https://www.jacoco.org/jacoco/trunk/doc/agent.html>
> 
> Regards,
> -marc
> 
>> On 14. Jan 2020, at 01:05, [email protected] <javascript:> wrote:
>> 
>> Dear All,
>> 
>> I am trying to use JaCoCo to measure the coverage achieved by an automated 
>> testing tool that uses appium and python. 
>> I checked the JaCoCo official webpage for offline instrumentation but didn't 
>> understand the process properly. I would be really grateful if someone can 
>> give a step by step procedure to do the JaCoCo offline instrumentation in 
>> Android. 
>> A blog post on this topic would be really helpful to the new users.
>> 
>> Thank you!
>> 
>> 
>> 
>> -- 
>> 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] <javascript:>.
>> To view this discussion on the web visit 
>> https://groups.google.com/d/msgid/jacoco/142163e8-fe60-4a0a-8f41-e186ee1c51d8%40googlegroups.com
>>  
>> <https://groups.google.com/d/msgid/jacoco/142163e8-fe60-4a0a-8f41-e186ee1c51d8%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] 
> <mailto:[email protected]>.
> To view this discussion on the web visit 
> https://groups.google.com/d/msgid/jacoco/5113efe9-9b9e-4ef3-b519-6ef6588820cf%40googlegroups.com
>  
> <https://groups.google.com/d/msgid/jacoco/5113efe9-9b9e-4ef3-b519-6ef6588820cf%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/49B6654A-9B05-465A-8897-0A101DF33EA8%40mountainminds.com.

Reply via email to