parent
5471f6521c
commit
fceadf2d13
|
@ -17,6 +17,7 @@ pipeline {
|
||||||
DOCKER = credentials('dockerhub-upboundci')
|
DOCKER = credentials('dockerhub-upboundci')
|
||||||
AWS = credentials('aws-upbound-bot')
|
AWS = credentials('aws-upbound-bot')
|
||||||
GITHUB_UPBOUND_BOT = credentials('github-upbound-jenkins')
|
GITHUB_UPBOUND_BOT = credentials('github-upbound-jenkins')
|
||||||
|
CODECOV_TOKEN = credentials('codecov-crossplane-runtime')
|
||||||
}
|
}
|
||||||
|
|
||||||
stages {
|
stages {
|
||||||
|
@ -95,37 +96,17 @@ pipeline {
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
stage('Record Coverage') {
|
stage('Publish Coverage to Codecov') {
|
||||||
when {
|
when {
|
||||||
allOf {
|
expression {
|
||||||
branch 'master';
|
return env.shouldBuild != "false"
|
||||||
expression {
|
|
||||||
return env.shouldBuild != "false"
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
steps {
|
steps {
|
||||||
script {
|
script {
|
||||||
currentBuild.result = 'SUCCESS'
|
sh 'curl -s https://codecov.io/bash | bash -s -- -c -f _output/tests/**/coverage.txt -F unittests'
|
||||||
}
|
|
||||||
step([$class: 'MasterCoverageAction', scmVars: [GIT_URL: env.GIT_URL]])
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
stage('PR Coverage to Github') {
|
|
||||||
when {
|
|
||||||
allOf {
|
|
||||||
not { branch 'master' };
|
|
||||||
expression { return env.CHANGE_ID != null };
|
|
||||||
expression { return env.shouldBuild != "false"}
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
steps {
|
|
||||||
script {
|
|
||||||
currentBuild.result = 'SUCCESS'
|
|
||||||
}
|
|
||||||
step([$class: 'CompareCoverageAction', publishResultAs: 'comment', scmVars: [GIT_URL: env.GIT_URL]])
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue