From 9a0b289ac4890afa6faf055cc9e5a151a0960df3 Mon Sep 17 00:00:00 2001 From: reinaortega <miguelangel.reinaortega@etsi.org> Date: Tue, 31 Aug 2021 09:41:25 +0200 Subject: [PATCH] Triggering CI/CD of Robot Hive Tap Test Tools project for 'plu' branches --- .jenkins.sh | 19 ++++++++++++++++++- 1 file changed, 18 insertions(+), 1 deletion(-) diff --git a/.jenkins.sh b/.jenkins.sh index ea4251e..528db63 100644 --- a/.jenkins.sh +++ b/.jenkins.sh @@ -9,7 +9,24 @@ cd "$(dirname "$0")" run_dir="$(pwd)" +echo "Using git branch $GIT_BRANCH" + ./scripts/build-container.sh ./scripts/run-container.sh "${run_dir}" -exit $? +if [[ "$GIT_BRANCH" =~ .*fix-plu$ ]]; then + + apiTestsVersion=$(echo $GIT_BRANCH | cut -d'/' -f 2) + apiTestsVersion=$(echo $apiTestsVersion | cut -d'-' -f 1) + echo apiTestsVersion + + curl -X POST \ + -F token=${ROBOT_HIVE_TAP_TT_TOKEN} \ + -F ref=master \ + -F "variables[API_TESTS_VERSION]=$apiTestsVersion" \ + -F "variables[TEST_SUITE]=MEC" \ + https://forge.etsi.org/rep/api/v4/projects/484/trigger/pipeline +fi +ret=$? +echo "Final validation result: $ret" +exit $ret -- GitLab