}
compileTestJava {
- if (clover) {
+
+ if (use_clover) {
dependsOn compileCloverJava
classpath += configurations.cloverRuntime
+ } else {
+ classpath += sourceSets.main.runtimeClasspath
}
doFirst {
- if (JAVA_VERSION.equals("1.8")) {
- sourceCompatibility = 1.8
- targetCompatibility = 1.8
- } else if (JAVA_VERSION.equals("11")) {
- sourceCompatibility = 11
- targetCompatibility = 11
-
- options.compilerArgs = [
- '--module-path', sourceSets.modules.compileClasspath.asPath,
- '--add-modules', j11modules
- ]
- }
+ sourceCompatibility = compile_source_compatibility
+ targetCompatibility = compile_target_compatibility
+ options.compilerArgs = additional_compiler_args
print ("Setting target compatibility to "+targetCompatibility+"\n")
}
}