Fix test_get_service_by_invalid_params for microversion 2.75

From nova microversion 2.75, additional parameters of list_services
are not allowed, so test_get_service_by_invalid_params should be
skipped for microversion >= 2.75.

Change-Id: Iba870f077203d3f0d154aeb24de491a7534290af
This commit is contained in:
zhufl 2020-06-18 16:36:52 +08:00
parent f94204f044
commit 8517b918a3

View File

@ -43,6 +43,9 @@ class ServicesAdminNegativeTestJSON(base.BaseV2ComputeAdminTest):
Expect all services to be returned when the request contains invalid
parameters.
"""
if not self.is_requested_microversion_compatible('2.74'):
raise self.skipException(
"From microversion 2.75 invalid parameters are not allowed.")
services = self.client.list_services()['services']
services_xxx = (self.client.list_services(xxx='nova-compute')
['services'])