forked from jonathanhood/gradle-plugin-example
-
Notifications
You must be signed in to change notification settings - Fork 4
Expand file tree
/
Copy pathbuild.gradle
More file actions
47 lines (38 loc) · 1001 Bytes
/
Copy pathbuild.gradle
File metadata and controls
47 lines (38 loc) · 1001 Bytes
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
plugins {
id 'java-gradle-plugin'
id 'maven-publish'
id 'java'
}
group = artifact_group
version = "${artifact_version}.${build_number}"
repositories {
mavenCentral()
}
dependencies {
implementation gradleApi()
testImplementation(platform("org.junit:junit-bom:5.9.1"))
testImplementation("org.junit.jupiter:junit-jupiter")
}
test {
useJUnitPlatform()
}
test {
// Always run the tests
outputs.upToDateWhen { false }
// Turn on some console logging
testLogging {
events "passed", "skipped", "failed"
exceptionFormat "full"
stackTraceFilters "entryPoint"
}
}
// Write the plugin's classpath to a file to share with the tests
task createClasspathManifest {
def outputDir = file("$buildDir/$name")
inputs.files sourceSets.main.runtimeClasspath
outputs.dir outputDir
doLast {
outputDir.mkdirs()
file("$outputDir/plugin-classpath.txt").text = sourceSets.main.runtimeClasspath.join("\n")
}
}