aboutsummaryrefslogtreecommitdiffstats
path: root/resources
diff options
context:
space:
mode:
authorVratko Polak <vrpolak@cisco.com>2020-08-06 10:32:46 +0200
committerVratko Polak <vrpolak@cisco.com>2020-08-06 10:32:46 +0200
commitd867f81c2f6c7fefecd52276ecc4deb330a01cbc (patch)
tree045ee5b971e54fcec5b0dd4607c7829dd7d47767 /resources
parent57b2c338b8295884a4fa9405b66c42e726b8b7d3 (diff)
Limit user triggers: no OR
To avoid runs such as: https://jenkins.fd.io/job/vpp-csit-verify-perf-master-3n-hsw/340/ Change-Id: I1b30d5f440ddf8ff32b11265b2ac2176f4b9a665 Signed-off-by: Vratko Polak <vrpolak@cisco.com>
Diffstat (limited to 'resources')
-rw-r--r--resources/libraries/bash/function/common.sh7
1 files changed, 7 insertions, 0 deletions
diff --git a/resources/libraries/bash/function/common.sh b/resources/libraries/bash/function/common.sh
index f724e53ea0..70ce91c0b7 100644
--- a/resources/libraries/bash/function/common.sh
+++ b/resources/libraries/bash/function/common.sh
@@ -911,6 +911,13 @@ function select_tags () {
warn "The following tag expression hints at bad trigger: ${tag}"
warn "Possible cause: Multiple triggers in a single comment."
die "Aborting to avoid triggering too many tests."
+ elif [[ "${tag}" == *"OR"* ]]; then
+ # If OR had higher precedence than AND, it would be useful here.
+ # Some people think it does, thus triggering way too much tests.
+ set -x
+ warn "The following tag expression hints at bad trigger: ${tag}"
+ warn "Operator OR has lower precedence than AND. Use space instead."
+ die "Aborting to avoid triggering too many tests."
elif [[ "${tag}" != "" && "${tag}" != "#"* ]]; then
# Empty and comment lines are skipped.
# Other lines are normal tags, they are to be prefixed.