neutron/neutron/tests/functional/db
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
..
migrations Use constant IP_VERSION_4/6 in functional tests 2018-08-27 21:45:56 +00:00
__init__.py Freeze models for healing migration 2014-07-14 18:36:05 +02:00
test_ipam.py Fix flake8 H404 errors 2018-10-05 21:48:41 +00:00
test_migrations.py Add new test decorator skip_if_timeout 2019-02-14 11:08:19 +01:00
test_models.py All functional tests logs results now 2018-11-21 19:58:18 +00:00
test_network.py Check "security_group_rule" quota during security group creation 2020-04-24 11:45:27 +02:00