Merge "Add Nova lock and unlock scenario"

This commit is contained in:
Jenkins 2015-05-06 06:37:53 +00:00 committed by Gerrit Code Review
commit 67f2820778
4 changed files with 66 additions and 1 deletions

View File

@ -1278,6 +1278,25 @@
failure_rate:
max: 0
NovaServers.boot_lock_unlock_and_delete:
-
args:
flavor:
name: "m1.tiny"
image:
name: {{image_name}}
runner:
type: "constant"
times: 4
concurrency: 4
context:
users:
tenants: 2
users_per_tenant: 1
sla:
failure_rate:
max: 0
NovaServers.boot_server_from_volume_and_delete:
-
args:

View File

@ -0,0 +1,25 @@
{
"NovaServers.boot_lock_unlock_and_delete": [
{
"args": {
"flavor": {
"name": "m1.tiny"
},
"image": {
"name": "cirros-0.3.2-x86_64-uec"
}
},
"runner": {
"type": "constant",
"times": 10,
"concurrency": 2
},
"context": {
"users": {
"tenants": 1,
"users_per_tenant": 1
}
}
}
]
}

View File

@ -0,0 +1,16 @@
---
NovaServers.boot_lock_unlock_and_delete:
-
args:
flavor:
name: "m1.tiny"
image:
name: "cirros-0.3.2-x86_64-uec"
runner:
type: "constant"
times: 10
concurrency: 2
context:
users:
tenants: 1
users_per_tenant: 1

View File

@ -105,10 +105,15 @@ class FakeResource(object):
class FakeServer(FakeResource):
def suspend(self):
self.status = "SUSPENDED"
def lock(self):
setattr(self, "OS-EXT-STS:locked", True)
def unlock(self):
setattr(self, "OS-EXT-STS:locked", False)
class FakeFailedServer(FakeResource):