neutron/neutron/tests/unit/scheduler
Rodolfo Alonso Hernandez ff607c3f22
Check "security_group_rule" quota during security group creation
The tracked resources quota check is done at the beginning of an API
call to the Neutron server. The API call contains a resource and an
action over the resource. In case of creation, the server checks if
the number of items requested fits in the existing quota.

In case of security group creation, the tracked resource checked is
"security_group". But "SecurityGroupDbMixin.create_security_group"
method also creates several default rules for the new group and the
quota for "security_group_rule" is not enforced.

This patch checks the number of security group rules being created
("delta") and checks in the plugin method (not in the API method) if
there is enough room for those new rules (tracked resource
"security_group_rule").

Change-Id: I0a9b91b09d6260ff96fdba2f0a455de53bbc1f00
Closes-Bug: #1858680
(cherry picked from commit 936bd67aa4)
2020-04-24 11:45:27 +02:00
..
__init__.py Reorganize unit test tree 2015-04-06 23:28:31 +00:00
test_dhcp_agent_scheduler.py Fix sort issue in test_dhcp_agent_scheduler.test_filter_bindings 2019-08-12 08:16:43 +00:00
test_l3_agent_scheduler.py Check "security_group_rule" quota during security group creation 2020-04-24 11:45:27 +02:00