summaryrefslogtreecommitdiffstats
path: root/tests/run.sh
diff options
context:
space:
mode:
authorRyota MIBU <r-mibu@cq.jp.nec.com>2016-07-22 19:21:42 +0900
committerRyota MIBU <r-mibu@cq.jp.nec.com>2016-07-22 19:23:32 +0900
commit6c2bfae36dfa0bde96fa96092ccad8b32beb7f02 (patch)
tree5d62f039db545466ac27ffbdee641e1b44c18fb4 /tests/run.sh
parent5aa254607e0737916dc72200064857882e1abd36 (diff)
make script fail if it failed to get COMPUTE_HOST
This patch is to make sure the test will be stop and report it failed. JIRA: DOCTOR-63 Change-Id: Ibab577a100dee784df14e8b129fbde626d04fce9 Signed-off-by: Ryota MIBU <r-mibu@cq.jp.nec.com>
Diffstat (limited to 'tests/run.sh')
-rwxr-xr-xtests/run.sh4
1 files changed, 4 insertions, 0 deletions
diff --git a/tests/run.sh b/tests/run.sh
index 4d9a5c73..5dbd608b 100755
--- a/tests/run.sh
+++ b/tests/run.sh
@@ -46,6 +46,10 @@ get_compute_host_info() {
grep "OS-EXT-SRV-ATTR:host" | awk '{ print $4 }' |
awk -F '.' '{print $1}')
)
+ if [[ -z "$COMPUTE_HOST" ]] ; then
+ echo "ERROR: failed to get compute hostname"
+ exit 1
+ fi
if [[ "$INSTALLER_TYPE" == "apex" ]] ; then
COMPUTE_USER=${COMPUTE_USER:-heat-admin}
if [[ "$INSTALLER_IP" == "none" ]] ; then