forked from bmanley91/gradle-cucumber-jvm-plugin
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathbuild.gradle
110 lines (90 loc) · 2.54 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
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
plugins {
id 'groovy'
id 'codenarc'
id 'net.saliman.cobertura' version '2.2.8'
id 'idea'
id 'maven-publish'
id 'net.researchgate.release' version '2.1.2'
id "com.jfrog.bintray" version "1.2"
id 'nebula.integtest' version '3.0.3'
}
sourceCompatibility = 1.7
targetCompatibility = 1.7
repositories {
maven {
url "http://repo.bodar.com"
}
jcenter()
}
dependencies {
compile gradleApi()
compile 'org.codehaus.gpars:gpars:1.2.1'
compile 'org.zeroturnaround:zt-exec:1.8'
compile 'net.masterthought:cucumber-reporting:0.6.0'
//testCompile 'org.spockframework:spock-core:0.7-groovy-2.0'
testCompile 'com.netflix.nebula:nebula-test:3.1.0'
//intTestCompile 'org.spockframework:spock-core:0.7-groovy-2.0'
integTestCompile 'com.netflix.nebula:nebula-test:3.1.0'
}
sourceSets {
test {
//remove incompatible jar from test class path
runtimeClasspath = runtimeClasspath.minus files("$gradle.gradleHomeDir/lib/commons-io-1.4.jar")
}
}
codenarc {
configFile = rootProject.file('codenarcrule.groovy')
reportFormat = System.properties['codeNarcOutput'] ?: 'html'
}
cobertura {
coverageIgnoreTrivial = true
auxiliaryClasspath += project.sourceSets.main.runtimeClasspath
}
test {
finalizedBy coberturaReport
}
integrationTest {
finalizedBy coberturaReport
}
task sourcesJar(type: Jar, dependsOn: classes) {
classifier = 'sources'
from sourceSets.main.allSource
}
task javadocJar(type: Jar, dependsOn: javadoc) {
classifier = 'javadoc'
from javadoc.destinationDir
}
// add javadoc/source jar tasks as artifacts
artifacts {
archives sourcesJar, javadocJar
}
publishing {
publications {
mavenJava(MavenPublication) {
from components.java
artifact sourcesJar {
classifier "sources"
}
artifact javadocJar {
classifier "javadoc"
}
pom.withXml {
def Node root = asNode()
}
}
}
}
bintray {
user = project.hasProperty("bintrayUserName") ? bintrayUserName : null
key = project.hasProperty("bintrayApiKey") ? bintrayApiKey : null
publications = ["mavenJava"]
pkg {
repo = "main"
userOrg = "commercehub-oss"
name = 'gradle-cucumber-jvm-plugin'
licenses = ["Apache-2.0"]
vcsUrl = 'https://github.com/commercehub-oss/gradle-cucumber-jvm-plugin'
}
}
bintrayUpload.dependsOn build, sourcesJar, javadocJar
createReleaseTag.dependsOn bintrayUpload