Skip to content
Snippets Groups Projects
Commit 43b601c4 authored by OZGCloud's avatar OZGCloud
Browse files

jenkins triggeredby test

parent 9e67fa1d
No related branches found
No related tags found
No related merge requests found
......@@ -54,20 +54,51 @@ pipeline {
// }
// }
// }
stage('Check branch') {
// stage('Check branch') {
// when {
// anyOf {
// triggeredBy 'CronCause'
// triggeredBy 'TimerTrigger'
// }
// }
// steps {
// script {
// if (!isMasterBranch()) {
// echo "Branchname "+env.BRANCH_NAME+" does not match, skipping e2e tests"
// SKIP_RUN = true
// }
// }
// }
// }
stage('TimerTrigger') {
when {
triggeredBy 'TimerTrigger'
}
steps {
script {
if (!isMasterBranch()) {
echo "Branchname "+env.BRANCH_NAME+" does not match, skipping e2e tests"
SKIP_RUN = true
echo "TimerTrigger"
}
}
stage('UserIdCause') {
when {
triggeredBy cause: 'UserIdCause'
}
steps {
echo "UserIdCause"
}
}
stage('When not anyOf') {
when {
not {
anyOf {
triggeredBy 'UpstreamCause'
triggeredBy 'BuildUpstreamCause'
triggeredBy cause: 'UserIdCause'
triggeredBy 'TimerTrigger'
}
}
}
steps {
echo "When not anyOf"
}
}
stage('Checkout SCM') {
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment