Move properties handling to the test side
On Glance v1 API, properties are passed on headers and the v1 client changed properties' names internally. Service clients should work without any wrapper functions, so this patch moves the handling to the test side. Change-Id: I46716e2948eeb429a597289c3db54e978a154f27
This commit is contained in:
parent
d23af14447
commit
e28b2c278e
|
@ -381,7 +381,8 @@ class ServerActionsTestJSON(base.BaseV2ComputeTest):
|
|||
'sort_dir': 'asc'
|
||||
}
|
||||
if CONF.image_feature_enabled.api_v1:
|
||||
params.update({'properties': properties})
|
||||
for key, value in properties.items():
|
||||
params['property-%s' % key] = value
|
||||
image_list = glance_client.list_images(
|
||||
detail=True,
|
||||
**params)['images']
|
||||
|
|
|
@ -130,10 +130,6 @@ class ImagesClient(rest_client.RestClient):
|
|||
if detail:
|
||||
url += '/detail'
|
||||
|
||||
properties = kwargs.pop('properties', {})
|
||||
for key, value in six.iteritems(properties):
|
||||
kwargs['property-%s' % key] = value
|
||||
|
||||
if kwargs.get('changes_since'):
|
||||
kwargs['changes-since'] = kwargs.pop('changes_since')
|
||||
|
||||
|
|
Loading…
Reference in New Issue