Remove unnecessary libs from testSets test classpath
MODIFY
gradle/instrumentation.gradle
gradle/instrumentation.gradle
@@ -108,6 +108,8 @@ shadowJar {
evaluationDependsOn(":testing:agent-for-testing")
+// need to run this after evaluate because testSets plugin adds new test tasks
+afterEvaluate {
tasks.withType(Test).configureEach {
inputs.file(shadowJar.archiveFile)
@@ -142,6 +144,7 @@ tasks.withType(Test).configureEach {
return true
}
}
+}
configurations.configureEach {
if (it.name.toLowerCase().endsWith('testruntimeclasspath')) {

Remove unnecessary libs from testSets test classpath (#2654)