summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorSteven Hardy <shardy@redhat.com>2014-10-02 12:52:20 +0100
committerSteven Hardy <shardy@redhat.com>2014-10-08 12:11:40 +0100
commitda2a83562b297c019b9325023577196ec992e507 (patch)
tree635b7bc0e3bab52503a4d14079adf08c9672692b
parentc7430c2ac5c2351c32dd05521e954e8c990b8f22 (diff)
downloadtempest-da2a83562b297c019b9325023577196ec992e507.tar.gz
Orchestration use stack timeout waiting for ping response
The test_server_cfn_init scenario test boots a full Fedora image, not the cirros image which is presumably used for compute tests where the default 120s ping timeout may be appropriate. To ensure we don't encounter any spurious failures due to booting the much bigger orchestration image (which is Fedora in the gate), use the stack timeout (default 900s) to override the ping timeout for this test. Change-Id: I4eba18333bdaa0ef41122cda85fd3f4d91b2cf5c Closes-Bug: #1374175
-rw-r--r--tempest/scenario/manager.py7
-rw-r--r--tempest/scenario/orchestration/test_server_cfn_init.py4
2 files changed, 6 insertions, 5 deletions
diff --git a/tempest/scenario/manager.py b/tempest/scenario/manager.py
index 79207cd93..699d9a76b 100644
--- a/tempest/scenario/manager.py
+++ b/tempest/scenario/manager.py
@@ -443,7 +443,9 @@ class ScenarioTest(tempest.test.BaseTestCase):
if wait:
self.servers_client.wait_for_server_status(server_id, 'ACTIVE')
- def ping_ip_address(self, ip_address, should_succeed=True):
+ def ping_ip_address(self, ip_address, should_succeed=True,
+ ping_timeout=None):
+ timeout = ping_timeout or CONF.compute.ping_timeout
cmd = ['ping', '-c1', '-w1', ip_address]
def ping():
@@ -453,8 +455,7 @@ class ScenarioTest(tempest.test.BaseTestCase):
proc.communicate()
return (proc.returncode == 0) == should_succeed
- return tempest.test.call_until_true(
- ping, CONF.compute.ping_timeout, 1)
+ return tempest.test.call_until_true(ping, timeout, 1)
class NetworkScenarioTest(ScenarioTest):
diff --git a/tempest/scenario/orchestration/test_server_cfn_init.py b/tempest/scenario/orchestration/test_server_cfn_init.py
index abda1f828..791c564c2 100644
--- a/tempest/scenario/orchestration/test_server_cfn_init.py
+++ b/tempest/scenario/orchestration/test_server_cfn_init.py
@@ -24,7 +24,6 @@ LOG = logging.getLogger(__name__)
class CfnInitScenarioTest(manager.OrchestrationScenarioTest):
- @test.skip_because(bug="1374175")
def setUp(self):
super(CfnInitScenarioTest, self).setUp()
if not CONF.orchestration.image_ref:
@@ -84,7 +83,8 @@ class CfnInitScenarioTest(manager.OrchestrationScenarioTest):
server_ip =\
server['addresses'][CONF.compute.network_for_ssh][0]['addr']
- if not self.ping_ip_address(server_ip):
+ if not self.ping_ip_address(
+ server_ip, ping_timeout=CONF.orchestration.build_timeout):
self._log_console_output(servers=[server])
self.fail(
"(CfnInitScenarioTest:test_server_cfn_init) Timed out waiting "