]> review.fuel-infra Code Review - openstack-build/neutron-build.git/commit
Enable to apply policies to resources with special plural
authorYushiro FURUKAWA <y.furukawa_2@jp.fujitsu.com>
Tue, 6 Jan 2015 08:53:54 +0000 (17:53 +0900)
committerYushiro FURUKAWA <y.furukawa_2@jp.fujitsu.com>
Thu, 19 Mar 2015 08:34:48 +0000 (17:34 +0900)
commit88fb463b3cfcd27888c02858cb45c5c5f3bda3a6
tree61d13ceaf083d0ee037159ec5448aee1064c29c1
parent9ac4c3ad9332180bbdf32844af56b32e0433e24d
Enable to apply policies to resources with special plural

Some neutron resource with special plural form
can not apply the policy control using policy.json
when create/update/delete the resource.
Following resources can not apply the policy control
because of wrong pluralize process:

  * firewall_policy
  * ipsec_policy
  * ikepolicy

Current pluralize process is as following:
  "resource" + "s"
  e.g. *_policy -> *_policys

This fix enables to apply the policy control with those resources.
  *_policy -> *_policies

Change-Id: I38a55e95f653f69edd477dbbcbdd6e956c0a0e2b
Closes-Bug: 1407886
neutron/api/v2/base.py
neutron/policy.py
neutron/tests/unit/test_policy.py