- I have written some test cases under
androidTestdirectory. - I am using androidx (
testInstrumentationRunner "androidx.test.runner.AndroidJUnitRunner") added dependencies:
androidTestImplementation 'androidx.test:runner:1.1.0'androidTestImplementation 'androidx.test:rules:1.1.0'added JaCoCo as dependency, as well.
- When I run
createDebugAndroidTestCoverageReportGradle task, all the test cases run successfully but coverage is 0% in report
I am guessing that is due to this error:
V/InstrumentationResultParser: Error: Failed to generate Emma/JaCoCo coverage. V/InstrumentationResultParser: INSTRUMENTATION_CODE: -1
classDirectories; verify this once. - Martin Zeitler