e2eproject/success/Jenkinsfile
2020-02-19 17:25:25 +08:00

41 lines
560 B
Groovy

pipeline {
agent {
label 'maven'
}
options {
disableConcurrentBuilds()
}
stages{
stage('Build & Test'){
steps{
script{
container('java'){
sh 'mvn clean package test'
sleep time: 10, unit: 'MINUTES'
}
}
}
}
stage('Only for demo'){
when {
allOf {
branch 'master'
}
}
steps{
echo 'only for demo'
}
}
}
post{
always{
junit 'target/surefire-reports/**/*.xml'
}
}
}