orchestration convert API test Timeouts to respect build_timeout

Some tests have a hard-coded WaitCondition timeout, which would be better
controlled from the global timeout set in tempest.conf

We should ensure future tests follow this convention where Timeout values
are specified in the template.

Change-Id: Ie4a9048771e3a106e1d9c6b69f244461f6d5fd8d
Partial-Bug: #1297560
This commit is contained in:
Steven Hardy 2014-04-16 16:09:58 +01:00
parent 65366479a3
commit 0d00dd8be1
4 changed files with 10 additions and 4 deletions

View File

@ -11,6 +11,8 @@ Parameters:
Type: String
network:
Type: String
timeout:
Type: Number
Resources:
CfnUser:
Type: AWS::IAM::User
@ -68,7 +70,7 @@ Resources:
DependsOn: SmokeServer
Properties:
Handle: {Ref: WaitHandle}
Timeout: '600'
Timeout: {Ref: timeout}
Outputs:
WaitConditionStatus:
Description: Contents of /tmp/smoke-status on SmokeServer

View File

@ -12,6 +12,8 @@ parameters:
type: string
ExternalNetworkId:
type: string
timeout:
type: number
resources:
Network:
type: OS::Neutron::Net
@ -65,4 +67,4 @@ resources:
depends_on: Server
properties:
Handle: {get_resource: WaitHandleNeutron}
Timeout: '600'
Timeout: {get_param: timeout}

View File

@ -53,7 +53,8 @@ class NeutronResourcesTestJSON(base.BaseOrchestrationTest):
'InstanceType': CONF.orchestration.instance_type,
'ImageId': CONF.orchestration.image_ref,
'ExternalRouterId': cls.external_router_id,
'ExternalNetworkId': cls.external_network_id
'ExternalNetworkId': cls.external_network_id,
'timeout': CONF.orchestration.build_timeout
})
cls.stack_id = cls.stack_identifier.split('/')[1]
try:

View File

@ -50,7 +50,8 @@ class ServerCfnInitTestJSON(base.BaseOrchestrationTest):
'key_name': keypair_name,
'flavor': CONF.orchestration.instance_type,
'image': CONF.orchestration.image_ref,
'network': cls._get_default_network()['id']
'network': cls._get_default_network()['id'],
'timeout': CONF.orchestration.build_timeout
})
@test.attr(type='slow')