Merge "Fix typo in schema"

This commit is contained in:
Zuul 2022-09-02 17:34:54 +00:00 committed by Gerrit Code Review
commit 723da65faf
3 changed files with 23 additions and 3 deletions

View File

@ -172,7 +172,7 @@ POST_ALLOCATIONS_V1_28["patternProperties"] = {
# request group suffixes with lists of resource provider uuids.
mappings_schema = {
"type": "object",
"minProperites": 1,
"minProperties": 1,
"patternProperties": {
common.GROUP_PAT_1_33: {
"type": "array",

View File

@ -70,8 +70,19 @@ tests:
project_id: b2e599e0-ded8-47fd-b8ab-ceb7fca578bd
status: 400
response_json_paths:
# u? accounts for difference in Python 2.7 v. 3.x response
$.errors[0].detail: "/JSON does not validate: u?'beta' is not of type 'array'/"
$.errors[0].detail: "/JSON does not validate: 'beta' is not of type 'array'/"
- name: put allocation mapping empty
PUT: /allocations/5f9588de-079d-462a-a459-408524ab9b60
data:
allocations: $HISTORY['mappings request'].$RESPONSE['$.allocation_requests[0].allocations']
mappings: {}
consumer_generation: null
user_id: 8c974f9a-f266-42f7-8613-a8017cbfb87F
project_id: b2e599e0-ded8-47fd-b8ab-ceb7fca578bd
status: 400
response_json_paths:
$.errors[0].detail: "/JSON does not validate: {} does not have enough properties/"
- name: post allocation with results
POST: /allocations

View File

@ -0,0 +1,9 @@
---
fixes:
- |
Since microversion 1.34, it has been possible to provide a ``mappings``
field when creating new allocations via the ``POST /allocations`` or ``PUT
/allocations/{allocation_id}`` APIs. This field should be a a dictionary
associating request group suffixes with a list of UUIDs identifying the
resource providers that satisfied each group. Due to a typo, this was
allowing an empty object (``{}``). This is now corrected.