Fix error when OPENMANO envioronment is set a different location
Change-Id: I0f3c7396bd27c857a677c2f37befd11a07616616
Signed-off-by: tierno <alfonso.tiernosepulveda@telefonica.com>
diff --git a/test/basictest.sh b/test/basictest.sh
index 38bf015..91e87ec 100755
--- a/test/basictest.sh
+++ b/test/basictest.sh
@@ -48,7 +48,7 @@
}
#detect if is called with a source to use the 'exit'/'return' command for exiting
-[[ ${BASH_SOURCE[0]} != $0 ]] && _exit="return" || _exit="exit"
+[[ ${BASH_SOURCE[0]} != $0 ]] && _exit="return" || _exit="exit"
#check correct arguments
@@ -82,6 +82,12 @@
DIRNAME=$(dirname $(readlink -f ${BASH_SOURCE[0]}))
DIRmano=$(dirname $DIRNAME)
DIRscript=${DIRmano}/scripts
+export OPENMANO_HOST=localhost
+export OPENMANO_PORT=9090
+[[ $insert_bashrc == y ]] && echo -e "\nexport OPENMANO_HOST=localhost" >> ~/.bashrc
+[[ $insert_bashrc == y ]] && echo -e "\nexport OPENMANO_PORT=9090" >> ~/.bashrc
+
+
#by default action should be reset and create
[[ -z $action_list ]] && action_list="reset create delete"
[[ -z $init_openvim ]] || initopenvim $force || echo "WARNING openvim cannot be initialized. The rest of test can fail!"