AttachVolumeShelveTestJSON.test_attach_detach_volume TC fails, as it uses v2.20 api for getting server details, but schema does not allow additional properties in items of os-extended-volumes:volumes_attached (delete_on_termination is provided since v2.20)
identical testcase AttachVolumeTestJSON.test_attach_detach_volume which uses v2.19 passes
tempest.api.compute.volumes.test_attach_volume.AttachVolumeShelveTestJSON.test_attach_detach_volume[id-52e9045a-e90d-4c0d-9087-79d657faffff]
--------------------------------------------------------------------------------------------------------------------------------------------
Captured traceback:
~~~~~~~~~~~~~~~~~~~
Traceback (most recent call last):
File "/opt/stack/new/tempest/tempest/api/compute/volumes/test_attach_volume.py", line 122, in test_attach_detach_volume
'SHUTOFF')
File "/opt/stack/new/tempest/tempest/common/waiters.py", line 39, in wait_for_server_status
body = client.show_server(server_id)['server']
File "/opt/stack/new/tempest/tempest/lib/services/compute/servers_client.py", line 106, in show_server
self.validate_response(schema.get_server, resp, body)
File "/opt/stack/new/tempest/tempest/lib/common/rest_client.py", line 896, in validate_response
raise exceptions.InvalidHTTPResponseBody(msg)
tempest.lib.exceptions.InvalidHTTPResponseBody: HTTP response body is invalid json or xml
Details: HTTP response body is invalid (Additional properties are not allowed (u'delete_on_termination' was unexpected)
Failed validating 'additionalProperties' in schema['properties']['server']['properties']['os-extended-volumes:volumes_attached']['items']:
{'additionalProperties': False,
'properties': {'id': {'type': 'string'}},
'type': 'object'}
On instance['server']['os-extended-volumes:volumes_attached'][0]:
{u'delete_on_termination': False,
u'id': u'a38cfda7-4e69-48b6-b0ff-ad38cf56154d'})
...
22016-07-07 11:09:10.674 69769 INFO tempest.lib.common.rest_client [req-72829c8d-cd8b-4384-9c1c-e6f4561bb8c1 ] Request (AttachVolumeShelveTestJSON:test_attach_detach_volume): 200 GET http://127.0.0.1:8774/v2.1/servers/7903f672-d9ca-4312-a60d-f26375656c2d 0.496s
2016-07-07 11:09:10.674 69769 DEBUG tempest.lib.common.rest_client [req-72829c8d-cd8b-4384-9c1c-e6f4561bb8c1 ] Request - Headers: {'Content-Type': 'application/json', 'Accept': 'application/json', 'X-OpenStack-Nova-API-Version': '2.20', 'X-Auth-Token': '<omitted>'}
Body: None
Response - Headers: {'status': '200', 'content-length': '1724', 'content-location': 'http://127.0.0.1:8774/v2.1/servers/7903f672-d9ca-4312-a60d-f26375656c2d', 'x-compute-request-id': 'req-72829c8d-cd8b-4384-9c1c-e6f4561bb8c1', 'vary': 'X-OpenStack-Nova-API-Version', 'openstack-api-version': 'compute 2.20', 'connection': 'close', 'x-openstack-nova-api-version': '2.20', 'date': 'Thu, 07 Jul 2016 11:09:10 GMT', 'content-type': 'application/json'}
Body: {"server": {"OS-EXT-STS:task_state": "powering-off", "addresses": {"private": [{"OS-EXT-IPS-MAC:mac_addr": "fa:16:3e:ab:4d:f7", "version": 4, "addr": "10.1.15.0", "OS-EXT-IPS:type": "fixed"}, {"OS-EXT-IPS-MAC:mac_addr": "fa:16:3e:ab:4d:f7", "version": 4, "addr": "172.24.5.2", "OS-EXT-IPS:type": "floating"}]}, "links": [{"href": "http://127.0.0.1:8774/v2.1/servers/7903f672-d9ca-4312-a60d-f26375656c2d", "rel": "self"}, {"href": "http://127.0.0.1:8774/servers/7903f672-d9ca-4312-a60d-f26375656c2d", "rel": "bookmark"}], "image": {"id": "07f9a49d-ea1a-4c3a-a669-ff3020baf67d", "links": [{"href": "http://127.0.0.1:8774/images/07f9a49d-ea1a-4c3a-a669-ff3020baf67d", "rel": "bookmark"}]}, "OS-EXT-STS:vm_state": "active", "OS-SRV-USG:launched_at": "2016-07-07T11:08:52.000000", "flavor": {"id": "42", "links": [{"href": "http://127.0.0.1:8774/flavors/42", "rel": "bookmark"}]}, "id": "7903f672-d9ca-4312-a60d-f26375656c2d", "security_groups": [{"name": "tempest-securitygroup--133906238"}], "OS-SRV-USG:terminated_at": null, "user_id": "83da61292ed64aa88e96fde195e55efe", "OS-DCF:diskConfig": "MANUAL", "accessIPv4": "", "accessIPv6": "", "progress": 0, "OS-EXT-STS:power_state": 1, "OS-EXT-AZ:availability_zone": "nova", "metadata": {}, "status": "ACTIVE", "updated": "2016-07-07T11:09:09Z", "hostId": "926bf6df0ffbd026495dda6a405a418753130578037f040f9562be35", "description": null, "key_name": "tempest-keypair-910368243", "locked": false, "name": "tempest.common.compute-instance-1437032414", "created": "2016-07-07T11:08:33Z", "tenant_id": "ea5d804196454943beedda2db3dc9243", "os-extended-volumes:volumes_attached": [{"id": "cfbbc7be-cc22-425e-a534-e01e9d9ddfbd", "delete_on_termination": false}], "config_drive": "True"}} _log_request_full /opt/stack/new/tempest/tempest/lib/common/rest_client.py:430
^^^
here "delete_on_termination" was unexpected in current schema
This issue was not detected by the gate because we skip test_attach_ detach_ volume (except for in the neutron-ssh job which is non-voting).