When I am debugging the code for the fixing of bug #1468597, #1466872 [1], I found some testcases failure, they are `test_create_region_with_duplicate_id`, `test_create_region_with_matching_ids` and `test_create_region_with_id`.
After digging into the code, I found when the region is created with id provided is not given schema validation at all, this is beasue region reference data is not passed as dict, see [2], but validator expect the reference data is in kwargs [3] which is common usage when the resource is request with restful API.
So, the region creation with id given missed the schema validation.
[1] https://review.openstack.org/#/c/195903/
[2] https://github.com/openstack/keystone/blob/master/keystone/catalog/controllers.py#L173
[3] https://github.com/openstack/keystone/blob/master/keystone/common/validation/__init__.py#L34-L35
Fix proposed to branch: master /review. openstack. org/201007
Review: https:/