Merge "Use upper constraints in pep8 test run"
diff --git a/bindep.txt b/bindep.txt
index 7d34939..3eb3bbd 100644
--- a/bindep.txt
+++ b/bindep.txt
@@ -5,7 +5,6 @@
libffi-devel [platform:rpm]
gcc [platform:rpm]
gcc [platform:dpkg]
-python-devel [platform:rpm]
python3-dev [platform:dpkg]
python3-devel [platform:rpm]
openssl-devel [platform:rpm]
diff --git a/doc/source/supported_version.rst b/doc/source/supported_version.rst
index 3d221c9..e86ba39 100644
--- a/doc/source/supported_version.rst
+++ b/doc/source/supported_version.rst
@@ -9,10 +9,9 @@
Tempest master supports the below OpenStack Releases:
+* 2023.1
* Zed
* Yoga
-* Xena
-* Wallaby
For older OpenStack Release:
@@ -35,3 +34,5 @@
* Python 3.8
* Python 3.9
+* Python 3.10
+* Python 3.11
diff --git a/tempest/api/network/admin/test_negative_quotas.py b/tempest/api/network/admin/test_negative_quotas.py
deleted file mode 100644
index 1ce9f47..0000000
--- a/tempest/api/network/admin/test_negative_quotas.py
+++ /dev/null
@@ -1,86 +0,0 @@
-# Copyright 2015 Cloudwatt
-# All Rights Reserved.
-#
-# Licensed under the Apache License, Version 2.0 (the "License"); you may
-# not use this file except in compliance with the License. You may obtain
-# a copy of the License at
-#
-# http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing, software
-# distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
-# WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
-# License for the specific language governing permissions and limitations
-# under the License.
-
-from tempest.api.network import base
-from tempest.common import identity
-from tempest.common import utils
-from tempest.lib.common.utils import data_utils
-from tempest.lib.common.utils import test_utils
-from tempest.lib import decorators
-from tempest.lib import exceptions as lib_exc
-
-
-class QuotasNegativeTest(base.BaseAdminNetworkTest):
- """Tests the following operations in the Neutron API:
-
- set network quota and exceed this quota
-
- v2.0 of the API is assumed.
- It is also assumed that the per-project quota extension API is configured
- in /etc/neutron/neutron.conf as follows:
-
- quota_driver = neutron.db.quota.driver.DbQuotaDriver
- """
-
- @classmethod
- def skip_checks(cls):
- super(QuotasNegativeTest, cls).skip_checks()
- if not utils.is_extension_enabled('quotas', 'network'):
- msg = "quotas extension not enabled."
- raise cls.skipException(msg)
-
- def setUp(self):
- super(QuotasNegativeTest, self).setUp()
- name = data_utils.rand_name('test_project_')
- description = data_utils.rand_name('desc_')
- self.creds_client = identity.identity_utils(self.os_admin)
- self.project = self.creds_client.create_project(
- name=name, description=description)
- self.addCleanup(identity.identity_utils(self.os_admin).delete_project,
- self.project['id'])
-
- def tearDown(self):
- super(QuotasNegativeTest, self).tearDown()
- self.credentials_provider.cleanup_default_secgroup(
- self.os_admin.security_groups_client, self.project['id'])
-
- @decorators.attr(type=['negative'])
- @decorators.idempotent_id('644f4e1b-1bf9-4af0-9fd8-eb56ac0f51cf')
- def test_network_quota_exceeding(self):
- """Test creating network when exceeding network quota will fail"""
- # Set the network quota to two
- self.admin_quotas_client.update_quotas(self.project['id'], network=2)
-
- # Create two networks
- n1 = self.admin_networks_client.create_network(
- project_id=self.project['id'])
- self.addCleanup(test_utils.call_and_ignore_notfound_exc,
- self.admin_networks_client.delete_network,
- n1['network']['id'])
- n2 = self.admin_networks_client.create_network(
- project_id=self.project['id'])
- self.addCleanup(test_utils.call_and_ignore_notfound_exc,
- self.admin_networks_client.delete_network,
- n2['network']['id'])
-
- # Try to create a third network while the quota is two
- with self.assertRaisesRegex(
- lib_exc.Conflict,
- r"Quota exceeded for resources: \['network'\].*"):
- n3 = self.admin_networks_client.create_network(
- project_id=self.project['id'])
- self.addCleanup(test_utils.call_and_ignore_notfound_exc,
- self.admin_networks_client.delete_network,
- n3['network']['id'])
diff --git a/tempest/api/network/admin/test_quotas.py b/tempest/api/network/admin/test_quotas.py
deleted file mode 100644
index d8db298..0000000
--- a/tempest/api/network/admin/test_quotas.py
+++ /dev/null
@@ -1,107 +0,0 @@
-# Copyright 2013 OpenStack Foundation
-# All Rights Reserved.
-#
-# Licensed under the Apache License, Version 2.0 (the "License"); you may
-# not use this file except in compliance with the License. You may obtain
-# a copy of the License at
-#
-# http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing, software
-# distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
-# WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
-# License for the specific language governing permissions and limitations
-# under the License.
-
-import testtools
-
-from tempest.api.network import base
-from tempest.common import identity
-from tempest.common import utils
-from tempest.lib.common.utils import data_utils
-from tempest.lib.common.utils import test_utils
-from tempest.lib import decorators
-
-
-class QuotasTest(base.BaseAdminNetworkTest):
- """Tests the following operations in the Neutron API:
-
- list quotas for projects who have non-default quota values
- show quotas for a specified project
- update quotas for a specified project
- reset quotas to default values for a specified project
-
- v2.0 of the API is assumed.
- It is also assumed that the per-project quota extension API is configured
- in /etc/neutron/neutron.conf as follows:
-
- quota_driver = neutron.db.quota.driver.DbQuotaDriver
- """
-
- @classmethod
- def skip_checks(cls):
- super(QuotasTest, cls).skip_checks()
- if not utils.is_extension_enabled('quotas', 'network'):
- msg = "quotas extension not enabled."
- raise cls.skipException(msg)
-
- def _check_quotas(self, new_quotas):
- # Add a project to conduct the test
- project = data_utils.rand_name('test_project_')
- description = data_utils.rand_name('desc_')
- project = identity.identity_utils(self.os_admin).create_project(
- name=project, description=description)
- project_id = project['id']
- self.addCleanup(identity.identity_utils(self.os_admin).delete_project,
- project_id)
-
- # Change quotas for project
- quota_set = self.admin_quotas_client.update_quotas(
- project_id, **new_quotas)['quota']
- self.addCleanup(test_utils.call_and_ignore_notfound_exc,
- self.admin_quotas_client.reset_quotas, project_id)
- for key, value in new_quotas.items():
- self.assertEqual(value, quota_set[key])
-
- # Confirm our project is listed among projects with non default quotas
- non_default_quotas = self.admin_quotas_client.list_quotas()
- found = False
- for qs in non_default_quotas['quotas']:
- if qs['project_id'] == project_id:
- found = True
- self.assertTrue(found)
-
- # Confirm from API quotas were changed as requested for project
- quota_set = self.admin_quotas_client.show_quotas(project_id)
- quota_set = quota_set['quota']
- for key, value in new_quotas.items():
- self.assertEqual(value, quota_set[key])
-
- # Reset quotas to default and confirm
- self.admin_quotas_client.reset_quotas(project_id)
- non_default_quotas = self.admin_quotas_client.list_quotas()
- for q in non_default_quotas['quotas']:
- self.assertNotEqual(project_id, q['project_id'])
- quota_set = self.admin_quotas_client.show_quotas(project_id)['quota']
- default_quotas = self.admin_quotas_client.show_default_quotas(
- project_id)['quota']
- self.assertEqual(default_quotas, quota_set)
-
- @decorators.idempotent_id('2390f766-836d-40ef-9aeb-e810d78207fb')
- def test_quotas(self):
- """Test update/list/show/reset of network quotas"""
- new_quotas = {'network': 0, 'port': 0}
- self._check_quotas(new_quotas)
-
- @testtools.skipUnless(utils.is_extension_enabled(
- 'quota_details', 'network'), 'Quota details extension not enabled.')
- @decorators.idempotent_id('7b05ec5f-bf44-43cb-b28f-ddd72a824288')
- def test_show_quota_details(self):
- """Test showing network quota details"""
- # Show quota details for an existing project
- quota_details = self.admin_quotas_client.show_quota_details(
- self.admin_quotas_client.tenant_id)['quota']
- expected_keys = ['used', 'limit', 'reserved']
- for resource_type in quota_details:
- for key in expected_keys:
- self.assertIn(key, quota_details[resource_type])
diff --git a/tempest/lib/services/object_storage/container_client.py b/tempest/lib/services/object_storage/container_client.py
index ee87726..bdca0d0 100644
--- a/tempest/lib/services/object_storage/container_client.py
+++ b/tempest/lib/services/object_storage/container_client.py
@@ -43,7 +43,7 @@
url = str(container_name)
resp, body = self.put(url, body=None, headers=headers)
- self.expected_success([201, 202], resp.status)
+ self.expected_success([201, 202, 204], resp.status)
return resp, body
# NOTE: This alias is for the usability because PUT can be used for both
diff --git a/zuul.d/integrated-gate.yaml b/zuul.d/integrated-gate.yaml
index 2d4b8d9..87b8af0 100644
--- a/zuul.d/integrated-gate.yaml
+++ b/zuul.d/integrated-gate.yaml
@@ -20,8 +20,6 @@
- job:
name: tempest-ipv6-only
parent: devstack-tempest-ipv6
- # This currently works from stable/pike on.
- branches: ^(?!stable/ocata).*$
description: |
Integration test of IPv6-only deployments. This job runs
smoke and IPv6 relates tests only. Basic idea is to test
@@ -33,10 +31,6 @@
- job:
name: tempest-full
parent: devstack-tempest
- # This currently works from stable/pike on.
- # Before stable/pike, legacy version of tempest-full
- # 'legacy-tempest-dsvm-neutron-full' run.
- branches: ^(?!stable/ocata).*$
description: |
Base integration test with Neutron networking and py27.
This job is supposed to run until stable/train setup only.
@@ -78,7 +72,9 @@
# available in old tempest used till stable/wallaby,
# this job definition is only for stable/xena onwards
# and separate job definition until stable/wallaby
- branches: ^(?!stable/(ocata|pike|queens|rocky|stein|train|ussuri|victoria|wallaby)).*$
+ branches:
+ regex: ^stable/(stein|train|ussuri|victoria|wallaby)$
+ negate: true
description: |
Base integration test with Neutron networking, horizon, swift enable,
and py3.
@@ -110,7 +106,9 @@
parent: tempest-full-py3
nodeset: devstack-single-node-centos-9-stream
# centos-9-stream is supported from yoga release onwards
- branches: ^(?!stable/(pike|queens|rocky|stein|train|ussuri|victoria|wallaby|xena)).*$
+ branches:
+ regex: ^stable/(stein|train|ussuri|victoria|wallaby|xena)$
+ negate: true
description: |
Base integration test on CentOS 9 stream
vars:
@@ -122,7 +120,6 @@
- job:
name: tempest-integrated-networking
parent: devstack-tempest
- branches: ^(?!stable/ocata).*$
description: |
This job runs integration tests for networking. This is subset of
'tempest-full-py3' job and run only Neutron and Nova related tests.
@@ -142,7 +139,6 @@
- job:
name: tempest-integrated-compute
parent: devstack-tempest
- branches: ^(?!stable/ocata).*$
description: |
This job runs integration tests for compute. This is
subset of 'tempest-full-py3' job and run Nova, Neutron, Cinder (except backup tests)
@@ -171,7 +167,9 @@
parent: tempest-integrated-compute
nodeset: devstack-single-node-centos-9-stream
# centos-9-stream is supported from yoga release onwards
- branches: ^(?!stable/(pike|queens|rocky|stein|train|ussuri|victoria|wallaby|xena)).*$
+ branches:
+ regex: ^stable/(stein|train|ussuri|victoria|wallaby|xena)$
+ negate: true
description: |
This job runs integration tests for compute. This is
subset of 'tempest-full-py3' job and run Nova, Neutron, Cinder (except backup tests)
@@ -185,7 +183,6 @@
- job:
name: tempest-integrated-placement
parent: devstack-tempest
- branches: ^(?!stable/ocata).*$
description: |
This job runs integration tests for placement. This is
subset of 'tempest-full-py3' job and run Nova and Neutron
@@ -211,7 +208,6 @@
- job:
name: tempest-integrated-storage
parent: devstack-tempest
- branches: ^(?!stable/ocata).*$
description: |
This job runs integration tests for image & block storage. This is
subset of 'tempest-full-py3' job and run Cinder, Glance, Swift and Nova
@@ -227,7 +223,6 @@
- job:
name: tempest-integrated-object-storage
parent: devstack-tempest
- branches: ^(?!stable/ocata).*$
description: |
This job runs integration tests for object storage. This is
subset of 'tempest-full-py3' job and run Swift, Cinder and Glance
@@ -259,7 +254,9 @@
parent: tempest-multinode-full-base
nodeset: openstack-two-node-jammy
# This job runs on ubuntu Jammy and after stable/zed.
- branches: ^(?!stable/(pike|queens|rocky|stein|train|ussuri|victoria|wallaby|xena|yoga|zed)).*$
+ branches:
+ regex: ^stable/(stein|train|ussuri|victoria|wallaby|xena|yoga|zed)$
+ negate: true
vars:
# NOTE(gmann): Default concurrency is higher (number of cpu -2) which
# end up 6 in upstream CI. Higher concurrency means high parallel
@@ -294,8 +291,6 @@
* legacy-tempest-dsvm-neutron-scenario-multinode-lvm-multibackend
* tempest-scenario-multinode-lvm-multibackend
timeout: 10800
- # This job runs on stable/stein onwards.
- branches: ^(?!stable/(ocata|pike|queens|rocky)).*$
vars:
tox_envlist: slow-serial
devstack_localrc:
@@ -323,7 +318,9 @@
# As the 'slow' tox env which is not available in old tempest used
# till stable/wallaby, this job definition is only for stable/xena
# onwards and separate job definition until stable/wallaby
- branches: ^(?!stable/(ocata|pike|queens|rocky|stein|train|ussuri|victoria|wallaby)).*$
+ branches:
+ regex: ^stable/(stein|train|ussuri|victoria|wallaby)$
+ negate: true
vars:
tox_envlist: slow
devstack_localrc:
@@ -450,7 +447,9 @@
# and job is broken up to wallaby branch due to the issue
# described in https://review.opendev.org/872341
- openstacksdk-functional-devstack:
- branches: ^(?!stable/(ussuri|victoria|wallaby)).*$
+ branches:
+ regex: ^stable/(ussuri|victoria|wallaby)$
+ negate: true
gate:
jobs:
- grenade
@@ -460,7 +459,9 @@
# and job is broken up to wallaby branch due to the issue
# described in https://review.opendev.org/872341
- openstacksdk-functional-devstack:
- branches: ^(?!stable/(ussuri|victoria|wallaby)).*$
+ branches:
+ regex: ^stable/(ussuri|victoria|wallaby)$
+ negate: true
- project-template:
name: integrated-gate-compute
@@ -498,7 +499,9 @@
# and job is broken up to wallaby branch due to the issue
# described in https://review.opendev.org/872341
- openstacksdk-functional-devstack:
- branches: ^(?!stable/(ussuri|victoria|wallaby)).*$
+ branches:
+ regex: ^stable/(ussuri|victoria|wallaby)$
+ negate: true
gate:
jobs:
- grenade-skip-level-always:
@@ -506,12 +509,16 @@
- master
- tempest-integrated-compute
- openstacksdk-functional-devstack:
- branches: ^(?!stable/(ussuri|victoria|wallaby)).*$
+ branches:
+ regex: ^stable/(ussuri|victoria|wallaby)$
+ negate: true
periodic-weekly:
jobs:
# centos-9-stream is tested from zed release onwards
- tempest-integrated-compute-centos-9-stream:
- branches: ^(?!stable/(pike|queens|rocky|stein|train|ussuri|victoria|wallaby|xena|yoga)).*$
+ branches:
+ regex: ^stable/(stein|train|ussuri|victoria|wallaby|xena|yoga)$
+ negate: true
- project-template:
name: integrated-gate-placement
@@ -533,7 +540,9 @@
# and job is broken up to wallaby branch due to the issue
# described in https://review.opendev.org/872341
- openstacksdk-functional-devstack:
- branches: ^(?!stable/(ussuri|victoria|wallaby)).*$
+ branches:
+ regex: ^stable/(ussuri|victoria|wallaby)$
+ negate: true
gate:
jobs:
- grenade
@@ -543,7 +552,9 @@
# and job is broken up to wallaby branch due to the issue
# described in https://review.opendev.org/872341
- openstacksdk-functional-devstack:
- branches: ^(?!stable/(ussuri|victoria|wallaby)).*$
+ branches:
+ regex: ^stable/(ussuri|victoria|wallaby)$
+ negate: true
- project-template:
name: integrated-gate-storage
@@ -565,7 +576,9 @@
# and job is broken up to wallaby branch due to the issue
# described in https://review.opendev.org/872341
- openstacksdk-functional-devstack:
- branches: ^(?!stable/(ussuri|victoria|wallaby)).*$
+ branches:
+ regex: ^stable/(ussuri|victoria|wallaby)$
+ negate: true
gate:
jobs:
- grenade
@@ -575,7 +588,9 @@
# and job is broken up to wallaby branch due to the issue
# described in https://review.opendev.org/872341
- openstacksdk-functional-devstack:
- branches: ^(?!stable/(ussuri|victoria|wallaby)).*$
+ branches:
+ regex: ^stable/(ussuri|victoria|wallaby)$
+ negate: true
- project-template:
name: integrated-gate-object-storage
@@ -593,7 +608,9 @@
# and job is broken up to wallaby branch due to the issue
# described in https://review.opendev.org/872341
- openstacksdk-functional-devstack:
- branches: ^(?!stable/(ussuri|victoria|wallaby)).*$
+ branches:
+ regex: ^stable/(ussuri|victoria|wallaby)$
+ negate: true
gate:
jobs:
- grenade
@@ -603,4 +620,6 @@
# and job is broken up to wallaby branch due to the issue
# described in https://review.opendev.org/872341
- openstacksdk-functional-devstack:
- branches: ^(?!stable/(ussuri|victoria|wallaby)).*$
+ branches:
+ regex: ^stable/(ussuri|victoria|wallaby)$
+ negate: true
diff --git a/zuul.d/stable-jobs.yaml b/zuul.d/stable-jobs.yaml
index d399556..51559f4 100644
--- a/zuul.d/stable-jobs.yaml
+++ b/zuul.d/stable-jobs.yaml
@@ -39,7 +39,7 @@
name: tempest-slow-2023-1
parent: tempest-slow-py3
nodeset: openstack-two-node-jammy
- override-checkout: stable/2023-1
+ override-checkout: stable/2023.1
- job:
name: tempest-full-enforce-scope-new-defaults-zed
@@ -95,9 +95,6 @@
# This job version is with swift disabled on py3
# as swift was not ready on py3 until stable/train.
branches:
- - stable/pike
- - stable/queens
- - stable/rocky
- stable/stein
- stable/train
description: |
@@ -227,72 +224,11 @@
USE_PYTHON3: False
- job:
- name: tempest-multinode-full
- parent: tempest-multinode-full-base
- nodeset: openstack-two-node-xenial
- # This job runs on Xenial and this is for stable/pike, stable/queens
- # and stable/rocky. This job is prepared to make sure all stable branches
- # before stable/stein will keep running on xenial. This job can be
- # removed once stable/rocky is EOL.
- branches:
- - stable/pike
- - stable/queens
- - stable/rocky
- vars:
- devstack_localrc:
- USE_PYTHON3: False
- group-vars:
- subnode:
- devstack_localrc:
- USE_PYTHON3: False
-
-- job:
- name: tempest-slow
- parent: tempest-multinode-full
- description: |
- This multinode integration job will run all the tests tagged as slow.
- It enables the lvm multibackend setup to cover few scenario tests.
- This job will run only slow tests (API or Scenario) serially.
- Former names for this job were:
- * legacy-tempest-dsvm-neutron-scenario-multinode-lvm-multibackend
- * tempest-scenario-multinode-lvm-multibackend
- timeout: 10800
- branches:
- - stable/pike
- - stable/queens
- - stable/rocky
- vars:
- tox_envlist: slow-serial
- devstack_localrc:
- CINDER_ENABLED_BACKENDS: lvm:lvmdriver-1,lvm:lvmdriver-2
- ENABLE_VOLUME_MULTIATTACH: true
- # to avoid https://bugs.launchpad.net/neutron/+bug/1914037
- # as we couldn't backport the fix to rocky and older releases
- IPV6_PUBLIC_RANGE: 2001:db8:0:10::/64
- IPV6_PUBLIC_NETWORK_GATEWAY: 2001:db8:0:10::2
- IPV6_ROUTER_GW_IP: 2001:db8:0:10::1
- devstack_plugins:
- neutron: https://opendev.org/openstack/neutron
- devstack_services:
- neutron-placement: true
- neutron-qos: true
- group-vars:
- # NOTE(mriedem): The ENABLE_VOLUME_MULTIATTACH variable is used on both
- # the controller and subnode prior to Rocky so we have to make sure the
- # variable is set in both locations.
- subnode:
- devstack_localrc:
- ENABLE_VOLUME_MULTIATTACH: true
-
-- job:
name: tempest-slow-py3
parent: tempest-slow
# This job version is with swift disabled on py3
# as swift was not ready on py3 until stable/train.
branches:
- - stable/pike
- - stable/queens
- - stable/rocky
- stable/stein
- stable/train
vars:
@@ -333,9 +269,6 @@
# This job is not used after stable/xena and can be
# removed once stable/xena is EOL.
branches:
- - stable/pike
- - stable/queens
- - stable/rocky
- stable/stein
- stable/train
- stable/ussuri
diff --git a/zuul.d/tempest-specific.yaml b/zuul.d/tempest-specific.yaml
index ca63fcc..10490b4 100644
--- a/zuul.d/tempest-specific.yaml
+++ b/zuul.d/tempest-specific.yaml
@@ -54,7 +54,6 @@
- job:
name: tempest-full-py3-ipv6
parent: devstack-tempest-ipv6
- branches: ^(?!stable/ocata).*$
description: |
Base integration test with Neutron networking, IPv6 and py3.
vars: