+# CSIT EXECUTION
+PYBOT_ARGS="--consolewidth 100 \
+ --loglevel TRACE \
+ --variable TOPOLOGY_PATH:${WORKING_TOPOLOGY} \
+ --suite tests.${DUT}.perf"
+
+case "$TEST_TAG" in
+ # select specific performance tests based on jenkins job type variable
+ PERFTEST_DAILY )
+ TAGS=('ndrdiscANDnic_intel-x520-da2AND1c'
+ 'ndrdiscANDnic_intel-x520-da2AND2c'
+ 'ndrpdrANDnic_intel-x520-da2AND1c'
+ 'ndrpdrANDnic_intel-x520-da2AND2c'
+ 'ndrdiscAND1cANDipsec'
+ 'ndrdiscAND2cANDipsec')
+ ;;
+ PERFTEST_SEMI_WEEKLY )
+ TAGS=('ndrdiscANDnic_intel-x710AND1c'
+ 'ndrdiscANDnic_intel-x710AND2c'
+ 'ndrdiscANDnic_intel-xl710AND1c'
+ 'ndrdiscANDnic_intel-xl710AND2c')
+ ;;
+ PERFTEST_MRR_DAILY )
+ TAGS=('mrrAND64bAND1c'
+ 'mrrAND64bAND2c'
+ 'mrrAND64bAND4c'
+ 'mrrAND78bAND1c'
+ 'mrrAND78bAND2c'
+ 'mrrAND78bAND4c'
+ 'mrrANDimixAND1cANDvhost'
+ 'mrrANDimixAND2cANDvhost'
+ 'mrrANDimixAND4cANDvhost'
+ 'mrrANDimixAND1cANDmemif'
+ 'mrrANDimixAND2cANDmemif'
+ 'mrrANDimixAND4cANDmemif')
+ ;;
+ VERIFY-PERF-PATCH )
+ if [[ -z "$TEST_TAG_STRING" ]]; then
+ # If nothing is specified, we will run pre-selected tests by
+ # following tags. Items of array will be concatenated by OR in Robot
+ # Framework.
+ TEST_TAG_ARRAY=('mrrANDnic_intel-x710AND1cAND64bANDip4base'
+ 'mrrANDnic_intel-x710AND1cAND78bANDip6base'
+ 'mrrANDnic_intel-x710AND1cAND64bANDl2bdbase')
+ else
+ # If trigger contains tags, split them into array.
+ TEST_TAG_ARRAY=(${TEST_TAG_STRING//:/ })
+ fi
+
+ TAGS=()
+
+ for TAG in "${TEST_TAG_ARRAY[@]}"; do
+ if [[ ${TAG} == "!"* ]]; then
+ # Exclude tags are not prefixed.
+ TAGS+=("${TAG}")
+ else
+ # We will prefix with perftest to prevent running other tests
+ # (e.g. Functional).
+ prefix="perftestAND"
+ if [[ ${JOB_NAME} == vpp-* ]] ; then
+ # Automatic prefixing for VPP jobs to limit the NIC used and
+ # traffic evaluation to MRR.
+ prefix="${prefix}mrrANDnic_intel-x710AND"
+ fi
+ TAGS+=("$prefix${TAG}")
+ fi
+ done
+ ;;
+ * )
+ TAGS=('perftest')
+esac
+
+# Catenate TAG selections
+EXPANDED_TAGS=()
+for TAG in "${TAGS[@]}"; do
+ if [[ ${TAG} == "!"* ]]; then
+ EXPANDED_TAGS+=(" --exclude ${TAG#$"!"} ")
+ else
+ EXPANDED_TAGS+=(" --include ${TOPOLOGIES_TAGS}AND${TAG} ")
+ fi
+done
+
+# Execute the test
+pybot ${PYBOT_ARGS}${EXPANDED_TAGS[@]} tests/
+RETURN_STATUS=$(echo $?)
+
+# Archive JOB artifacts in jenkins
+for i in ${JOB_ARCHIVE_ARTIFACTS[@]}; do
+ cp $( readlink -f ${i} | tr '\n' ' ' ) ${JOB_ARCHIVE_DIR}/
+done
+# Archive JOB artifacts to logs.fd.io
+for i in ${LOG_ARCHIVE_ARTIFACTS[@]}; do
+ cp $( readlink -f ${i} | tr '\n' ' ' ) ${LOG_ARCHIVE_DIR}/
+done
+
+exit ${RETURN_STATUS}