-
Notifications
You must be signed in to change notification settings - Fork 6
/
build.gradle
60 lines (47 loc) · 1.32 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
apply plugin: "java"
repositories {
jcenter()
maven { url 'https://jitpack.io' }
}
task copyLibs(type: Copy) {
into "${buildDir}/libs"
from configurations.runtimeClasspath
exclude "sonar-*-plugin*.jar"
}
task copyTestLibs(type: Copy) {
into "${buildDir}/test"
from configurations.testRuntimeClasspath
}
task copyPlugins(type: Copy) {
into "${buildDir}/plugins"
from configurations.runtimeClasspath
include "sonar-*-plugin*.jar"
}
task copyRunnable(type: Copy) {
into "${buildDir}"
from "bin/codeclimate-sonar"
}
tasks.named("jar") {
dependsOn copyRunnable
}
tasks.named("compileTestJava") {
dependsOn copyRunnable
}
task infra(dependsOn: ["copyPlugins", "copyLibs", "copyTestLibs", "copyRunnable", "jar"])
build.dependsOn(infra)
test.dependsOn(infra)
dependencies {
implementation("com.github.codeclimate:codeclimate-ss-analyzer-wrapper:beta-SNAPSHOT")
// Plugins
implementation("org.sonarsource.java:sonar-java-plugin:6.15.1.26025")
testImplementation("org.assertj:assertj-core:2.8.0")
testImplementation("org.skyscreamer:jsonassert:1.5.0")
testImplementation("junit:junit:4.12")
}
test {
outputs.upToDateWhen { false }
testLogging {
events "passed", "skipped", "failed", "standardOut", "standardError"
exceptionFormat "full"
}
}