-
Notifications
You must be signed in to change notification settings - Fork 0
/
build.gradle
77 lines (62 loc) · 1.88 KB
/
build.gradle
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
plugins {
id 'java'
// Plugin which can update Gradle dependencies, use help/useLatestVersions
id 'se.patrikerdes.use-latest-versions' version '0.2.18'
id 'com.github.ben-manes.versions' version '0.42.0'
// Test coverage
id 'jacoco'
// Upload jacoco coverage reports to coveralls
id 'com.github.kt3k.coveralls' version '2.12.0'
// https://openjfx.io/openjfx-docs/#gradle
id 'org.openjfx.javafxplugin' version '0.0.13'
}
description = """
Gradle build file.
This uses the gradle wrapper, so when running (the first time) use 'gradlew test' so then it
downloads the right gradle automatically.
"""
repositories {
mavenCentral()
mavenLocal()
}
dependencies {
testImplementation 'org.junit.jupiter:junit-jupiter-api:5.9.0'
testRuntimeOnly 'org.junit.jupiter:junit-jupiter-engine:5.9.0'
// Needed for JavaFX tests.
testImplementation 'org.testfx:testfx-core:4.0.16-alpha'
testImplementation "org.testfx:testfx-junit:4.0.15-alpha"
// Only needed for headless testing.
// testCompile "org.testfx:openjfx-monocle:8u76-b04" // jdk-9+181 for Java 9
}
sourceSets {
main.java.srcDirs += 'src'
main.resources.srcDirs += 'src'
test.java.srcDirs += 'test'
test.resources.srcDirs += 'test'
}
// Java target version
sourceCompatibility = 1.8
targetCompatibility = 1.8
javafx {
version = "14"
modules = [ 'javafx.controls' ]
}
test {
// Enable JUnit 5 (Gradle 4.6+).
useJUnitPlatform()
// Always run tests, even when nothing changed.
dependsOn 'cleanTest'
// Show test results.
testLogging {
events "passed", "skipped", "failed"
}
}
// Test coverage reporting
jacocoTestReport {
// Enable xml for coveralls.
reports {
html.required.set(true)
xml.required.set(true)
xml.outputLocation.set(file("${buildDir}/reports/jacoco/test/jacocoTestReport.xml"))
}
}