Merge "api: Correct expected errors"

This commit is contained in:
Zuul
2025-08-29 21:12:29 +00:00
committed by Gerrit Code Review
3 changed files with 2 additions and 5 deletions

View File

@@ -181,8 +181,8 @@ class KeypairController(wsgi.Controller):
@validation.response_body_schema(schema.index_response, '2.0', '2.1')
@validation.response_body_schema(schema.index_response_v22, '2.2', '2.34')
@validation.response_body_schema(schema.index_response_v235, '2.35')
@wsgi.expected_errors((), '2.0', '2.9')
@wsgi.expected_errors(400, '2.10')
@wsgi.expected_errors((), '2.0', '2.34')
@wsgi.expected_errors(400, '2.35')
def index(self, req):
key_type = False
if api_version_request.is_supported(req, '2.2'):

View File

@@ -110,7 +110,6 @@ class QuotaSetsController(wsgi.Controller):
else:
return []
@wsgi.api_version('2.1')
@wsgi.expected_errors(400)
@validation.query_schema(quota_sets.show_query, '2.0', '2.74')
@validation.query_schema(quota_sets.show_query_v275, '2.75')
@@ -148,7 +147,6 @@ class QuotaSetsController(wsgi.Controller):
self._get_quotas(context, id, user_id=user_id, usages=True),
filtered_quotas=filtered_quotas)
@wsgi.api_version('2.1')
@wsgi.expected_errors(400)
@validation.schema(quota_sets.update, '2.0', '2.35')
@validation.schema(quota_sets.update_v236, '2.36', '2.56')

View File

@@ -185,7 +185,6 @@ class ServerGroupController(wsgi.Controller):
for group in limited_list]
return {'server_groups': result}
@wsgi.api_version("2.1")
@wsgi.expected_errors((400, 403, 409))
@validation.schema(schema.create, "2.0", "2.14")
@validation.schema(schema.create_v215, "2.15", "2.63")