def cloverInstrDir = file("$buildDir/$cloverSourcesInstrDir")
def classes = "$jalviewDir/$classesDir"
if (clover.equals("true")) {
- clover = true
+ use_clover = true
classes = "$buildDir/$cloverClassesDir"
} else {
- clover = false
+ use_clover = false
classes = "$jalviewDir/$classesDir"
}
}
compileClasspath = files( sourceSets.test.java.outputDir )
- if (clover) {
+ if (use_clover) {
compileClasspath += sourceSets.clover.compileClasspath
} else {
compileClasspath += sourceSets.main.compileClasspath
+ compileClasspath += files(sourceSets.main.java.outputDir)
}
compileClasspath += files( sourceSets.main.resources.srcDirs)
compileClasspath += fileTree(dir: "$jalviewDir/$utilsDir", include: ["**/*.jar"])
// clover bits
dependencies {
- if (clover) {
+ if (use_clover) {
cloverCompile 'org.openclover:clover:4.3.1'
testCompile 'org.openclover:clover:4.3.1'
}
}
compileTestJava {
- if (clover) {
+
+ if (use_clover) {
dependsOn compileCloverJava
classpath += configurations.cloverRuntime
+ } else {
+ classpath += sourceSets.main.runtimeClasspath
}
doFirst {
if (JAVA_VERSION.equals("1.8")) {
//testReportDirName = "test-reports" // note that test workingDir will be $jalviewDir
test {
dependsOn prepare
- if (clover) {
+ dependsOn compileJava
+ if (use_clover) {
dependsOn cloverInstr
}
- print("Running tests " + (clover?"WITH":"WITHOUT") + " clover [clover="+clover+"]\n")
+ print("Running tests " + (use_clover?"WITH":"WITHOUT") + " clover [clover="+use_clover+"]\n")
useTestNG() {
includeGroups testngGroups