mirror of
https://github.com/kestra-io/kestra.git
synced 2025-12-19 18:05:41 -05:00
feat(test): add jacoco report
This commit is contained in:
36
build.gradle
36
build.gradle
@@ -57,6 +57,7 @@ allprojects {
|
|||||||
apply plugin:"java"
|
apply plugin:"java"
|
||||||
apply plugin:"net.ltgt.apt-eclipse"
|
apply plugin:"net.ltgt.apt-eclipse"
|
||||||
apply plugin:"net.ltgt.apt-idea"
|
apply plugin:"net.ltgt.apt-idea"
|
||||||
|
apply plugin: "jacoco"
|
||||||
|
|
||||||
// test
|
// test
|
||||||
apply plugin:"com.adarshr.test-logger"
|
apply plugin:"com.adarshr.test-logger"
|
||||||
@@ -150,4 +151,39 @@ jar {
|
|||||||
|
|
||||||
shadowJar {
|
shadowJar {
|
||||||
mergeServiceFiles()
|
mergeServiceFiles()
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
/**********************************************************************************************************************\
|
||||||
|
* Jacoco
|
||||||
|
**********************************************************************************************************************/
|
||||||
|
subprojects {
|
||||||
|
test {
|
||||||
|
finalizedBy jacocoTestReport
|
||||||
|
}
|
||||||
|
|
||||||
|
jacoco {
|
||||||
|
toolVersion = "0.8.4"
|
||||||
|
}
|
||||||
|
|
||||||
|
jacocoTestReport {
|
||||||
|
getAdditionalSourceDirs().setFrom(files(sourceSets.main.allSource.srcDirs))
|
||||||
|
getSourceDirectories().setFrom(files(sourceSets.main.allSource.srcDirs))
|
||||||
|
getClassDirectories().setFrom(files(sourceSets.main.output))
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
task jacoco(type: org.gradle.testing.jacoco.tasks.JacocoReport) {
|
||||||
|
dependsOn = subprojects.test
|
||||||
|
|
||||||
|
getAdditionalSourceDirs().setFrom(files(subprojects.sourceSets.main.allSource.srcDirs))
|
||||||
|
getSourceDirectories().setFrom(files(subprojects.sourceSets.main.allSource.srcDirs))
|
||||||
|
getClassDirectories().setFrom(files(subprojects.sourceSets.main.output))
|
||||||
|
getExecutionData().setFrom(files(subprojects.jacocoTestReport.executionData))
|
||||||
|
|
||||||
|
reports {
|
||||||
|
html.enabled = true
|
||||||
|
xml.enabled = true
|
||||||
|
csv.enabled = true
|
||||||
|
}
|
||||||
}
|
}
|
||||||
12
cli/src/test/java/org/floworc/cli/TodoTest.java
Normal file
12
cli/src/test/java/org/floworc/cli/TodoTest.java
Normal file
@@ -0,0 +1,12 @@
|
|||||||
|
package org.floworc.cli;
|
||||||
|
|
||||||
|
import org.junit.jupiter.api.Test;
|
||||||
|
|
||||||
|
import static org.junit.jupiter.api.Assertions.assertTrue;
|
||||||
|
|
||||||
|
class TodoTest {
|
||||||
|
@Test
|
||||||
|
void todo() {
|
||||||
|
assertTrue(true);
|
||||||
|
}
|
||||||
|
}
|
||||||
@@ -1,3 +1,4 @@
|
|||||||
|
config.stopBubbling = true
|
||||||
lombok.addLombokGeneratedAnnotation = true
|
lombok.addLombokGeneratedAnnotation = true
|
||||||
lombok.anyConstructor.addConstructorProperties = true
|
lombok.anyConstructor.addConstructorProperties = true
|
||||||
lombok.equalsAndHashCode.callSuper = call
|
lombok.equalsAndHashCode.callSuper = call
|
||||||
|
|||||||
Reference in New Issue
Block a user