-
Notifications
You must be signed in to change notification settings - Fork 50
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Issue using com.bmuschko.clover plugin for Android lib (gradle, java) #157
Comments
Android plugin has caused issues with this plugin before. I have been unable to test and understand the issues. Something unusual with the way the Android tooling sets up the source sets or the tasks causes an unexpected null pointer exception. I thought I had added some defensive logic to correct the NPE although I cannot recall when that was done. |
I think I remember a situation that was caused by the Android tools setting the testClassesDirs property of the test task to null which is an invalid value when it should be a collection reference. But I do not have time or a way to test as I am not an Android developer myself. |
Hi,
Gradle 6.9.1 (gradle wrapper)
After adding plugin to plugins section
id 'com.bmuschko.clover' version '3.0.1' apply true
I have an error with stack trace at the end
I tried to check plugin code, but don't understand reason, because of the code:
with such result:
Stack trace:
A problem occurred configuring project ':lib'.
Caused by: java.lang.RuntimeException: org.gradle.api.internal.tasks.DefaultTaskContainer$TaskCreationException: Could not create task ':lib:testDebugUnitTest'.
Caused by: org.gradle.api.internal.tasks.DefaultTaskContainer$TaskCreationException: Could not create task ':lib:testDebugUnitTest'.
Caused by: org.gradle.api.internal.tasks.DefaultTaskContainer$TaskCreationException: Could not create task ':lib:cloverInstrumentCodeForTestDebugUnitTest'.
at com.bmuschko.gradle.clover.CloverPlugin.configureActionsForTask(CloverPlugin.groovy:114)
at com.bmuschko.gradle.clover.CloverPlugin$_configureActions_closure2.doCall(CloverPlugin.groovy:92)
Caused by: org.gradle.api.tasks.TaskInstantiationException: Could not create task of type 'CloverInstrumentationTask'
Caused by: java.lang.NullPointerException
at com.bmuschko.gradle.clover.CloverInstrumentationTask.(CloverInstrumentationTask.groovy:39)
The text was updated successfully, but these errors were encountered: