As our internal QE reported to us, ddt is producing more consistent
names of the same tests with different variables then testscenarios.
With testscenarios it is something like:
foo_tempest_plugin.tests.something.SomeClass.test_foo[id-123456](c1,c2)
and with ddt is more similar to tests without scenarios:
foo_tempest_plugin.tests.something.SomeClass.test_foo_1[id-123456]
Apparently due to this inconsistency results of some tests couldn't be
properly reported properly to some tools which we are using downstream.
So this patch proposes to remove usage of testscenarios in
neutron_tempest_plugin and replace it with ddt where it is needed.
Actually ddt was already used in some of the tests here so this will
make it also more consistent across the tests in that repo.
Also as part of this effort I relalised that in some cases testscenarios
where used, tests were running e.g. 2 times but actually variable set to
different value in different scenarios were not used at all. So in such
case I simply dropped usage of testscenarios and left only one variant
of the test to be run.
Change-Id: Ieabab4ccaa0e2a365939425dff0c0776839251eb
The tenant_id property of RestClient in tempest was deprecated in
25.0.0. This replaces the deprecated property by the new project_id
property to avoid the following warning.
WARNING tempest.lib.common.rest_client [-] Deprecated: "tenant_id"
property is deprecated for removal, use "project_id" instead
Depends-on: https://review.opendev.org/c/openstack/tempest/+/707938
Change-Id: Ie3c32f9f2278b78603a4214c5717df8691ba490a
In the test_qos_dscp_create_and_update API test, qos policy was made as
admin user (which is correct) but was also owned by admin project. And
later, to check if DSCP marking rule was created in that policy
properly, regular client is used instead.
The problem is that with new S-RBAC API policies, rules are visible to
owners of the policy, not to all users. And due to that this test is
failing with new S-RBAC policies enforced.
This patch fixes it by changing owner of the qos policy to the regular
client's project.
Related-Bug: #2018727
Change-Id: Iadf69c167cdda0017084e482a58116520a1ea80f
On Wallaby, We have pinned tempest[1] to particular commit[2]
to fix lp#1963907.
https://review.rdoproject.org/r/c/rdoinfo/+/40273 pinned
neutron-tempest-plugin at master commit to fix neutron tempest
tests in wallaby.
But the tempest tests are throwing
```
AttributeError: module 'neutron_lib.services.qos.constants'
has no attribute 'RULE_TYPE_MINIMUM_PACKET_RATE'
```
On wallaby, neutron-lib=2.10.2 is used in the RDO/Tripleo
Deployment.
https://review.opendev.org/c/openstack/neutron-lib/+/816447
Moves RULE_TYPE_MINIMUM_PACKET_RATE to neutron-lib which is available
in Yoga release and not available in wallaby neutron-lib
leading to above failure.
Moving the RULE_TYPE_MINIMUM_PACKET_RATE variable to the setup
method fixes the issue.
[1]. https://review.opendev.org/c/openstack/tempest/+/822560
[2]. https://review.rdoproject.org/r/c/rdoinfo/+/40228
Related-Bug: #1963907
Signed-off-by: Chandan Kumar (raukadah) <chkumar@redhat.com>
Change-Id: If2badd6cbac13ddaf86fe81b48ebd69d2857f1b0
test_list_policy_filter_by_name was looking for policies
with name 'test' and expected only one such policy to
be retrieved, but since tempest is running with multiple
concurrency and some other qos tests were also using same
policy name, this leads to test failure when this test
runs at same time with other such tests. This patch fixes
it by using random name for the policy for this test.
Closes-Bug: #1959184
Change-Id: Ibcbb2403b5b5983b2573c5a4791fb30850816d60
The test validates that a regular client is allowed to attach\detach
QoS policies only to\from networks with policies that were configured
as "Shared".
This test will not be running automatically because of the creation
of a "Shared" resource during the test.
Setting the create_shared_resources option as 'True' in the config.py
file is needed.
Change-Id: Iec3fda32cbce00a677cb30dac3c234c99d7c27fd
The test validates that:
1.Two bandwidth limit rules could be both attached to a policy.
2.The system prevents addition of rules with the same direction to a policy.
Change-Id: I387d50673795c2a5073ec298426960fca593c017
The test verifies that admin user is able to set
DSCP marking rules with all of the valid marks between 0-56.
The test was moved from screnario\test_qos to api\test_qos.
Change-Id: I65b152622d4ba39ef710b44a2d3a044904e3e309
When the API extension qos-bw-minimum-ingress will be on master (see:
https://review.openstack.org/584927) the test
neutron_tempest_plugin.api.test_qos.QosMinimumBandwidthRuleTestJSON.
test_rule_create_fail_for_direction_ingress is useless, so it can be
removed from master, and to keep the coverage for stable branches there
should be fullstack test: I6ee08d43aed60a7dd2d3281deaccfac2f3712b33
Change-Id: Ie04d53817c1f28b4756b1cc308203dc77dd2a19c
Partial-Bug: #1578989
See-Also: https://review.openstack.org/502306 (nova spec)
See-Also: https://review.openstack.org/508149 (neutron spec)
Fix some pep8 warnings found running under python3.5.
Also removed some ignore directives that were carried
over from the neutron tree, and exclude some additional
directories.
Trivialfix
Change-Id: I96f53d3d142352f0d2c7cc641391019b476b0724
This patch adds API test which checks if regular user can
create port in own network if this network has got QoS policy
configured by admin and this QoS policy belongs to admin.
Issue with such scenario was reported in related bug.
Change-Id: I08f337f3bf786ae66f57d48ec8698845ac568b97
Related-Bug: #1750591
Depends-On: I464888ca3920b42edd6ab638f6a317ee51ef0994
* The following commit sync the code from following hash:
start_hash: 7279aa35851110a4933a10b58b2758a2bc3933a3
end_hash: 6e911a49a9e630878f4c46f61fde3964be550880
Change-Id: I371aa4d5f043f695df04b98b0f485c8f0548f2b3
* switch from neutron.tests.tempest to neutron_tempest_plugin
* Cleaned up README.rst and setup.cfg
* Use neutron_tempest_plugin as a tempest plugin package
* Fixed gitreview
* Keeping flake8 Ignores in tox.ini as tempest plugin is
imported from neutron codebase.
Change-Id: I42d389836e72813fdeebc797a577f4a8ac2ee603