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

jenkins triggeredby test

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