Verify the response attributes of 'aggregate-set-metadata' API
This patch verifies the response attributes of 'aggregate-set-metadata'.
The response attributes of v2 and v3 are the same:
{
"aggregate": {
"availability_zone": "nova",
"created_at": "2012-11-16T06:22:22.342791",
"deleted": false,
"deleted_at": null,
"hosts": [],
"id": 1,
"metadata": {
"availability_zone": "nova",
"key": "value"
},
"name": "name",
"updated_at": null
}
}
Partially implements blueprint nova-api-attribute-test
Change-Id: I8940a18e71540aec300023e6736a3318b253d702
diff --git a/tempest/services/compute/v3/json/aggregates_client.py b/tempest/services/compute/v3/json/aggregates_client.py
index 1859642..8d7440e 100644
--- a/tempest/services/compute/v3/json/aggregates_client.py
+++ b/tempest/services/compute/v3/json/aggregates_client.py
@@ -105,4 +105,5 @@
resp, body = self.post('os-aggregates/%s/action' % aggregate_id,
post_body)
body = json.loads(body)
+ self.validate_response(schema.aggregate_set_metadata, resp, body)
return resp, body['aggregate']