Merge "Remove redundant interfaces from v3 identity client"
diff --git a/tempest/api/compute/admin/test_live_migration.py b/tempest/api/compute/admin/test_live_migration.py
index 653a3cd..95310af 100644
--- a/tempest/api/compute/admin/test_live_migration.py
+++ b/tempest/api/compute/admin/test_live_migration.py
@@ -129,10 +129,6 @@
@test.idempotent_id('1e107f21-61b2-4988-8f22-b196e938ab88')
@testtools.skipUnless(CONF.compute_feature_enabled.pause,
'Pause is not available.')
- @testtools.skipUnless(CONF.compute_feature_enabled
- .live_migrate_paused_instances,
- 'Live migration of paused instances is not '
- 'available.')
def test_live_block_migration_paused(self):
self._test_live_migration(state='PAUSED')
diff --git a/tempest/api/compute/servers/test_server_group.py b/tempest/api/compute/servers/test_server_group.py
index c23b365..e32f6b0 100644
--- a/tempest/api/compute/servers/test_server_group.py
+++ b/tempest/api/compute/servers/test_server_group.py
@@ -13,8 +13,6 @@
# License for the specific language governing permissions and limitations
# under the License.
-from tempest_lib import decorators
-
from tempest.api.compute import base
from tempest.common.utils import data_utils
from tempest import test
@@ -81,13 +79,6 @@
policy = ['anti-affinity']
self._create_delete_server_group(policy)
- @decorators.skip_because(bug="1324348")
- @test.idempotent_id('6d9bae05-eb32-425d-a673-e14e1b1c6306')
- def test_create_delete_server_group_with_multiple_policies(self):
- # Create and Delete the server-group with multiple policies
- policies = ['affinity', 'affinity']
- self._create_delete_server_group(policies)
-
@test.idempotent_id('154dc5a4-a2fe-44b5-b99e-f15806a4a113')
def test_create_delete_multiple_server_groups_with_same_name_policy(self):
# Create and Delete the server-groups with same name and same policy
diff --git a/tempest/api/orchestration/stacks/test_limits.py b/tempest/api/orchestration/stacks/test_limits.py
index 2acf97b..315b3e0 100644
--- a/tempest/api/orchestration/stacks/test_limits.py
+++ b/tempest/api/orchestration/stacks/test_limits.py
@@ -33,7 +33,7 @@
Foo: bar''' % fill
ex = self.assertRaises(lib_exc.BadRequest, self.create_stack,
stack_name, template)
- self.assertIn('Template exceeds maximum allowed size', str(ex))
+ self.assertIn('exceeds maximum allowed size', str(ex))
@test.idempotent_id('d1b83e73-7cad-4a22-9839-036548c5387c')
def test_exceed_max_resources_per_stack(self):
diff --git a/tempest/clients.py b/tempest/clients.py
index 866936e..1b89de1 100644
--- a/tempest/clients.py
+++ b/tempest/clients.py
@@ -85,6 +85,7 @@
as NetworkQuotasClient
from tempest_lib.services.network.security_groups_client import \
SecurityGroupsClient
+from tempest_lib.services.network.subnetpools_client import SubnetpoolsClient
from tempest_lib.services.network.subnets_client import SubnetsClient
from tempest.common import negative_rest_client
@@ -136,7 +137,6 @@
from tempest.services.network.json.network_client import NetworkClient
from tempest.services.network.json.security_group_rules_client import \
SecurityGroupRulesClient
-from tempest.services.network.json.subnetpools_client import SubnetpoolsClient
from tempest.services.object_storage.account_client import AccountClient
from tempest.services.object_storage.container_client import ContainerClient
from tempest.services.object_storage.object_client import ObjectClient
diff --git a/tempest/cmd/cleanup.py b/tempest/cmd/cleanup.py
index 7b73a61..c8a8159 100644
--- a/tempest/cmd/cleanup.py
+++ b/tempest/cmd/cleanup.py
@@ -231,7 +231,6 @@
return 'Cleanup after tempest run'
def _add_admin(self, tenant_id):
- id_cl = self.admin_mgr.identity_client
rl_cl = self.admin_mgr.roles_client
needs_role = True
roles = rl_cl.list_user_roles(tenant_id, self.admin_id)['roles']
@@ -241,7 +240,7 @@
LOG.debug("User already had admin privilege for this tenant")
if needs_role:
LOG.debug("Adding admin privilege for : %s" % tenant_id)
- id_cl.assign_user_role(tenant_id, self.admin_id,
+ rl_cl.assign_user_role(tenant_id, self.admin_id,
self.admin_role_id)
self.admin_role_added.append(tenant_id)
diff --git a/tempest/config.py b/tempest/config.py
index 14a6ad2..cdeb916 100644
--- a/tempest/config.py
+++ b/tempest/config.py
@@ -352,13 +352,6 @@
help="Does the test environment block migration support "
"cinder iSCSI volumes. Note, libvirt doesn't support this, "
"see https://bugs.launchpad.net/nova/+bug/1398999"),
- # TODO(gilliard): Remove live_migrate_paused_instances at juno-eol.
- cfg.BoolOpt('live_migrate_paused_instances',
- default=False,
- help="Does the test system allow live-migration of paused "
- "instances? Note, this is more than just the ANDing of "
- "paused and live_migrate, but all 3 should be set to True "
- "to run those tests"),
cfg.BoolOpt('vnc_console',
default=False,
help='Enable VNC console. This configuration value should '
@@ -394,12 +387,6 @@
cfg.BoolOpt('personality',
default=True,
help='Does the test environment support server personality'),
- # TODO(mriedem): Remove preserve_ports once juno-eol happens.
- cfg.BoolOpt('preserve_ports',
- default=False,
- help='Does Nova preserve preexisting ports from Neutron '
- 'when deleting an instance? This should be set to True '
- 'if testing Kilo+ Nova.'),
cfg.BoolOpt('attach_encrypted_volume',
default=True,
help='Does the test environment support attaching an '
@@ -1384,7 +1371,8 @@
_CONF([], project='tempest')
logging_cfg_path = "%s/logging.conf" % os.path.dirname(path)
- if (not hasattr(_CONF, 'log_config_append') and
+ if ((not hasattr(_CONF, 'log_config_append') or
+ _CONF.log_config_append is None) and
os.path.isfile(logging_cfg_path)):
# if logging conf is in place we need to set log_config_append
_CONF.log_config_append = logging_cfg_path
diff --git a/tempest/scenario/test_network_basic_ops.py b/tempest/scenario/test_network_basic_ops.py
index 33f0ece..4d03ed7 100644
--- a/tempest/scenario/test_network_basic_ops.py
+++ b/tempest/scenario/test_network_basic_ops.py
@@ -626,9 +626,6 @@
"admin_state_up of instance port to True")
@test.idempotent_id('759462e1-8535-46b0-ab3a-33aa45c55aaa')
- @testtools.skipUnless(CONF.compute_feature_enabled.preserve_ports,
- 'Preserving ports on instance delete may not be '
- 'supported in the version of Nova being tested.')
@test.services('compute', 'network')
def test_preserve_preexisting_port(self):
"""Test preserve pre-existing port
diff --git a/tempest/services/network/json/subnetpools_client.py b/tempest/services/network/json/subnetpools_client.py
deleted file mode 100644
index f921bb0..0000000
--- a/tempest/services/network/json/subnetpools_client.py
+++ /dev/null
@@ -1,40 +0,0 @@
-# Copyright 2015 NEC Corporation. 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.services.network.json import base
-
-
-class SubnetpoolsClient(base.BaseNetworkClient):
-
- def list_subnetpools(self, **filters):
- uri = '/subnetpools'
- return self.list_resources(uri, **filters)
-
- def create_subnetpool(self, **kwargs):
- uri = '/subnetpools'
- post_data = {'subnetpool': kwargs}
- return self.create_resource(uri, post_data)
-
- def show_subnetpool(self, subnetpool_id, **fields):
- uri = '/subnetpools/%s' % subnetpool_id
- return self.show_resource(uri, **fields)
-
- def update_subnetpool(self, subnetpool_id, **kwargs):
- uri = '/subnetpools/%s' % subnetpool_id
- post_data = {'subnetpool': kwargs}
- return self.update_resource(uri, post_data)
-
- def delete_subnetpool(self, subnetpool_id):
- uri = '/subnetpools/%s' % subnetpool_id
- return self.delete_resource(uri)
diff --git a/tempest/test.py b/tempest/test.py
index a676cc2..ee3288c 100644
--- a/tempest/test.py
+++ b/tempest/test.py
@@ -234,6 +234,9 @@
log_format = ('%(asctime)s %(process)d %(levelname)-8s '
'[%(name)s] %(message)s')
+ # Client manager class to use in this test case.
+ client_manager = clients.Manager
+
@classmethod
def setUpClass(cls):
# It should never be overridden by descendants
@@ -519,8 +522,8 @@
else:
raise exceptions.InvalidCredentials(
"Invalid credentials type %s" % credential_type)
- return clients.Manager(credentials=creds, service=cls._service,
- api_microversions=cls.services_microversion)
+ return cls.client_manager(credentials=creds, service=cls._service,
+ api_microversions=cls.services_microversion)
@classmethod
def clear_credentials(cls):