forked from PegaSysEng/pantheon
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Jenkinsfile
88 lines (84 loc) · 3.37 KB
/
Jenkinsfile
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
#!/usr/bin/env groovy
if (env.BRANCH_NAME == "master") {
properties([
buildDiscarder(
logRotator(
daysToKeepStr: '90'
)
)
])
} else {
properties([
buildDiscarder(
logRotator(
numToKeepStr: '10'
)
)
])
}
stage('Pantheon tests') {
parallel javaTests: {
node {
checkout scm
docker.image('docker:18.06.0-ce-dind').withRun('--privileged') { d ->
docker.image('pegasyseng/pantheon-build:0.0.1').inside("--link ${d.id}:docker") {
try {
stage('Compile') {
sh './gradlew --no-daemon --parallel clean compileJava'
}
stage('compile tests') {
sh './gradlew --no-daemon --parallel compileTestJava'
}
stage('assemble') {
sh './gradlew --no-daemon --parallel assemble'
}
stage('Build') {
sh './gradlew --no-daemon --parallel build'
}
stage('Reference tests') {
sh './gradlew --no-daemon --parallel referenceTest'
}
stage('Integration Tests') {
sh './gradlew --no-daemon --parallel integrationTest'
}
stage('Acceptance Tests') {
sh './gradlew --no-daemon --parallel acceptanceTest --tests Web3Sha3AcceptanceTest --tests PantheonClusterAcceptanceTest --tests MiningAcceptanceTest'
}
stage('Check Licenses') {
sh './gradlew --no-daemon --parallel checkLicenses'
}
stage('Check javadoc') {
sh './gradlew --no-daemon --parallel javadoc'
}
stage('Jacoco root report') {
sh './gradlew --no-daemon jacocoRootReport'
}
} finally {
archiveArtifacts '**/build/reports/**'
archiveArtifacts '**/build/test-results/**'
archiveArtifacts 'build/reports/**'
archiveArtifacts 'build/distributions/**'
junit '**/build/test-results/**/*.xml'
}
}
}
}
}, quickstartTests: {
node {
checkout scm
docker.image('docker:18.06.0-ce-dind').withRun('--privileged') { d ->
docker.image('pegasyseng/pantheon-build:0.0.1').inside("--link ${d.id}:docker") {
try {
stage('Docker quickstart Tests') {
sh 'DOCKER_HOST=tcp://docker:2375 ./gradlew --no-daemon --parallel clean dockerQuickstartTest'
}
} finally {
archiveArtifacts '**/build/test-results/**'
archiveArtifacts '**/build/reports/**'
junit '**/build/test-results/**/*.xml'
}
}
}
}
}
}