Fixed
Status Update
Comments
tn...@google.com <tn...@google.com> #2
can you share your android studio version
st...@gmail.com <st...@gmail.com> #3
Is this happening with Studio 3.0?
al...@google.com <al...@google.com> #4
Note: This worked for me on Windows 7 Pro 32-bit (with Android Studio 2.3.3). Seems like an issue with adt-branding module (which should contain the "/idea/AndroidStudioApplicationInfo.xml" resource).
xa...@android.com <xa...@android.com> #5
Hi, also happened on Mac Book Pro 15 retina mi-2015
MacOs Sierra 10.12.6
Android Studio 2.3.3
java version "1.8.0_51"
Java(TM) SE Runtime Environment (build 1.8.0_51-b16)
Java HotSpot(TM) 64-Bit Server VM (build 25.51-b03, mixed mode)
MacOs Sierra 10.12.6
Android Studio 2.3.3
java version "1.8.0_51"
Java(TM) SE Runtime Environment (build 1.8.0_51-b16)
Java HotSpot(TM) 64-Bit Server VM (build 25.51-b03, mixed mode)
st...@gmail.com <st...@gmail.com> #6
Thank you for this feedback. Your feedback helps make sure Android development tools are great! Given your issues has been resolved I am closing this issue.
xa...@android.com <xa...@android.com> #7
Thanks for the pointer.
[Deleted User] <[Deleted User]> #8
Please supported Jacoco as soon as possibile.
wi...@gmail.com <wi...@gmail.com> #9
[Comment deleted]
wi...@gmail.com <wi...@gmail.com> #10
At this point any code coverage tool for android that integrates nicely with Android & gradle would be a plus (eg instrumented emulator tests).
Any chance of a rough timeframe?
Any chance of a rough timeframe?
ma...@bootstraponline.com <ma...@bootstraponline.com> #11
Jacoco support would be very helpful. The workaround of using ant via Gradle isn't great.
https://github.com/skyisle/gradle-jacoco-android
kr...@gmail.com <kr...@gmail.com> #12
Please add some sort of code coverage support.
mb...@gmail.com <mb...@gmail.com> #13
Please add jacoco or emma support on gradle builds.
If it is already present, please share the documentation link.
If it is already present, please share the documentation link.
di...@gmail.com <di...@gmail.com> #14
xavier just mentioned that the 0.10 of gradle-android plugin will have jacoco support, he just implemented it. (see https://groups.google.com/forum/#!topic/adt-dev/xr7hnrHKYmI )
st...@gmail.com <st...@gmail.com> #15
wi...@gmail.com <wi...@gmail.com> #16
Woop. We can finally drop our Gradle-Ant-Groovy script behemoth.
re...@netmoms.de <re...@netmoms.de> #17
Indeed great! So we can use it now? Or are more changes required by Google?
If we can use it right now, is there any tutorial how to use it? I'm not very familar with code coverage.
If we can use it right now, is there any tutorial how to use it? I'm not very familar with code coverage.
aa...@gmail.com <aa...@gmail.com> #18
From Xavier : "The code is here: https://android-review.googlesource.com/#/c/91712 and this will be part of the plugin version 0.10." So to use it now you'll have to build a custom version of the build tools.
wi...@gmail.com <wi...@gmail.com> #19
Do we have a rough ETA on when v0.10 will go live?
an...@gmail.com <an...@gmail.com> #22
Thanks for this feature, it's very helpful indeed.
Can we have a short demo of how to apply this feature properly? I've just tried to enable code coverage in one of my projects following the guide in release notes and it didn't work for me. I created a question on Stackoverflow describing the errors I get:http://stackoverflow.com/questions/23403092/java-lang-verifyerror-when-running-android-tests-with-testcoverageenabled-true
Thank you.
Can we have a short demo of how to apply this feature properly? I've just tried to enable code coverage in one of my projects following the guide in release notes and it didn't work for me. I created a question on Stackoverflow describing the errors I get:
Thank you.
xa...@android.com <xa...@android.com> #23
For those reading this, it's currently not compatible with Dagger. We'll investigate this shortly.
You can track the issue here:https://code.google.com/p/android/issues/detail?id=69174
You can track the issue here:
sa...@gmail.com <sa...@gmail.com> #24
Hi,
I also tried the similar approach for my library project. I used gradle 1.10+ and latest SDK tool and Android Studio.
testCoverageEnabled = true for the debug build version
When I am running the tests through the terminal, I am getting the report of the test results but the testCoverage report is not being generated.
Kindly let me know if anything else needs to be done.
Thanks and Warm Regards,
sachin
I also tried the similar approach for my library project. I used gradle 1.10+ and latest SDK tool and Android Studio.
testCoverageEnabled = true for the debug build version
When I am running the tests through the terminal, I am getting the report of the test results but the testCoverage report is not being generated.
Kindly let me know if anything else needs to be done.
Thanks and Warm Regards,
sachin
ku...@gmail.com <ku...@gmail.com> #25
I try Jacoco integration on latest Android api21,
latest build tools 21.0.1,
latest Android Studio 0.8.13 and
latest gradle plugin 0.13.+ -
Summary: integration does not work! Emulator all the time return exception:
10-19 11:45:43.887 2320-2333/? E/InstrumentationTestRunner﹕ Failed to generate emma coverage.
java.lang.reflect.InvocationTargetException
at java.lang.reflect.Method.invokeNative(Native Method)
at java.lang.reflect.Method.invoke(Method.java:515)
at android.test.InstrumentationTestRunner.generateCoverageReport(InstrumentationTestRunner.java:607)
at android.test.InstrumentationTestRunner.onStart(InstrumentationTestRunner.java:570)
at com.google.android.apps.common.testing.testrunner.GoogleInstrumentationTestRunner.onStart(GoogleInstrumentationTestRunner.java:167)
at android.app.Instrumentation$InstrumentationThread.run(Instrumentation.java:1701)
Caused by: java.lang.IllegalStateException: JaCoCo agent not started.
at org.jacoco.agent.rt.internal_e6e56f0.Agent.getInstance(Agent.java:72)
at org.jacoco.agent.rt.RT.getAgent(RT.java:32)
at com.vladium.emma.rt.RT.dumpCoverageData(RT.java:52)
at java.lang.reflect.Method.invokeNative(Native Method)
at java.lang.reflect.Method.invoke(Method.java:515)
at android.test.InstrumentationTestRunner.generateCoverageReport(InstrumentationTestRunner.java:607)
at android.test.InstrumentationTestRunner.onStart(InstrumentationTestRunner.java:570)
at com.google.android.apps.common.testing.testrunner.GoogleInstrumentationTestRunner.onStart(GoogleInstrumentationTestRunner.java:167)
at android.app.Instrumentation$InstrumentationThread.run(Instrumentation.java:1701)
Anyone can provide a working example of code coverage with JaCoCo?
latest build tools 21.0.1,
latest Android Studio 0.8.13 and
latest gradle plugin 0.13.+ -
Summary: integration does not work! Emulator all the time return exception:
10-19 11:45:43.887 2320-2333/? E/InstrumentationTestRunner﹕ Failed to generate emma coverage.
java.lang.reflect.InvocationTargetException
at java.lang.reflect.Method.invokeNative(Native Method)
at java.lang.reflect.Method.invoke(Method.java:515)
at android.test.InstrumentationTestRunner.generateCoverageReport(InstrumentationTestRunner.java:607)
at android.test.InstrumentationTestRunner.onStart(InstrumentationTestRunner.java:570)
at com.google.android.apps.common.testing.testrunner.GoogleInstrumentationTestRunner.onStart(GoogleInstrumentationTestRunner.java:167)
at android.app.Instrumentation$InstrumentationThread.run(Instrumentation.java:1701)
Caused by: java.lang.IllegalStateException: JaCoCo agent not started.
at org.jacoco.agent.rt.internal_e6e56f0.Agent.getInstance(Agent.java:72)
at org.jacoco.agent.rt.RT.getAgent(RT.java:32)
at com.vladium.emma.rt.RT.dumpCoverageData(RT.java:52)
at java.lang.reflect.Method.invokeNative(Native Method)
at java.lang.reflect.Method.invoke(Method.java:515)
at android.test.InstrumentationTestRunner.generateCoverageReport(InstrumentationTestRunner.java:607)
at android.test.InstrumentationTestRunner.onStart(InstrumentationTestRunner.java:570)
at com.google.android.apps.common.testing.testrunner.GoogleInstrumentationTestRunner.onStart(GoogleInstrumentationTestRunner.java:167)
at android.app.Instrumentation$InstrumentationThread.run(Instrumentation.java:1701)
Anyone can provide a working example of code coverage with JaCoCo?
xa...@android.com <xa...@android.com> #26
We haven't tested with the GoogleInstrumentationTestRunner. It's possible there's a problem there.
I've open Issue 36949180 to track this.
I've open
ku...@gmail.com <ku...@gmail.com> #27
Original InstrumentationTestRunner in use:
/* default unit testing runner */
testInstrumentationRunner "android.test.InstrumentationTestRunner"
Results are the same:
10-22 03:58:46.517 2016-2030/com.artfulbits.benchmark.sample E/InstrumentationTestRunner﹕ Failed to generate emma coverage.
java.lang.reflect.InvocationTargetException
at java.lang.reflect.Method.invokeNative(Native Method)
at java.lang.reflect.Method.invoke(Method.java:515)
at android.test.InstrumentationTestRunner.generateCoverageReport(InstrumentationTestRunner.java:607)
at android.test.InstrumentationTestRunner.onStart(InstrumentationTestRunner.java:570)
at android.app.Instrumentation$InstrumentationThread.run(Instrumentation.java:1701)
Caused by: java.lang.IllegalStateException: JaCoCo agent not started.
at org.jacoco.agent.rt.internal_932a715.Agent.getInstance(Agent.java:72)
at org.jacoco.agent.rt.RT.getAgent(RT.java:32)
at com.vladium.emma.rt.RT.dumpCoverageData(RT.java:52)
at java.lang.reflect.Method.invokeNative(Native Method)
at java.lang.reflect.Method.invoke(Method.java:515)
at android.test.InstrumentationTestRunner.generateCoverageReport(InstrumentationTestRunner.java:607)
at android.test.InstrumentationTestRunner.onStart(InstrumentationTestRunner.java:570)
at android.app.Instrumentation$InstrumentationThread.run(Instrumentation.java:1701)
For execution tests with JaCoCo I use command line gradlew:
> gradlew connectedCheck createDebugCoverageReport
Can you provide link on project on which you test JaCoCo integration? Want to compare gradle build files.
Are you using "jacoco gradle plugin?" in build file?
I try to enable code coverage on this simple project:https://github.com/OleksandrKucherenko/meter
/* default unit testing runner */
testInstrumentationRunner "android.test.InstrumentationTestRunner"
Results are the same:
10-22 03:58:46.517 2016-2030/com.artfulbits.benchmark.sample E/InstrumentationTestRunner﹕ Failed to generate emma coverage.
java.lang.reflect.InvocationTargetException
at java.lang.reflect.Method.invokeNative(Native Method)
at java.lang.reflect.Method.invoke(Method.java:515)
at android.test.InstrumentationTestRunner.generateCoverageReport(InstrumentationTestRunner.java:607)
at android.test.InstrumentationTestRunner.onStart(InstrumentationTestRunner.java:570)
at android.app.Instrumentation$InstrumentationThread.run(Instrumentation.java:1701)
Caused by: java.lang.IllegalStateException: JaCoCo agent not started.
at org.jacoco.agent.rt.internal_932a715.Agent.getInstance(Agent.java:72)
at org.jacoco.agent.rt.RT.getAgent(RT.java:32)
at com.vladium.emma.rt.RT.dumpCoverageData(RT.java:52)
at java.lang.reflect.Method.invokeNative(Native Method)
at java.lang.reflect.Method.invoke(Method.java:515)
at android.test.InstrumentationTestRunner.generateCoverageReport(InstrumentationTestRunner.java:607)
at android.test.InstrumentationTestRunner.onStart(InstrumentationTestRunner.java:570)
at android.app.Instrumentation$InstrumentationThread.run(Instrumentation.java:1701)
For execution tests with JaCoCo I use command line gradlew:
> gradlew connectedCheck createDebugCoverageReport
Can you provide link on project on which you test JaCoCo integration? Want to compare gradle build files.
Are you using "jacoco gradle plugin?" in build file?
I try to enable code coverage on this simple project:
xa...@android.com <xa...@android.com> #28
the "basic" project in our samples has test coverage enabled. you only need to run "connectedCheck" it'll do everything needed.
Description
If it is there, then I would like to request some docs. :)
If it is still a roadmap item, then this issue can be used to get notified when it in implemented.