summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authoryuyang <Gabriel.yuyang@huawei.com>2016-11-04 23:30:41 +0800
committeryuyang <Gabriel.yuyang@huawei.com>2016-11-05 00:55:27 +0800
commit00fd400230d4ec9f09aea10821a5a61ec28763f9 (patch)
tree62429accc2f706775000c3c81dfc42e53bbb8a1b
parentcefb61eb31acce1c04cf31c42a7b17fd9d00a5b5 (diff)
Add stack created judging logic
JIRA: BOTTLENECK-103 The stack created judging logic in Rubbos testsuite is optimized by replacing the wating method with judging from the stack created return value. Change-Id: Ie96476fbfb8baf995237f71b993cf9d381b94217 Signed-off-by: yuyang <Gabriel.yuyang@huawei.com>
-rwxr-xr-xtestsuites/rubbos/run_rubbos.py12
1 files changed, 8 insertions, 4 deletions
diff --git a/testsuites/rubbos/run_rubbos.py b/testsuites/rubbos/run_rubbos.py
index 18103f7a..f0fb089a 100755
--- a/testsuites/rubbos/run_rubbos.py
+++ b/testsuites/rubbos/run_rubbos.py
@@ -214,7 +214,7 @@ def rubbos_create_instances(
print "Created stack, id=" + str(stack_id) + ", status=" + str(stack_status)
timeInProgress = 0
- while stack_status == "CREATE_IN_PROGRESS" and timeInProgress < 150:
+ while stack_status == "CREATE_IN_PROGRESS" and timeInProgress < 3600:
print " stack's status: %s, after %d seconds" % (stack_status, timeInProgress)
time.sleep(5)
timeInProgress = timeInProgress + 5
@@ -458,9 +458,13 @@ def main():
else:
print "Cannot create instances, as Failed to create image(s)."
exit(-1)
-
- print "Wait 600 seconds after stack creation..."
- time.sleep(600)
+
+ if stack_created:
+ print "The rubbos_stack is created successfully. \
+ Now to run rubbos instances!"
+ else:
+ print "The rubbos_stack failed to be created. Exit the test!"
+ exit(-1)
# reboot_instances()
# time.sleep(180)