Fix a missing policy in test policy data
Add the 'os_compute_api:os-flavor-manage:update'
in the test policy data in nova/tests/unit/fake_policy.py.
It should have been added in
Ib16b0de82f9f9492f5cacf646dc3165a0849d75e.
TrivialFix
Change-Id: Ibbdcec1c9c5b897eb6dab993ece0535f307025ab
(cherry picked from commit 72028ff8b9
)
This commit is contained in:
parent
f287a291e2
commit
a4017aaa53
|
@ -688,9 +688,10 @@ class FlavorManagerPolicyEnforcementV21(test.TestCase):
|
|||
exc.format_message())
|
||||
|
||||
def test_flavor_update_non_admin_fails(self):
|
||||
"""Tests that trying to update a flavor as a non-admin fails due
|
||||
to the default policy.
|
||||
"""Tests that trying to update a flavor as a non-admin fails.
|
||||
"""
|
||||
rule_name = "os_compute_api:os-flavor-manage:update"
|
||||
self.policy.set_rules({rule_name: "is_admin:True"})
|
||||
self.req.api_version_request = api_version_request.APIVersionRequest(
|
||||
'2.55')
|
||||
exc = self.assertRaises(
|
||||
|
|
|
@ -45,6 +45,7 @@ policy_data = """
|
|||
"os_compute_api:os-flavor-extra-specs:show": "",
|
||||
"os_compute_api:os-flavor-manage": "",
|
||||
"os_compute_api:os-flavor-manage:create": "",
|
||||
"os_compute_api:os-flavor-manage:update": "",
|
||||
"os_compute_api:os-flavor-manage:delete": "",
|
||||
"os_compute_api:os-floating-ip-pools": "",
|
||||
"os_compute_api:os-floating-ips": "",
|
||||
|
|
Loading…
Reference in New Issue