run_tiers() {
tiers=$1
- if [[ ${BRANCH##*/} == "master" ]]; then
- cmd_opt="run_tests -r -t all"
- [[ $BUILD_TAG =~ "suite" ]] && cmd_opt="run_tests -t all"
- else
+ if [[ ${BRANCH##*/} == "stable/euphrates" ]]; then
cmd_opt="prepare_env start && run_tests -r -t all"
[[ $BUILD_TAG =~ "suite" ]] && cmd_opt="prepare_env start && run_tests -t all"
+ else
+ cmd_opt="run_tests -r -t all"
+ [[ $BUILD_TAG =~ "suite" ]] && cmd_opt="run_tests -t all"
fi
ret_val_file="${HOME}/opnfv/functest/results/${BRANCH##*/}/return_value"
echo 0 > ${ret_val_file}
run_test() {
test_name=$1
- if [[ ${BRANCH##*/} == "master" ]]; then
- cmd_opt="run_tests -t ${test_name}"
- else
+ if [[ ${BRANCH##*/} == "stable/euphrates" ]]; then
cmd_opt="prepare_env start && run_tests -t ${test_name}"
+ else
+ cmd_opt="run_tests -t ${test_name}"
fi
ret_val_file="${HOME}/opnfv/functest/results/${BRANCH##*/}/return_value"
echo 0 > ${ret_val_file}
envs="${envs} -e POD_ARCH=${COMPUTE_ARCH}"
fi
-volumes="${images_vol} ${results_vol} ${sshkey_vol} ${rc_file_vol} ${cacert_file_vol}"
-set +e
+if [[ ${INSTALLER_TYPE} == 'compass' && ${DEPLOY_SCENARIO} =~ 'sfc' ]]; then
+ ssh_key="/tmp/id_rsa"
+ user_config="/tmp/openstack_user_config.yml"
+ docker cp compass-tasks:/root/.ssh/id_rsa $ssh_key
+ docker cp compass-tasks:/etc/openstack_deploy/openstack_user_config.yml $user_config
+ sshkey_vol="-v ${ssh_key}:/root/.ssh/id_rsa"
+ userconfig_vol="-v ${user_config}:${user_config}"
+ envs="${envs} -e EXTERNAL_NETWORK=${EXTERNAL_NETWORK}"
+fi
-if [[ ${DEPLOY_SCENARIO} =~ ^os-.* ]]; then
- [[ ${BRANCH##*/} == "master" ]] && check_os_deployment
- if [ ${FUNCTEST_MODE} == 'testcase' ]; then
- echo "FUNCTEST_MODE=testcase, FUNCTEST_SUITE_NAME=${FUNCTEST_SUITE_NAME}"
- run_test ${FUNCTEST_SUITE_NAME}
- elif [ ${FUNCTEST_MODE} == 'tier' ]; then
- echo "FUNCTEST_MODE=tier, FUNCTEST_TIER=${FUNCTEST_TIER}"
- tiers=(${FUNCTEST_TIER})
- run_tiers ${tiers}
+volumes="${images_vol} ${results_vol} ${sshkey_vol} ${userconfig_vol} ${rc_file_vol} ${cacert_file_vol}"
+
+set +e
+
+if [ ${FUNCTEST_MODE} == 'testcase' ]; then
+ echo "FUNCTEST_MODE=testcase, FUNCTEST_SUITE_NAME=${FUNCTEST_SUITE_NAME}"
+ run_test ${FUNCTEST_SUITE_NAME}
+elif [ ${FUNCTEST_MODE} == 'tier' ]; then
+ echo "FUNCTEST_MODE=tier, FUNCTEST_TIER=${FUNCTEST_TIER}"
+ tiers=(${FUNCTEST_TIER})
+ run_tiers ${tiers}
+else
+ if [ ${DEPLOY_TYPE} == 'baremetal' ]; then
+ tiers=(healthcheck smoke features vnf parser)
else
- if [ ${DEPLOY_TYPE} == 'baremetal' ]; then
- tiers=(healthcheck smoke patrole features vnf parser)
- else
- tiers=(healthcheck smoke patrole features)
- fi
- run_tiers ${tiers}
+ tiers=(healthcheck smoke features)
fi
-else
- echo "k8 deployment has not been supported by functest yet"
+ run_tiers ${tiers}
fi