minor fixes for spm repo

following fixes done
  - update run_local_ci script to include spm config
  - remove non-existent tftf-l1-spm test from tftf group

Signed-off-by: Manish Pandey <manish.pandey2@arm.com>
Change-Id: Ie5048237bc80af4b123786d83406578a87ac2478
Signed-off-by: Leonardo Sandoval <leonardo.sandoval@linaro.org>
diff --git a/script/clone_repos.sh b/script/clone_repos.sh
index e05dba5..0f0b3bc 100755
--- a/script/clone_repos.sh
+++ b/script/clone_repos.sh
@@ -405,7 +405,7 @@
 	# Clone Trusted Firmware TF repository
 	url="$tftf_src_repo_url" name="trusted-firmware-tf" ref="TFTF_REFSPEC" \
 		loc="TFTF_CHECKOUT_LOC" \
-		gerrit_test_groups="tftf-l1-build tftf-l1-fvp tftf-l1-spm" \
+		gerrit_test_groups="tftf-l1-build tftf-l1-fvp" \
 		clone_and_sync
 fi
 
diff --git a/script/run_local_ci.sh b/script/run_local_ci.sh
index 857355a..248d338 100755
--- a/script/run_local_ci.sh
+++ b/script/run_local_ci.sh
@@ -250,13 +250,20 @@
     tftf_config="${tftf_config:-nil}"
     scp_config="${scp_config:-nil}"
     scp_tools="${scp_tools:-nil}"
+    spm_config="${spm_config:-nil}"
     run_config="${run_config:-nil}"
 
-    # constuct the 'long form' so it takes into account all possible configurations
-    tg=$(printf "%s/%s,%s,%s,%s:%s" "${test_group}" "${tf_config}" "${tftf_config}" "${scp_config}" "${scp_tools}" "${run_config}")
+    # construct the 'long form' so it takes into account all possible configurations
+    if echo ${test_group} | grep -q 'scp-'; then
+	tg=$(printf "%s/%s,%s,%s,%s:%s" "${test_group}" "${scp_config}" "${tf_config}" "${tftf_config}" "${scp_tools}" "${run_config}")
+    elif echo ${test_group} | grep -q 'spm-'; then
+	tg=$(printf "%s/%s,%s,%s,%s,%s:%s" "${test_group}" "${spm_config}" "${tf_config}" "${tftf_config}" "${scp_config}" "${scp_tools}" "${run_config}")
+    else
+	tg=$(printf "%s/%s,%s,%s,%s,%s:%s" "${test_group}" "${tf_config}" "${tftf_config}" "${scp_config}" "${scp_tools}" "${spm_config}" "${run_config}")
+    fi
 
     # trim any ',nil:' from it
-    tg="${tg/,nil:/:}" tg="${tg/,nil:/:}"; tg="${tg/,nil:/:}"
+    tg="${tg/,nil:/:}" tg="${tg/,nil:/:}"; tg="${tg/,nil:/:}"; tg="${tg/,nil:/:}"
 
     # finally exported
     export test_groups="${tg}"