X-Git-Url: https://gerrit.fd.io/r/gitweb?p=csit.git;a=blobdiff_plain;f=resources%2Flibraries%2Fbash%2Ffunction%2Fcommon.sh;fp=resources%2Flibraries%2Fbash%2Ffunction%2Fcommon.sh;h=2f15762da556fda341f772cd6fe537e2449a2fc3;hp=b827a054fb755783b16193e573f50d0cc9b52072;hb=e62ade12b7c9918cda2d363387ed0f517aa9840d;hpb=a33b52ae0f255021d89307ebc694f6e907906151 diff --git a/resources/libraries/bash/function/common.sh b/resources/libraries/bash/function/common.sh index b827a054fb..2f15762da5 100644 --- a/resources/libraries/bash/function/common.sh +++ b/resources/libraries/bash/function/common.sh @@ -291,11 +291,17 @@ function compose_pybot_arguments () { if [[ ${tag} == "!"* ]]; then EXPANDED_TAGS+=("--exclude" "${tag#$"!"}") else - EXPANDED_TAGS+=("${SELECTION_MODE}" "${tag}") + if [[ ${SELECTION_MODE} == "--test" ]]; then + EXPANDED_TAGS+=("--test" "${tag}") + else + EXPANDED_TAGS+=("--include" "${TOPOLOGIES_TAGS}AND${tag}") + fi fi done - EXPANDED_TAGS+=("--include" "${TOPOLOGIES_TAGS}") + if [[ ${SELECTION_MODE} == "--test" ]]; then + EXPANDED_TAGS+=("--include" "${TOPOLOGIES_TAGS}") + fi } @@ -1061,6 +1067,7 @@ function select_vpp_device_tags () { # If trigger contains tags, split them into array. test_tag_array=(${TEST_TAG_STRING//:/ }) fi + SELECTION_MODE="--include" ;; esac