Increase Shaker timeout before init message in console 51/69851/1
authorCédric Ollivier <cedric.ollivier@orange.com>
Sat, 28 Mar 2020 08:52:24 +0000 (09:52 +0100)
committerCédric Ollivier <cedric.ollivier@orange.com>
Sat, 28 Mar 2020 09:15:37 +0000 (10:15 +0100)
It failed in parallel of rally_full [1].

[1] https://build.opnfv.org/ci/job/functest-opnfv-functest-benchmarking-hunter-shaker-run/397/console
[2] https://build.opnfv.org/ci/job/functest-opnfv-functest-benchmarking-hunter-shaker-run/395/console

Change-Id: I0eab7374c5962d45405c5f4147798067526f6e70
Signed-off-by: Cédric Ollivier <cedric.ollivier@orange.com>
(cherry picked from commit 14268b0e9f73a057c16f1a3ea0be0246dedaf4db)

functest/core/singlevm.py
functest/opnfv_tests/openstack/shaker/shaker.py

index 0a8007f..724e077 100644 (file)
@@ -368,6 +368,8 @@ class SingleVm1(VmReady1):
     ssh_connect_timeout = 1
     ssh_connect_loops = 6
     create_floating_ip_timeout = 120
+    check_console_loop = 6
+    check_console_regex = ' login: '
 
     def __init__(self, **kwargs):
         if "case_name" not in kwargs:
@@ -481,7 +483,9 @@ class SingleVm1(VmReady1):
             self.prepare()
             self.sshvm = self.boot_vm(
                 key_name=self.keypair.id, security_groups=[self.sec.id])
-            if self.check_regex_in_console(self.sshvm.name):
+            if self.check_regex_in_console(
+                    self.sshvm.name, regex=self.check_console_regex,
+                    loop=self.check_console_loop):
                 (self.fip, self.ssh) = self.connect(self.sshvm)
                 if not self.execute():
                     self.result = 100
index fe52100..57e033e 100644 (file)
@@ -43,6 +43,7 @@ class Shaker(singlevm.SingleVm2):
     shaker_timeout = '3600'
     quota_instances = -1
     quota_cores = -1
+    check_console_loop = 12
 
     def __init__(self, **kwargs):
         super(Shaker, self).__init__(**kwargs)