summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--doc/source/configuration.rst301
-rw-r--r--etc/accounts.yaml.sample6
-rw-r--r--tempest/api/baremetal/admin/base.py15
-rw-r--r--tempest/api/compute/admin/test_agents.py5
-rw-r--r--tempest/api/compute/admin/test_aggregates.py15
-rw-r--r--tempest/api/compute/admin/test_aggregates_negative.py32
-rw-r--r--tempest/api/compute/admin/test_availability_zone.py6
-rw-r--r--tempest/api/compute/admin/test_availability_zone_negative.py4
-rw-r--r--tempest/api/compute/admin/test_baremetal_nodes.py2
-rw-r--r--tempest/api/compute/admin/test_fixed_ips.py3
-rw-r--r--tempest/api/compute/admin/test_fixed_ips_negative.py10
-rw-r--r--tempest/api/compute/admin/test_flavors.py10
-rw-r--r--tempest/api/compute/admin/test_flavors_access.py2
-rw-r--r--tempest/api/compute/admin/test_flavors_access_negative.py10
-rw-r--r--tempest/api/compute/admin/test_flavors_extra_specs.py3
-rw-r--r--tempest/api/compute/admin/test_flavors_extra_specs_negative.py14
-rw-r--r--tempest/api/compute/admin/test_floating_ips_bulk.py1
-rw-r--r--tempest/api/compute/admin/test_hosts.py5
-rw-r--r--tempest/api/compute/admin/test_hosts_negative.py30
-rw-r--r--tempest/api/compute/admin/test_hypervisor.py7
-rw-r--r--tempest/api/compute/admin/test_hypervisor_negative.py22
-rw-r--r--tempest/api/compute/admin/test_instance_usage_audit_log.py2
-rw-r--r--tempest/api/compute/admin/test_instance_usage_audit_log_negative.py4
-rw-r--r--tempest/api/compute/admin/test_live_migration.py2
-rw-r--r--tempest/api/compute/admin/test_migrations.py2
-rw-r--r--tempest/api/compute/admin/test_quotas.py3
-rw-r--r--tempest/api/compute/admin/test_quotas_negative.py11
-rw-r--r--tempest/api/compute/admin/test_servers.py10
-rw-r--r--tempest/api/compute/admin/test_servers_negative.py16
-rw-r--r--tempest/api/compute/admin/test_services.py4
-rw-r--r--tempest/api/compute/admin/test_services_negative.py8
-rw-r--r--tempest/api/compute/admin/test_simple_tenant_usage.py3
-rw-r--r--tempest/api/compute/admin/test_simple_tenant_usage_negative.py6
-rw-r--r--tempest/api/compute/base.py25
-rw-r--r--tempest/api/compute/certificates/test_certificates.py4
-rw-r--r--tempest/api/compute/flavors/test_flavors.py8
-rw-r--r--tempest/api/compute/floating_ips/test_floating_ips_actions.py4
-rw-r--r--tempest/api/compute/floating_ips/test_floating_ips_actions_negative.py10
-rw-r--r--tempest/api/compute/floating_ips/test_list_floating_ips.py3
-rw-r--r--tempest/api/compute/floating_ips/test_list_floating_ips_negative.py2
-rw-r--r--tempest/api/compute/images/test_image_metadata.py6
-rw-r--r--tempest/api/compute/images/test_image_metadata_negative.py12
-rw-r--r--tempest/api/compute/images/test_images.py1
-rw-r--r--tempest/api/compute/images/test_images_negative.py22
-rw-r--r--tempest/api/compute/images/test_images_oneserver.py1
-rw-r--r--tempest/api/compute/images/test_images_oneserver_negative.py10
-rw-r--r--tempest/api/compute/images/test_list_image_filters.py13
-rw-r--r--tempest/api/compute/images/test_list_image_filters_negative.py2
-rw-r--r--tempest/api/compute/keypairs/test_keypairs.py4
-rw-r--r--tempest/api/compute/keypairs/test_keypairs_negative.py16
-rw-r--r--tempest/api/compute/limits/test_absolute_limits.py1
-rw-r--r--tempest/api/compute/limits/test_absolute_limits_negative.py2
-rw-r--r--tempest/api/compute/security_groups/test_security_groups_negative.py6
-rw-r--r--tempest/api/compute/servers/test_availability_zone.py3
-rw-r--r--tempest/api/compute/servers/test_create_server.py4
-rw-r--r--tempest/api/compute/servers/test_delete_server.py10
-rw-r--r--tempest/api/compute/servers/test_disk_config.py5
-rw-r--r--tempest/api/compute/servers/test_instance_actions.py2
-rw-r--r--tempest/api/compute/servers/test_instance_actions_negative.py4
-rw-r--r--tempest/api/compute/servers/test_list_server_filters.py17
-rw-r--r--tempest/api/compute/servers/test_list_servers_negative.py23
-rw-r--r--tempest/api/compute/servers/test_multiple_create.py2
-rw-r--r--tempest/api/compute/servers/test_multiple_create_negative.py10
-rw-r--r--tempest/api/compute/servers/test_server_actions.py13
-rw-r--r--tempest/api/compute/servers/test_server_addresses_negative.py4
-rw-r--r--tempest/api/compute/servers/test_server_group.py6
-rw-r--r--tempest/api/compute/servers/test_server_metadata.py7
-rw-r--r--tempest/api/compute/servers/test_server_metadata_negative.py24
-rw-r--r--tempest/api/compute/servers/test_server_password.py2
-rw-r--r--tempest/api/compute/servers/test_server_personality.py2
-rw-r--r--tempest/api/compute/servers/test_server_rescue.py2
-rw-r--r--tempest/api/compute/servers/test_server_rescue_negative.py12
-rw-r--r--tempest/api/compute/servers/test_servers.py7
-rw-r--r--tempest/api/compute/servers/test_servers_negative.py98
-rw-r--r--tempest/api/compute/servers/test_virtual_interfaces.py1
-rw-r--r--tempest/api/compute/servers/test_virtual_interfaces_negative.py2
-rw-r--r--tempest/api/compute/test_authorization.py39
-rw-r--r--tempest/api/compute/test_extensions.py4
-rw-r--r--tempest/api/compute/test_live_block_migration_negative.py2
-rw-r--r--tempest/api/compute/test_networks.py1
-rw-r--r--tempest/api/compute/test_tenant_networks.py1
-rw-r--r--tempest/api/compute/volumes/test_attach_volume.py2
-rw-r--r--tempest/api/compute/volumes/test_volumes_list.py6
-rw-r--r--tempest/api/compute/volumes/test_volumes_negative.py18
-rw-r--r--tempest/api/data_processing/base.py311
-rw-r--r--tempest/api/data_processing/test_cluster_templates.py66
-rw-r--r--tempest/api/data_processing/test_node_group_templates.py29
-rw-r--r--tempest/api/database/base.py7
-rw-r--r--tempest/api/database/flavors/test_flavors_negative.py2
-rw-r--r--tempest/api/identity/admin/v2/test_roles.py6
-rw-r--r--tempest/api/identity/admin/v2/test_roles_negative.py40
-rw-r--r--tempest/api/identity/admin/v2/test_services.py1
-rw-r--r--tempest/api/identity/admin/v2/test_tenant_negative.py26
-rw-r--r--tempest/api/identity/admin/v2/test_tenants.py7
-rw-r--r--tempest/api/identity/admin/v2/test_tokens.py2
-rw-r--r--tempest/api/identity/admin/v2/test_users.py3
-rw-r--r--tempest/api/identity/admin/v2/test_users_negative.py42
-rw-r--r--tempest/api/identity/admin/v3/test_endpoints.py2
-rw-r--r--tempest/api/identity/admin/v3/test_endpoints_negative.py8
-rw-r--r--tempest/api/identity/admin/v3/test_list_projects.py4
-rw-r--r--tempest/api/identity/admin/v3/test_list_users.py5
-rw-r--r--tempest/api/identity/admin/v3/test_projects.py8
-rw-r--r--tempest/api/identity/admin/v3/test_projects_negative.py14
-rw-r--r--tempest/api/identity/admin/v3/test_regions.py2
-rw-r--r--tempest/api/identity/admin/v3/test_roles.py1
-rw-r--r--tempest/api/identity/admin/v3/test_tokens.py1
-rw-r--r--tempest/api/identity/admin/v3/test_users.py4
-rw-r--r--tempest/api/identity/base.py30
-rw-r--r--tempest/api/identity/test_extension.py1
-rw-r--r--tempest/api/image/base.py20
-rw-r--r--tempest/api/image/v1/test_image_members.py3
-rw-r--r--tempest/api/image/v1/test_image_members_negative.py8
-rw-r--r--tempest/api/image/v1/test_images.py13
-rw-r--r--tempest/api/image/v1/test_images_negative.py16
-rw-r--r--tempest/api/image/v2/test_images.py13
-rw-r--r--tempest/api/image/v2/test_images_member.py6
-rw-r--r--tempest/api/image/v2/test_images_member_negative.py4
-rw-r--r--tempest/api/image/v2/test_images_negative.py14
-rw-r--r--tempest/api/image/v2/test_images_tags.py1
-rw-r--r--tempest/api/image/v2/test_images_tags_negative.py4
-rw-r--r--tempest/api/messaging/base.py7
-rw-r--r--tempest/api/network/admin/test_floating_ips_admin_actions.py7
-rw-r--r--tempest/api/network/admin/test_load_balancer_admin_actions.py11
-rw-r--r--tempest/api/network/admin/test_quotas.py2
-rw-r--r--tempest/api/network/base.py19
-rw-r--r--tempest/api/network/test_security_groups_negative.py20
-rw-r--r--tempest/api/object_storage/base.py4
-rw-r--r--tempest/api/object_storage/test_account_bulk.py3
-rw-r--r--tempest/api/object_storage/test_account_services_negative.py2
-rw-r--r--tempest/api/object_storage/test_container_acl_negative.py10
-rw-r--r--tempest/api/object_storage/test_container_staticweb.py4
-rw-r--r--tempest/api/object_storage/test_crossdomain.py1
-rw-r--r--tempest/api/object_storage/test_healthcheck.py1
-rw-r--r--tempest/api/object_storage/test_object_expiry.py2
-rw-r--r--tempest/api/object_storage/test_object_formpost.py1
-rw-r--r--tempest/api/object_storage/test_object_formpost_negative.py3
-rw-r--r--tempest/api/object_storage/test_object_services.py14
-rw-r--r--tempest/api/object_storage/test_object_slo.py4
-rw-r--r--tempest/api/object_storage/test_object_temp_url.py5
-rw-r--r--tempest/api/object_storage/test_object_temp_url_negative.py2
-rw-r--r--tempest/api/orchestration/base.py7
-rw-r--r--tempest/api/orchestration/stacks/test_environment.py3
-rw-r--r--tempest/api/orchestration/stacks/test_limits.py2
-rw-r--r--tempest/api/orchestration/stacks/test_neutron_resources.py6
-rw-r--r--tempest/api/orchestration/stacks/test_non_empty_stack.py8
-rw-r--r--tempest/api/orchestration/stacks/test_nova_keypair_resources.py2
-rw-r--r--tempest/api/orchestration/stacks/test_swift_resources.py6
-rw-r--r--tempest/api/orchestration/stacks/test_templates.py2
-rw-r--r--tempest/api/orchestration/stacks/test_templates_negative.py2
-rw-r--r--tempest/api/orchestration/stacks/test_volumes.py2
-rw-r--r--tempest/api/telemetry/base.py3
-rw-r--r--tempest/api/telemetry/test_telemetry_alarming_api.py12
-rw-r--r--tempest/api/telemetry/test_telemetry_notification_api.py1
-rw-r--r--tempest/api/volume/admin/test_multi_backend.py2
-rw-r--r--tempest/api/volume/admin/test_snapshots_actions.py6
-rw-r--r--tempest/api/volume/admin/test_volume_hosts.py1
-rw-r--r--tempest/api/volume/admin/test_volume_quotas.py8
-rw-r--r--tempest/api/volume/admin/test_volume_quotas_negative.py3
-rw-r--r--tempest/api/volume/admin/test_volume_services.py4
-rw-r--r--tempest/api/volume/admin/test_volume_types_extra_specs.py1
-rw-r--r--tempest/api/volume/admin/test_volume_types_extra_specs_negative.py11
-rw-r--r--tempest/api/volume/admin/test_volume_types_negative.py4
-rw-r--r--tempest/api/volume/admin/test_volumes_actions.py2
-rw-r--r--tempest/api/volume/base.py18
-rw-r--r--tempest/api/volume/test_availability_zone.py1
-rw-r--r--tempest/api/volume/test_extensions.py1
-rw-r--r--tempest/api/volume/test_snapshot_metadata.py3
-rw-r--r--tempest/api/volume/test_volume_metadata.py3
-rw-r--r--tempest/api/volume/test_volume_transfers.py19
-rw-r--r--tempest/api/volume/test_volumes_actions.py4
-rw-r--r--tempest/api/volume/test_volumes_extend.py1
-rw-r--r--tempest/api/volume/test_volumes_get.py1
-rw-r--r--tempest/api/volume/test_volumes_list.py11
-rw-r--r--tempest/api/volume/test_volumes_negative.py60
-rw-r--r--tempest/api/volume/test_volumes_snapshots.py5
-rw-r--r--tempest/api/volume/test_volumes_snapshots_negative.py4
-rw-r--r--tempest/api/volume/v2/test_volumes_list.py1
-rw-r--r--tempest/api_schema/response/compute/servers.py238
-rw-r--r--tempest/api_schema/response/compute/v2_1/servers.py390
-rw-r--r--tempest/api_schema/response/compute/version.py6
-rw-r--r--tempest/common/accounts.py10
-rw-r--r--tempest/common/credentials.py22
-rw-r--r--tempest/scenario/manager.py74
-rw-r--r--tempest/scenario/test_aggregates_basic_ops.py18
-rw-r--r--tempest/scenario/test_dashboard_basic_ops.py2
-rw-r--r--tempest/scenario/test_security_groups_basic_ops.py7
-rw-r--r--tempest/services/compute/json/aggregates_client.py4
-rw-r--r--tempest/services/compute/json/availability_zone_client.py18
-rw-r--r--tempest/services/compute/json/baremetal_nodes_client.py2
-rw-r--r--tempest/services/compute/json/certificates_client.py2
-rw-r--r--tempest/services/compute/json/extensions_client.py2
-rw-r--r--tempest/services/compute/json/interfaces_client.py2
-rw-r--r--tempest/services/compute/json/servers_client.py25
-rw-r--r--tempest/services/telemetry/json/telemetry_client.py18
-rw-r--r--tempest/test.py55
-rw-r--r--tempest/tests/test_decorators.py8
-rw-r--r--tempest/thirdparty/boto/test.py7
-rw-r--r--tempest/thirdparty/boto/test_ec2_instance_run.py11
198 files changed, 1470 insertions, 1586 deletions
diff --git a/doc/source/configuration.rst b/doc/source/configuration.rst
index 4fe2e9f9c..b6e00ce7d 100644
--- a/doc/source/configuration.rst
+++ b/doc/source/configuration.rst
@@ -40,6 +40,24 @@ are running. This will be addressed in the future, but is a current limitation.
Eventually the config options for providing credentials to tempest will be
deprecated and removed in favor of the accounts.yaml file.
+Keystone Connection Info
+^^^^^^^^^^^^^^^^^^^^^^^^
+In order for tempest to be able to talk to your OpenStack deployment you need
+to provide it with information about how it communicates with keystone.
+This involves configuring the following options in the identity section:
+
+ #. auth_version
+ #. uri
+ #. uri_v3
+
+The *auth_version* option is used to tell tempest whether it should be using
+keystone's v2 or v3 api for communicating with keystone. (except for the
+identity api tests which will test a specific version) The 2 uri options are
+used to tell tempest the url of the keystone endpoint. The *uri* option is used
+for keystone v2 request and *uri_v3* is used for keystone v3. You want to ensure
+that which ever version you set for *auth_version* has its uri option defined.
+
+
Credential Provider Mechanisms
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
@@ -65,8 +83,16 @@ To enable and use tenant isolation you only need to configure 2 things:
This is also the currently the default credential provider enabled by tempest,
due to it's common use and ease of configuration.
-Locking Test Accounts
-"""""""""""""""""""""
+It is worth pointing out that depending on your cloud configuration you might
+need to assign a role to each of the users created Tempest's tenant isolation.
+This can be set using the *tempest_roles* option. It takes in a list of role
+names each of which will be assigned to each of the users created by tenant
+isolation. This option will not have any effect when set and tempest is not
+configured to use tenant isolation.
+
+
+Locking Test Accounts (aka accounts.yaml or accounts file)
+""""""""""""""""""""""""""""""""""""""""""""""""""""""""""
For a long time using tenant isolation was the only method available if you
wanted to enable parallel execution of tempest tests. However this was
insufficient for certain use cases because of the admin credentials requirement
@@ -77,11 +103,6 @@ test accounts each test class will reserve a set of credentials from the
accounts.yaml before executing any of its tests so that each class is isolated
like in tenant isolation.
-Currently, this mechanism has some limitations, mostly around networking. The
-locking test accounts provider will only work with a single flat network as
-the default for each tenant/project. If another network configuration is used
-in your cloud you might face unexpected failures.
-
To enable and use locking test accounts you need do a few things:
#. Create a accounts.yaml file which contains the set of pre-existing
@@ -94,20 +115,20 @@ To enable and use locking test accounts you need do a few things:
#. Provide tempest with the location of you accounts.yaml file with the
test_accounts_file option in the auth section
+It is worth pointing out that each set of credentials in the accounts.yaml
+should have a unique tenant. This is required to provide proper isolation
+to the tests using the credentials, and failure to do this will likely cause
+unexpected failures in some tests.
-Non-locking test accounts
-"""""""""""""""""""""""""
-When tempest was refactored to allow for locking test accounts, the original
-non-tenant isolated case was converted to support the new accounts.yaml file.
-This mechanism is the non-locking test accounts provider. It only makes sense
-to use it if parallel execution isn't needed. If the role restrictions were too
-limiting with the locking accounts provider and tenant isolation is not wanted
-then you can use the non-locking test accounts credential provider without the
-accounts.yaml file.
-To use the non-locking test accounts provider you have 2 ways to configure it.
-First you can specify the sets of credentials in the configuration file like
-detailed above with following 9 options in the identity section:
+Non-locking test accounts (aka credentials config options)
+""""""""""""""""""""""""""""""""""""""""""""""""""""""""""
+When Tempest was refactored to allow for locking test accounts, the original
+non-tenant isolated case was converted to internally work similarly to the
+accounts.yaml file. This mechanism was then called the non-locking test accounts
+provider. To use the non-locking test accounts provider you can specify the sets
+of credentials in the configuration file like detailed above with following 9
+options in the identity section:
#. username
#. password
@@ -119,7 +140,241 @@ detailed above with following 9 options in the identity section:
#. alt_password
#. alt_tenant_name
-The only restriction with using the traditional config options for credentials
-is that if a test requires specific roles on accounts these tests can not be
-run. This is because the config options do not give sufficient flexibility to
-describe the roles assigned to a user for running the tests.
+It only makes sense to use it if parallel execution isn't needed, since tempest
+won't be able to properly isolate tests using this. Additionally, using the
+traditional config options for credentials is not able to provide credentials to
+tests which requires specific roles on accounts. This is because the config
+options do not give sufficient flexibility to describe the roles assigned to a
+user for running the tests. There are additional limitations with regard to
+network configuration when using this credential provider mechanism, see the
+`Networking`_ section below.
+
+Compute
+-------
+
+Flavors
+^^^^^^^
+For tempest to be able to create servers you need to specify flavors that it
+can use to boot the servers with. There are 2 options in the tempest config
+for doing this:
+
+ #. flavor_ref
+ #. flavor_ref_alt
+
+Both of these options are in the compute section of the config file and take
+in the flavor id (not the name) from nova. The *flavor_ref* option is what will
+be used for booting almost all of the guests, *flavor_ref_alt* is only used in
+tests where 2 different sized servers are required. (for example a resize test)
+
+Using a smaller flavor is generally recommended, when larger flavors are used
+the extra time required to bring up servers will likely affect total run time
+and probably require tweaking timeout values to ensure tests have ample time to
+finish.
+
+Images
+^^^^^^
+Just like with flavors, tempest needs to know which images to use for booting
+servers. There are 2 options in the compute section just like with flavors:
+
+ #. image_ref
+ #. image_ref_alt
+
+Both options are expecting an image id (not name) from nova. The *image_ref*
+option is what what will be used for booting the majority of servers in tempest.
+*image_ref_alt* is used for tests that require 2 images such as rebuild. If 2
+images are not available you can set both options to the same image_ref and
+those tests will be skipped.
+
+There are also options in the scenario section for images:
+
+ #. img_file
+ #. img_dir
+ #. aki_img_file
+ #. ari_img_file
+ #. ami_img_file
+ #. img_container_format
+ #. img_disk_format
+
+however unlike the other image options these are used for a very small subset
+of scenario tests which are uploading an image. These options are used to tell
+tempest where an image file is located and describe it's metadata for when it's
+uploaded.
+
+The behavior of these options is a bit convoluted (which will likely be fixed
+in future versions). You first need to specify *img_dir*, which is the directory
+tempest will look for the image files in. First it will check if the filename
+set for *img_file* could be found in *img_dir*. If it is found then the
+*img_container_format* and *img_disk_format* options are used to upload that
+image to glance. However if it's not found tempest will look for the 3 uec image
+file name options as a fallback. If neither is found the tests requiring an
+image to upload will fail.
+
+It is worth pointing out that using `cirros`_ is a very good choice for running
+tempest. It's what is used for upstream testing, they boot quickly and have a
+small footprint.
+
+.. _cirros: https://launchpad.net/cirros
+
+Networking
+----------
+OpenStack has a myriad of different networking configurations possible and
+depending on which of the 2 network backends, nova-network or neutron, you are
+using things can vary drastically. Due to this complexity Tempest has to provide
+a certain level of flexibility in it's configuration to ensure it will work
+against any cloud. This ends up causing a large number of permutations in
+Tempest's config around network configuration.
+
+
+Enabling Remote Access to Created Servers
+^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
+When Tempest creates servers for testing, some tests require being able to
+connect those servers. Depending on the configuration of the cloud, the methods
+for doing this can be different. In certain configurations it is required to
+specify a single network with server create calls. Accordingly, Tempest provides
+a few different methods for providing this information in configuration to try
+and ensure that regardless of the clouds configuration it'll still be able to
+run. This section covers the different methods of configuring Tempest to provide
+a network when creating servers.
+
+Fixed Network Name
+""""""""""""""""""
+This is the simplest method of specifying how networks should be used. You can
+just specify a single network name/label to use for all server creations. The
+limitation with this is that all tenants/projects and users must be able to see
+that network name/label if they were to perform a network list and be able to
+use it.
+
+If no network name is assigned in the config file and none of the below
+alternatives are used, then Tempest will not specify a network on server
+creations, which depending on the cloud configuration might prevent them from
+booting.
+
+To set a fixed network name simply do:
+
+ #. Set the fixed_network_name option in the compute group
+
+In the case that the configured fixed network name can not be found by a user
+network list call, it will be treated like one was not provided except that a
+warning will be logged stating that it couldn't be found.
+
+
+Accounts File
+"""""""""""""
+If you are using an accounts file to provide credentials for running Tempest
+then you can leverage it to also specify which network should be used with
+server creations on a per tenant/project and user pair basis. This provides
+the necessary flexibility to work with more intricate networking configurations
+by enabling the user to specify exactly which network to use for which
+tenants/projects. You can refer to the accounts.yaml sample file included in
+the tempest repo for the syntax around specifying networks in the file.
+
+However, specifying a network is not required when using an accounts file. If
+one is not specified you can use a fixed network name to specify the network to
+use when creating servers just as without an accounts file. However, any network
+specified in the accounts file will take precedence over the fixed network name
+provided. If no network is provided in the accounts file and a fixed network
+name is not set then no network will be included in create server requests.
+
+If a fixed network is provided and the accounts.yaml file also contains networks
+this has the benefit of enabling a couple more tests which require a static
+network to perform operations like server lists with a network filter. If a
+fixed network name is not provided these tests are skipped. Additionally, if a
+fixed network name is provided it will serve as a fallback in case of a
+misconfiguration or a missing network in the accounts file.
+
+
+With Tenant Isolation
+"""""""""""""""""""""
+With tenant isolation enabled and using nova-network then nothing changes. Your
+only option for configuration is to either set a fixed network name or not.
+However, in most cases it shouldn't matter because nova-network should have no
+problem booting a server with multiple networks. If this is not the case for
+your cloud then using an accounts file is recommended because it provides the
+necessary flexibility to describe your configuration. Tenant isolation is not
+able to dynamically allocate things as necessary if neutron is not enabled.
+
+With neutron and tenant isolation enabled there should not be any additional
+configuration necessary to enable Tempest to create servers with working
+networking, assuming you have properly configured the network section to work
+for your cloud. Tempest will dynamically create the neutron resources necessary
+to enable using servers with that network. Also, just as with the accounts
+file, if you specify a fixed network name while using neutron and tenant
+isolation it will enable running tests which require a static network and it
+will additionally be used as a fallback for server creation. However, unlike
+accounts.yaml this should never be triggered.
+
+Configuring Available Services
+------------------------------
+OpenStack is really a constellation of several different projects which
+are running together to create a cloud. However which projects you're running
+is not set in stone, and which services are running is up to the deployer.
+Tempest however needs to know which services are available so it can figure
+out which tests it is able to run and certain setup steps which differ based
+on the available services.
+
+The *service_available* section of the config file is used to set which
+services are available. It contains a boolean option for each service (except
+for keystone which is a hard requirement) set it to True if the service is
+available or False if it is not.
+
+Service Catalog
+^^^^^^^^^^^^^^^
+Each project which has its own REST API contains an entry in the service
+catalog. Like most things in OpenStack this is also completely configurable.
+However, for tempest to be able to figure out the endpoints to send REST API
+calls for each service to it needs to know how that project is defined in the
+service catalog. There are 3 options for each service section to accomplish
+this:
+
+ #. catalog_type
+ #. endpoint_type
+ #. region
+
+Setting *catalog_type* and *endpoint_type* should normally give Tempest enough
+information to determine which endpoint it should pull from the service
+catalog to use for talking to that particular service. However, if you're cloud
+has multiple regions available and you need to specify a particular one to use
+a service you can set the *region* option in that service's section.
+
+It should also be noted that the default values for these options are set
+to what devstack uses. (which is a de facto standard for service catalog
+entries) So often nothing actually needs to be set on these options to enable
+communication to a particular service. It is only if you are either not using
+the same *catalog_type* as devstack or you want Tempest to talk to a different
+endpoint type instead of publicURL for a service that these need to be changed.
+
+
+Service feature configuration
+-----------------------------
+
+OpenStack provides its deployers a myriad of different configuration options
+to enable anyone deploying it to create a cloud tailor-made for any individual
+use case. It provides options for several different backend type, databases,
+message queues, etc. However, the downside to this configurability is that
+certain operations and features aren't supported depending on the configuration.
+These features may or may not be discoverable from the API so the burden is
+often on the user to figure out what the cloud they're talking to supports.
+Besides the obvious interoperability issues with this it also leaves Tempest
+in an interesting situation trying to figure out which tests are expected to
+work. However, Tempest tests do not rely on dynamic api discovery for a feature
+(assuming one exists). Instead Tempest has to be explicitly configured as to
+which optional features are enabled. This is in order to prevent bugs in the
+discovery mechanisms from masking failures.
+
+The service feature-enabled config sections are how Tempest addresses the
+optional feature question. Each service that has tests for optional features
+contains one of these sections. The only options in it are boolean options
+with the name of a feature which is used. If it is set to false any test which
+depends on that functionality will be skipped. For a complete list of all these
+options refer to the sample config file.
+
+
+API Extensions
+^^^^^^^^^^^^^^
+The service feature-enabled sections often contain an *api-extensions* option
+(or in the case of swift a *discoverable_apis* option) this is used to tell
+tempest which api extensions (or configurable middleware) is used in your
+deployment. It has 2 valid config states, either it contains a single value
+"all" (which is the default) which means that every api extension is assumed
+to be enabled, or it is set to a list of each individual extension that is
+enabled for that service.
diff --git a/etc/accounts.yaml.sample b/etc/accounts.yaml.sample
index 31ceb3325..3f57eb76e 100644
--- a/etc/accounts.yaml.sample
+++ b/etc/accounts.yaml.sample
@@ -1,4 +1,7 @@
# The number of accounts required can be estimated as CONCURRENCY x 2
+# It is expected that each user provided here will be in a different tenant.
+# This is required to provide isolation between test for running in parallel
+#
# Valid fields for credentials are defined in the descendants of
# auth.Credentials - see KeystoneV[2|3]Credentials.CONF_ATTRIBUTES
@@ -28,6 +31,9 @@
- 'reseller_admin'
- 'operator'
+# Networks can be specified to tell tempest which network it should use when
+# creating servers with an account
+
- username: 'admin_user_1'
tenant_name: 'admin_tenant_1'
password: 'test_password'
diff --git a/tempest/api/baremetal/admin/base.py b/tempest/api/baremetal/admin/base.py
index 9aeea0ae9..0b5d7d959 100644
--- a/tempest/api/baremetal/admin/base.py
+++ b/tempest/api/baremetal/admin/base.py
@@ -15,8 +15,6 @@ import functools
from tempest_lib.common.utils import data_utils
from tempest_lib import exceptions as lib_exc
-from tempest import clients
-from tempest.common import credentials
from tempest import config
from tempest import test
@@ -54,6 +52,8 @@ def creates(resource):
class BaseBaremetalTest(test.BaseTestCase):
"""Base class for Baremetal API tests."""
+ credentials = ['admin']
+
@classmethod
def skip_checks(cls):
super(BaseBaremetalTest, cls).skip_checks()
@@ -68,18 +68,9 @@ class BaseBaremetalTest(test.BaseTestCase):
raise cls.skipException(skip_msg)
@classmethod
- def setup_credentials(cls):
- super(BaseBaremetalTest, cls).setup_credentials()
- if (not hasattr(cls, 'isolated_creds') or
- not cls.isolated_creds.name == cls.__name__):
- cls.isolated_creds = credentials.get_isolated_credentials(
- name=cls.__name__, network_resources=cls.network_resources)
- cls.mgr = clients.Manager(cls.isolated_creds.get_admin_creds())
-
- @classmethod
def setup_clients(cls):
super(BaseBaremetalTest, cls).setup_clients()
- cls.client = cls.mgr.baremetal_client
+ cls.client = cls.os_admin.baremetal_client
@classmethod
def resource_setup(cls):
diff --git a/tempest/api/compute/admin/test_agents.py b/tempest/api/compute/admin/test_agents.py
index aa29b3663..c9a73c7c2 100644
--- a/tempest/api/compute/admin/test_agents.py
+++ b/tempest/api/compute/admin/test_agents.py
@@ -60,7 +60,6 @@ class AgentsAdminTestJSON(base.BaseV2ComputeAdminTest):
kwargs[rand_key] = data_utils.rand_name(kwargs[rand_key])
return kwargs
- @test.attr(type='gate')
@test.idempotent_id('1fc6bdc8-0b6d-4cc7-9f30-9b04fabe5b90')
def test_create_agent(self):
# Create an agent.
@@ -73,7 +72,6 @@ class AgentsAdminTestJSON(base.BaseV2ComputeAdminTest):
for expected_item, value in params.items():
self.assertEqual(value, body[expected_item])
- @test.attr(type='gate')
@test.idempotent_id('dc9ffd51-1c50-4f0e-a820-ae6d2a568a9e')
def test_update_agent(self):
# Update an agent.
@@ -84,7 +82,6 @@ class AgentsAdminTestJSON(base.BaseV2ComputeAdminTest):
for expected_item, value in params.items():
self.assertEqual(value, body[expected_item])
- @test.attr(type='gate')
@test.idempotent_id('470e0b89-386f-407b-91fd-819737d0b335')
def test_delete_agent(self):
# Delete an agent.
@@ -94,7 +91,6 @@ class AgentsAdminTestJSON(base.BaseV2ComputeAdminTest):
agents = self.client.list_agents()
self.assertNotIn(self.agent_id, map(lambda x: x['agent_id'], agents))
- @test.attr(type='gate')
@test.idempotent_id('6a326c69-654b-438a-80a3-34bcc454e138')
def test_list_agents(self):
# List all agents.
@@ -102,7 +98,6 @@ class AgentsAdminTestJSON(base.BaseV2ComputeAdminTest):
self.assertTrue(len(agents) > 0, 'Cannot get any agents.(%s)' % agents)
self.assertIn(self.agent_id, map(lambda x: x['agent_id'], agents))
- @test.attr(type='gate')
@test.idempotent_id('eabadde4-3cd7-4ec4-a4b5-5a936d2d4408')
def test_list_agents_with_filter(self):
# List the agent builds by the filter.
diff --git a/tempest/api/compute/admin/test_aggregates.py b/tempest/api/compute/admin/test_aggregates.py
index 3a34a2e2e..35a647957 100644
--- a/tempest/api/compute/admin/test_aggregates.py
+++ b/tempest/api/compute/admin/test_aggregates.py
@@ -53,7 +53,6 @@ class AggregatesAdminTestJSON(base.BaseV2ComputeAdminTest):
except lib_exc.NotFound:
pass
- @test.attr(type='gate')
@test.idempotent_id('0d148aa3-d54c-4317-aa8d-42040a475e20')
def test_aggregate_create_delete(self):
# Create and delete an aggregate.
@@ -66,7 +65,6 @@ class AggregatesAdminTestJSON(base.BaseV2ComputeAdminTest):
self.client.delete_aggregate(aggregate['id'])
self.client.wait_for_resource_deletion(aggregate['id'])
- @test.attr(type='gate')
@test.idempotent_id('5873a6f8-671a-43ff-8838-7ce430bb6d0b')
def test_aggregate_create_delete_with_az(self):
# Create and delete an aggregate.
@@ -81,7 +79,6 @@ class AggregatesAdminTestJSON(base.BaseV2ComputeAdminTest):
self.client.delete_aggregate(aggregate['id'])
self.client.wait_for_resource_deletion(aggregate['id'])
- @test.attr(type='gate')
@test.idempotent_id('68089c38-04b1-4758-bdf0-cf0daec4defd')
def test_aggregate_create_verify_entry_in_list(self):
# Create an aggregate and ensure it is listed.
@@ -94,7 +91,6 @@ class AggregatesAdminTestJSON(base.BaseV2ComputeAdminTest):
map(lambda x: (x['id'], x['availability_zone']),
aggregates))
- @test.attr(type='gate')
@test.idempotent_id('36ec92ca-7a73-43bc-b920-7531809e8540')
def test_aggregate_create_update_metadata_get_details(self):
# Create an aggregate and ensure its details are returned.
@@ -102,7 +98,7 @@ class AggregatesAdminTestJSON(base.BaseV2ComputeAdminTest):
aggregate = self.client.create_aggregate(name=aggregate_name)
self.addCleanup(self.client.delete_aggregate, aggregate['id'])
- body = self.client.get_aggregate(aggregate['id'])
+ body = self.client.show_aggregate(aggregate['id'])
self.assertEqual(aggregate['name'], body['name'])
self.assertEqual(aggregate['availability_zone'],
body['availability_zone'])
@@ -114,10 +110,9 @@ class AggregatesAdminTestJSON(base.BaseV2ComputeAdminTest):
self.assertEqual(meta, body["metadata"])
# verify the metadata has been set
- body = self.client.get_aggregate(aggregate['id'])
+ body = self.client.show_aggregate(aggregate['id'])
self.assertEqual(meta, body["metadata"])
- @test.attr(type='gate')
@test.idempotent_id('4d2b2004-40fa-40a1-aab2-66f4dab81beb')
def test_aggregate_create_update_with_az(self):
# Update an aggregate and ensure properties are updated correctly
@@ -147,7 +142,6 @@ class AggregatesAdminTestJSON(base.BaseV2ComputeAdminTest):
(x['id'], x['name'], x['availability_zone']),
aggregates))
- @test.attr(type='gate')
@test.idempotent_id('c8e85064-e79b-4906-9931-c11c24294d02')
def test_aggregate_add_remove_host(self):
# Add an host to the given aggregate and remove.
@@ -168,7 +162,6 @@ class AggregatesAdminTestJSON(base.BaseV2ComputeAdminTest):
body['availability_zone'])
self.assertNotIn(self.host, body['hosts'])
- @test.attr(type='gate')
@test.idempotent_id('7f6a1cc5-2446-4cdb-9baa-b6ae0a919b72')
def test_aggregate_add_host_list(self):
# Add an host to the given aggregate and list.
@@ -187,7 +180,6 @@ class AggregatesAdminTestJSON(base.BaseV2ComputeAdminTest):
self.assertIsNone(agg['availability_zone'])
self.assertIn(self.host, agg['hosts'])
- @test.attr(type='gate')
@test.idempotent_id('eeef473c-7c52-494d-9f09-2ed7fc8fc036')
def test_aggregate_add_host_get_details(self):
# Add an host to the given aggregate and get details.
@@ -198,12 +190,11 @@ class AggregatesAdminTestJSON(base.BaseV2ComputeAdminTest):
self.client.add_host(aggregate['id'], self.host)
self.addCleanup(self.client.remove_host, aggregate['id'], self.host)
- body = self.client.get_aggregate(aggregate['id'])
+ body = self.client.show_aggregate(aggregate['id'])
self.assertEqual(aggregate_name, body['name'])
self.assertIsNone(body['availability_zone'])
self.assertIn(self.host, body['hosts'])
- @test.attr(type='gate')
@test.idempotent_id('96be03c7-570d-409c-90f8-e4db3c646996')
def test_aggregate_add_host_create_server_with_az(self):
# Add an host to the given aggregate and create a server.
diff --git a/tempest/api/compute/admin/test_aggregates_negative.py b/tempest/api/compute/admin/test_aggregates_negative.py
index f6d6ad3f8..6942fdb0c 100644
--- a/tempest/api/compute/admin/test_aggregates_negative.py
+++ b/tempest/api/compute/admin/test_aggregates_negative.py
@@ -44,7 +44,7 @@ class AggregatesAdminNegativeTestJSON(base.BaseV2ComputeAdminTest):
filter(lambda y: y['service'] == 'compute', hosts_all))
cls.host = hosts[0]
- @test.attr(type=['negative', 'gate'])
+ @test.attr(type=['negative'])
@test.idempotent_id('86a1cb14-da37-4a70-b056-903fd56dfe29')
def test_aggregate_create_as_user(self):
# Regular user is not allowed to create an aggregate.
@@ -53,7 +53,7 @@ class AggregatesAdminNegativeTestJSON(base.BaseV2ComputeAdminTest):
self.user_client.create_aggregate,
name=aggregate_name)
- @test.attr(type=['negative', 'gate'])
+ @test.attr(type=['negative'])
@test.idempotent_id('3b8a1929-3793-4e92-bcb4-dfa572ee6c1d')
def test_aggregate_create_aggregate_name_length_less_than_1(self):
# the length of aggregate name should >= 1 and <=255
@@ -61,7 +61,7 @@ class AggregatesAdminNegativeTestJSON(base.BaseV2ComputeAdminTest):
self.client.create_aggregate,
name='')
- @test.attr(type=['negative', 'gate'])
+ @test.attr(type=['negative'])
@test.idempotent_id('4c194563-543b-4e70-a719-557bbe947fac')
def test_aggregate_create_aggregate_name_length_exceeds_255(self):
# the length of aggregate name should >= 1 and <=255
@@ -70,7 +70,7 @@ class AggregatesAdminNegativeTestJSON(base.BaseV2ComputeAdminTest):
self.client.create_aggregate,
name=aggregate_name)
- @test.attr(type=['negative', 'gate'])
+ @test.attr(type=['negative'])
@test.idempotent_id('9c23a291-b0b1-487b-b464-132e061151b3')
def test_aggregate_create_with_existent_aggregate_name(self):
# creating an aggregate with existent aggregate name is forbidden
@@ -82,7 +82,7 @@ class AggregatesAdminNegativeTestJSON(base.BaseV2ComputeAdminTest):
self.client.create_aggregate,
name=aggregate_name)
- @test.attr(type=['negative', 'gate'])
+ @test.attr(type=['negative'])
@test.idempotent_id('cd6de795-c15d-45f1-8d9e-813c6bb72a3d')
def test_aggregate_delete_as_user(self):
# Regular user is not allowed to delete an aggregate.
@@ -94,14 +94,14 @@ class AggregatesAdminNegativeTestJSON(base.BaseV2ComputeAdminTest):
self.user_client.delete_aggregate,
aggregate['id'])
- @test.attr(type=['negative', 'gate'])
+ @test.attr(type=['negative'])
@test.idempotent_id('b7d475a6-5dcd-4ff4-b70a-cd9de66a6672')
def test_aggregate_list_as_user(self):
# Regular user is not allowed to list aggregates.
self.assertRaises(lib_exc.Forbidden,
self.user_client.list_aggregates)
- @test.attr(type=['negative', 'gate'])
+ @test.attr(type=['negative'])
@test.idempotent_id('557cad12-34c9-4ff4-95f0-22f0dfbaf7dc')
def test_aggregate_get_details_as_user(self):
# Regular user is not allowed to get aggregate details.
@@ -110,24 +110,24 @@ class AggregatesAdminNegativeTestJSON(base.BaseV2ComputeAdminTest):
self.addCleanup(self.client.delete_aggregate, aggregate['id'])
self.assertRaises(lib_exc.Forbidden,
- self.user_client.get_aggregate,
+ self.user_client.show_aggregate,
aggregate['id'])
- @test.attr(type=['negative', 'gate'])
+ @test.attr(type=['negative'])
@test.idempotent_id('c74f4bf1-4708-4ff2-95a0-f49eaca951bd')
def test_aggregate_delete_with_invalid_id(self):
# Delete an aggregate with invalid id should raise exceptions.
self.assertRaises(lib_exc.NotFound,
self.client.delete_aggregate, -1)
- @test.attr(type=['negative', 'gate'])
+ @test.attr(type=['negative'])
@test.idempotent_id('3c916244-2c46-49a4-9b55-b20bb0ae512c')
def test_aggregate_get_details_with_invalid_id(self):
# Get aggregate details with invalid id should raise exceptions.
self.assertRaises(lib_exc.NotFound,
- self.client.get_aggregate, -1)
+ self.client.show_aggregate, -1)
- @test.attr(type=['negative', 'gate'])
+ @test.attr(type=['negative'])
@test.idempotent_id('0ef07828-12b4-45ba-87cc-41425faf5711')
def test_aggregate_add_non_exist_host(self):
# Adding a non-exist host to an aggregate should raise exceptions.
@@ -145,7 +145,7 @@ class AggregatesAdminNegativeTestJSON(base.BaseV2ComputeAdminTest):
self.assertRaises(lib_exc.NotFound, self.client.add_host,
aggregate['id'], non_exist_host)
- @test.attr(type=['negative', 'gate'])
+ @test.attr(type=['negative'])
@test.idempotent_id('7324c334-bd13-4c93-8521-5877322c3d51')
def test_aggregate_add_host_as_user(self):
# Regular user is not allowed to add a host to an aggregate.
@@ -157,7 +157,7 @@ class AggregatesAdminNegativeTestJSON(base.BaseV2ComputeAdminTest):
self.user_client.add_host,
aggregate['id'], self.host)
- @test.attr(type=['negative', 'gate'])
+ @test.attr(type=['negative'])
@test.idempotent_id('19dd44e1-c435-4ee1-a402-88c4f90b5950')
def test_aggregate_add_existent_host(self):
self.useFixture(fixtures.LockFixture('availability_zone'))
@@ -171,7 +171,7 @@ class AggregatesAdminNegativeTestJSON(base.BaseV2ComputeAdminTest):
self.assertRaises(lib_exc.Conflict, self.client.add_host,
aggregate['id'], self.host)
- @test.attr(type=['negative', 'gate'])
+ @test.attr(type=['negative'])
@test.idempotent_id('7a53af20-137a-4e44-a4ae-e19260e626d9')
def test_aggregate_remove_host_as_user(self):
# Regular user is not allowed to remove a host from an aggregate.
@@ -186,7 +186,7 @@ class AggregatesAdminNegativeTestJSON(base.BaseV2ComputeAdminTest):
self.user_client.remove_host,
aggregate['id'], self.host)
- @test.attr(type=['negative', 'gate'])
+ @test.attr(type=['negative'])
@test.idempotent_id('95d6a6fa-8da9-4426-84d0-eec0329f2e4d')
def test_aggregate_remove_nonexistent_host(self):
non_exist_host = data_utils.rand_name('nonexist_host')
diff --git a/tempest/api/compute/admin/test_availability_zone.py b/tempest/api/compute/admin/test_availability_zone.py
index eadc15a8c..22eae03c2 100644
--- a/tempest/api/compute/admin/test_availability_zone.py
+++ b/tempest/api/compute/admin/test_availability_zone.py
@@ -28,16 +28,14 @@ class AZAdminV2TestJSON(base.BaseComputeAdminTest):
super(AZAdminV2TestJSON, cls).setup_clients()
cls.client = cls.availability_zone_admin_client
- @test.attr(type='gate')
@test.idempotent_id('d3431479-8a09-4f76-aa2d-26dc580cb27c')
def test_get_availability_zone_list(self):
# List of availability zone
- availability_zone = self.client.get_availability_zone_list()
+ availability_zone = self.client.list_availability_zones()
self.assertTrue(len(availability_zone) > 0)
- @test.attr(type='gate')
@test.idempotent_id('ef726c58-530f-44c2-968c-c7bed22d5b8c')
def test_get_availability_zone_list_detail(self):
# List of availability zones and available services
- availability_zone = self.client.get_availability_zone_list_detail()
+ availability_zone = self.client.list_availability_zones(detail=True)
self.assertTrue(len(availability_zone) > 0)
diff --git a/tempest/api/compute/admin/test_availability_zone_negative.py b/tempest/api/compute/admin/test_availability_zone_negative.py
index d6e577e6b..be1c2898f 100644
--- a/tempest/api/compute/admin/test_availability_zone_negative.py
+++ b/tempest/api/compute/admin/test_availability_zone_negative.py
@@ -29,11 +29,11 @@ class AZAdminNegativeTestJSON(base.BaseV2ComputeAdminTest):
super(AZAdminNegativeTestJSON, cls).setup_clients()
cls.non_adm_client = cls.availability_zone_client
- @test.attr(type=['negative', 'gate'])
+ @test.attr(type=['negative'])
@test.idempotent_id('bf34dca2-fdc3-4073-9c02-7648d9eae0d7')
def test_get_availability_zone_list_detail_with_non_admin_user(self):
# List of availability zones and available services with
# non-administrator user
self.assertRaises(
lib_exc.Forbidden,
- self.non_adm_client.get_availability_zone_list_detail)
+ self.non_adm_client.list_availability_zones, detail=True)
diff --git a/tempest/api/compute/admin/test_baremetal_nodes.py b/tempest/api/compute/admin/test_baremetal_nodes.py
index 64099c391..9b8893812 100644
--- a/tempest/api/compute/admin/test_baremetal_nodes.py
+++ b/tempest/api/compute/admin/test_baremetal_nodes.py
@@ -52,5 +52,5 @@ class BaremetalNodesAdminTestJSON(base.BaseV2ComputeAdminTest):
# Test getting each individually
for node in test_nodes:
- baremetal_node = self.client.get_baremetal_node(node['uuid'])
+ baremetal_node = self.client.show_baremetal_node(node['uuid'])
self.assertEqual(node['uuid'], baremetal_node['id'])
diff --git a/tempest/api/compute/admin/test_fixed_ips.py b/tempest/api/compute/admin/test_fixed_ips.py
index acfd659fb..eec468818 100644
--- a/tempest/api/compute/admin/test_fixed_ips.py
+++ b/tempest/api/compute/admin/test_fixed_ips.py
@@ -47,21 +47,18 @@ class FixedIPsTestJson(base.BaseV2ComputeAdminTest):
if cls.ip:
break
- @test.attr(type='gate')
@test.idempotent_id('16b7d848-2f7c-4709-85a3-2dfb4576cc52')
@test.services('network')
def test_list_fixed_ip_details(self):
fixed_ip = self.client.get_fixed_ip_details(self.ip)
self.assertEqual(fixed_ip['address'], self.ip)
- @test.attr(type='gate')
@test.idempotent_id('5485077b-7e46-4cec-b402-91dc3173433b')
@test.services('network')
def test_set_reserve(self):
body = {"reserve": "None"}
self.client.reserve_fixed_ip(self.ip, body)
- @test.attr(type='gate')
@test.idempotent_id('7476e322-b9ff-4710-bf82-49d51bac6e2e')
@test.services('network')
def test_set_unreserve(self):
diff --git a/tempest/api/compute/admin/test_fixed_ips_negative.py b/tempest/api/compute/admin/test_fixed_ips_negative.py
index 052ed71ff..ac8a60d5e 100644
--- a/tempest/api/compute/admin/test_fixed_ips_negative.py
+++ b/tempest/api/compute/admin/test_fixed_ips_negative.py
@@ -49,14 +49,14 @@ class FixedIPsNegativeTestJson(base.BaseV2ComputeAdminTest):
if cls.ip:
break
- @test.attr(type=['negative', 'gate'])
+ @test.attr(type=['negative'])
@test.idempotent_id('9f17f47d-daad-4adc-986e-12370c93e407')
@test.services('network')
def test_list_fixed_ip_details_with_non_admin_user(self):
self.assertRaises(lib_exc.Forbidden,
self.non_admin_client.get_fixed_ip_details, self.ip)
- @test.attr(type=['negative', 'gate'])
+ @test.attr(type=['negative'])
@test.idempotent_id('ce60042c-fa60-4836-8d43-1c8e3359dc47')
@test.services('network')
def test_set_reserve_with_non_admin_user(self):
@@ -65,7 +65,7 @@ class FixedIPsNegativeTestJson(base.BaseV2ComputeAdminTest):
self.non_admin_client.reserve_fixed_ip,
self.ip, body)
- @test.attr(type=['negative', 'gate'])
+ @test.attr(type=['negative'])
@test.idempotent_id('f1f7a35b-0390-48c5-9803-5f27461439db')
@test.services('network')
def test_set_unreserve_with_non_admin_user(self):
@@ -74,7 +74,7 @@ class FixedIPsNegativeTestJson(base.BaseV2ComputeAdminTest):
self.non_admin_client.reserve_fixed_ip,
self.ip, body)
- @test.attr(type=['negative', 'gate'])
+ @test.attr(type=['negative'])
@test.idempotent_id('f51cf464-7fc5-4352-bc3e-e75cfa2cb717')
@test.services('network')
def test_set_reserve_with_invalid_ip(self):
@@ -88,7 +88,7 @@ class FixedIPsNegativeTestJson(base.BaseV2ComputeAdminTest):
self.client.reserve_fixed_ip,
"my.invalid.ip", body)
- @test.attr(type=['negative', 'gate'])
+ @test.attr(type=['negative'])
@test.idempotent_id('fd26ef50-f135-4232-9d32-281aab3f9176')
@test.services('network')
def test_fixed_ip_with_invalid_action(self):
diff --git a/tempest/api/compute/admin/test_flavors.py b/tempest/api/compute/admin/test_flavors.py
index df4624c73..8aab8da8c 100644
--- a/tempest/api/compute/admin/test_flavors.py
+++ b/tempest/api/compute/admin/test_flavors.py
@@ -87,21 +87,18 @@ class FlavorsAdminTestJSON(base.BaseV2ComputeAdminTest):
return flavor['id']
- @test.attr(type='gate')
@test.idempotent_id('8b4330e1-12c4-4554-9390-e6639971f086')
def test_create_flavor_with_int_id(self):
flavor_id = data_utils.rand_int_id(start=1000)
new_flavor_id = self._create_flavor(flavor_id)
self.assertEqual(new_flavor_id, str(flavor_id))
- @test.attr(type='gate')
@test.idempotent_id('94c9bb4e-2c2a-4f3c-bb1f-5f0daf918e6d')
def test_create_flavor_with_uuid_id(self):
flavor_id = str(uuid.uuid4())
new_flavor_id = self._create_flavor(flavor_id)
self.assertEqual(new_flavor_id, flavor_id)
- @test.attr(type='gate')
@test.idempotent_id('f83fe669-6758-448a-a85e-32d351f36fe0')
def test_create_flavor_with_none_id(self):
# If nova receives a request with None as flavor_id,
@@ -110,7 +107,6 @@ class FlavorsAdminTestJSON(base.BaseV2ComputeAdminTest):
new_flavor_id = self._create_flavor(flavor_id)
self.assertEqual(new_flavor_id, str(uuid.UUID(new_flavor_id)))
- @test.attr(type='gate')
@test.idempotent_id('8261d7b0-be58-43ec-a2e5-300573c3f6c5')
def test_create_flavor_verify_entry_in_list_details(self):
# Create a flavor and ensure it's details are listed
@@ -135,7 +131,6 @@ class FlavorsAdminTestJSON(base.BaseV2ComputeAdminTest):
flag = True
self.assertTrue(flag)
- @test.attr(type='gate')
@test.idempotent_id('63dc64e6-2e79-4fdf-868f-85500d308d66')
def test_create_list_flavor_without_extra_data(self):
# Create a flavor and ensure it is listed
@@ -177,7 +172,6 @@ class FlavorsAdminTestJSON(base.BaseV2ComputeAdminTest):
flag = True
self.assertTrue(flag)
- @test.attr(type='gate')
@test.idempotent_id('be6cc18c-7c5d-48c0-ac16-17eaf03c54eb')
def test_list_non_public_flavor(self):
# Create a flavor with os-flavor-access:is_public false.
@@ -210,7 +204,6 @@ class FlavorsAdminTestJSON(base.BaseV2ComputeAdminTest):
flag = True
self.assertFalse(flag)
- @test.attr(type='gate')
@test.idempotent_id('bcc418ef-799b-47cc-baa1-ce01368b8987')
def test_create_server_with_non_public_flavor(self):
# Create a flavor with os-flavor-access:is_public false
@@ -230,7 +223,6 @@ class FlavorsAdminTestJSON(base.BaseV2ComputeAdminTest):
self.os.servers_client.create_server,
'test', self.image_ref, flavor['id'])
- @test.attr(type='gate')
@test.idempotent_id('b345b196-bfbd-4231-8ac1-6d7fe15ff3a3')
def test_list_public_flavor_with_other_user(self):
# Create a Flavor with public access.
@@ -254,7 +246,6 @@ class FlavorsAdminTestJSON(base.BaseV2ComputeAdminTest):
flag = True
self.assertTrue(flag)
- @test.attr(type='gate')
@test.idempotent_id('fb9cbde6-3a0e-41f2-a983-bdb0a823c44e')
def test_is_public_string_variations(self):
flavor_id_not_public = data_utils.rand_int_id(start=1000)
@@ -297,7 +288,6 @@ class FlavorsAdminTestJSON(base.BaseV2ComputeAdminTest):
_test_string_variations(['t', 'true', 'yes', '1'],
flavor_name_public)
- @test.attr(type='gate')
@test.idempotent_id('3b541a2e-2ac2-4b42-8b8d-ba6e22fcd4da')
def test_create_flavor_using_string_ram(self):
flavor_name = data_utils.rand_name(self.flavor_name_prefix)
diff --git a/tempest/api/compute/admin/test_flavors_access.py b/tempest/api/compute/admin/test_flavors_access.py
index b7edcab75..61d3dc690 100644
--- a/tempest/api/compute/admin/test_flavors_access.py
+++ b/tempest/api/compute/admin/test_flavors_access.py
@@ -51,7 +51,6 @@ class FlavorsAccessTestJSON(base.BaseV2ComputeAdminTest):
cls.vcpus = 1
cls.disk = 10
- @test.attr(type='gate')
@test.idempotent_id('ea2c2211-29fa-4db9-97c3-906d36fad3e0')
def test_flavor_access_list_with_private_flavor(self):
# Test to make sure that list flavor access on a newly created
@@ -67,7 +66,6 @@ class FlavorsAccessTestJSON(base.BaseV2ComputeAdminTest):
flavor_access = self.client.list_flavor_access(new_flavor_id)
self.assertEqual(len(flavor_access), 0, str(flavor_access))
- @test.attr(type='gate')
@test.idempotent_id('59e622f6-bdf6-45e3-8ba8-fedad905a6b4')
def test_flavor_access_add_remove(self):
# Test to add and remove flavor access to a given tenant.
diff --git a/tempest/api/compute/admin/test_flavors_access_negative.py b/tempest/api/compute/admin/test_flavors_access_negative.py
index 97930c1c9..be5e6cca3 100644
--- a/tempest/api/compute/admin/test_flavors_access_negative.py
+++ b/tempest/api/compute/admin/test_flavors_access_negative.py
@@ -51,7 +51,7 @@ class FlavorsAccessNegativeTestJSON(base.BaseV2ComputeAdminTest):
cls.vcpus = 1
cls.disk = 10
- @test.attr(type=['negative', 'gate'])
+ @test.attr(type=['negative'])
@test.idempotent_id('0621c53e-d45d-40e7-951d-43e5e257b272')
def test_flavor_access_list_with_public_flavor(self):
# Test to list flavor access with exceptions by querying public flavor
@@ -67,7 +67,7 @@ class FlavorsAccessNegativeTestJSON(base.BaseV2ComputeAdminTest):
self.client.list_flavor_access,
new_flavor_id)
- @test.attr(type=['negative', 'gate'])
+ @test.attr(type=['negative'])
@test.idempotent_id('41eaaade-6d37-4f28-9c74-f21b46ca67bd')
def test_flavor_non_admin_add(self):
# Test to add flavor access as a user without admin privileges.
@@ -84,7 +84,7 @@ class FlavorsAccessNegativeTestJSON(base.BaseV2ComputeAdminTest):
new_flavor['id'],
self.tenant_id)
- @test.attr(type=['negative', 'gate'])
+ @test.attr(type=['negative'])
@test.idempotent_id('073e79a6-c311-4525-82dc-6083d919cb3a')
def test_flavor_non_admin_remove(self):
# Test to remove flavor access as a user without admin privileges.
@@ -105,7 +105,7 @@ class FlavorsAccessNegativeTestJSON(base.BaseV2ComputeAdminTest):
new_flavor['id'],
self.tenant_id)
- @test.attr(type=['negative', 'gate'])
+ @test.attr(type=['negative'])
@test.idempotent_id('f3592cc0-0306-483c-b210-9a7b5346eddc')
def test_add_flavor_access_duplicate(self):
# Create a new flavor.
@@ -130,7 +130,7 @@ class FlavorsAccessNegativeTestJSON(base.BaseV2ComputeAdminTest):
new_flavor['id'],
self.tenant_id)
- @test.attr(type=['negative', 'gate'])
+ @test.attr(type=['negative'])
@test.idempotent_id('1f710927-3bc7-4381-9f82-0ca6e42644b7')
def test_remove_flavor_access_not_found(self):
# Create a new flavor.
diff --git a/tempest/api/compute/admin/test_flavors_extra_specs.py b/tempest/api/compute/admin/test_flavors_extra_specs.py
index b83a06393..2ed1e359e 100644
--- a/tempest/api/compute/admin/test_flavors_extra_specs.py
+++ b/tempest/api/compute/admin/test_flavors_extra_specs.py
@@ -64,7 +64,6 @@ class FlavorsExtraSpecsTestJSON(base.BaseV2ComputeAdminTest):
cls.client.wait_for_resource_deletion(cls.flavor['id'])
super(FlavorsExtraSpecsTestJSON, cls).resource_cleanup()
- @test.attr(type='gate')
@test.idempotent_id('0b2f9d4b-1ca2-4b99-bb40-165d4bb94208')
def test_flavor_set_get_update_show_unset_keys(self):
# Test to SET, GET, UPDATE, SHOW, UNSET flavor extra
@@ -95,7 +94,6 @@ class FlavorsExtraSpecsTestJSON(base.BaseV2ComputeAdminTest):
self.client.unset_flavor_extra_spec(self.flavor['id'], "key1")
self.client.unset_flavor_extra_spec(self.flavor['id'], "key2")
- @test.attr(type='gate')
@test.idempotent_id('a99dad88-ae1c-4fba-aeb4-32f898218bd0')
def test_flavor_non_admin_get_all_keys(self):
specs = {"key1": "value1", "key2": "value2"}
@@ -105,7 +103,6 @@ class FlavorsExtraSpecsTestJSON(base.BaseV2ComputeAdminTest):
for key in specs:
self.assertEqual(body[key], specs[key])
- @test.attr(type='gate')
@test.idempotent_id('12805a7f-39a3-4042-b989-701d5cad9c90')
def test_flavor_non_admin_get_specific_key(self):
specs = {"key1": "value1", "key2": "value2"}
diff --git a/tempest/api/compute/admin/test_flavors_extra_specs_negative.py b/tempest/api/compute/admin/test_flavors_extra_specs_negative.py
index 2236a8a2c..df592dd8a 100644
--- a/tempest/api/compute/admin/test_flavors_extra_specs_negative.py
+++ b/tempest/api/compute/admin/test_flavors_extra_specs_negative.py
@@ -66,7 +66,7 @@ class FlavorsExtraSpecsNegativeTestJSON(base.BaseV2ComputeAdminTest):
cls.client.wait_for_resource_deletion(cls.flavor['id'])
super(FlavorsExtraSpecsNegativeTestJSON, cls).resource_cleanup()
- @test.attr(type=['negative', 'gate'])
+ @test.attr(type=['negative'])
@test.idempotent_id('a00a3b81-5641-45a8-ab2b-4a8ec41e1d7d')
def test_flavor_non_admin_set_keys(self):
# Test to SET flavor extra spec as a user without admin privileges.
@@ -76,7 +76,7 @@ class FlavorsExtraSpecsNegativeTestJSON(base.BaseV2ComputeAdminTest):
self.flavor['id'],
specs)
- @test.attr(type=['negative', 'gate'])
+ @test.attr(type=['negative'])
@test.idempotent_id('1ebf4ef8-759e-48fe-a801-d451d80476fb')
def test_flavor_non_admin_update_specific_key(self):
# non admin user is not allowed to update flavor extra spec
@@ -91,7 +91,7 @@ class FlavorsExtraSpecsNegativeTestJSON(base.BaseV2ComputeAdminTest):
'key1',
key1='value1_new')
- @test.attr(type=['negative', 'gate'])
+ @test.attr(type=['negative'])
@test.idempotent_id('28f12249-27c7-44c1-8810-1f382f316b11')
def test_flavor_non_admin_unset_keys(self):
specs = {"key1": "value1", "key2": "value2"}
@@ -102,7 +102,7 @@ class FlavorsExtraSpecsNegativeTestJSON(base.BaseV2ComputeAdminTest):
self.flavor['id'],
'key1')
- @test.attr(type=['negative', 'gate'])
+ @test.attr(type=['negative'])
@test.idempotent_id('440b9f3f-3c7f-4293-a106-0ceda350f8de')
def test_flavor_unset_nonexistent_key(self):
nonexistent_key = data_utils.rand_name('flavor_key')
@@ -111,7 +111,7 @@ class FlavorsExtraSpecsNegativeTestJSON(base.BaseV2ComputeAdminTest):
self.flavor['id'],
nonexistent_key)
- @test.attr(type=['negative', 'gate'])
+ @test.attr(type=['negative'])
@test.idempotent_id('329a7be3-54b2-48be-8052-bf2ce4afd898')
def test_flavor_get_nonexistent_key(self):
self.assertRaises(lib_exc.NotFound,
@@ -119,7 +119,7 @@ class FlavorsExtraSpecsNegativeTestJSON(base.BaseV2ComputeAdminTest):
self.flavor['id'],
"nonexistent_key")
- @test.attr(type=['negative', 'gate'])
+ @test.attr(type=['negative'])
@test.idempotent_id('25b822b8-9f49-44f6-80de-d99f0482e5cb')
def test_flavor_update_mismatch_key(self):
# the key will be updated should be match the key in the body
@@ -129,7 +129,7 @@ class FlavorsExtraSpecsNegativeTestJSON(base.BaseV2ComputeAdminTest):
"key2",
key1="value")
- @test.attr(type=['negative', 'gate'])
+ @test.attr(type=['negative'])
@test.idempotent_id('f5889590-bf66-41cc-b4b1-6e6370cfd93f')
def test_flavor_update_more_key(self):
# there should be just one item in the request body
diff --git a/tempest/api/compute/admin/test_floating_ips_bulk.py b/tempest/api/compute/admin/test_floating_ips_bulk.py
index 3c48d9e3a..5c45dd8b5 100644
--- a/tempest/api/compute/admin/test_floating_ips_bulk.py
+++ b/tempest/api/compute/admin/test_floating_ips_bulk.py
@@ -61,7 +61,6 @@ class FloatingIPsBulkAdminTestJSON(base.BaseV2ComputeAdminTest):
except Exception:
pass
- @test.attr(type='gate')
@test.idempotent_id('2c8f145f-8012-4cb8-ac7e-95a587f0e4ab')
@test.services('network')
def test_create_list_delete_floating_ips_bulk(self):
diff --git a/tempest/api/compute/admin/test_hosts.py b/tempest/api/compute/admin/test_hosts.py
index e525358e5..a91c9bf44 100644
--- a/tempest/api/compute/admin/test_hosts.py
+++ b/tempest/api/compute/admin/test_hosts.py
@@ -28,13 +28,11 @@ class HostsAdminTestJSON(base.BaseV2ComputeAdminTest):
super(HostsAdminTestJSON, cls).setup_clients()
cls.client = cls.os_adm.hosts_client
- @test.attr(type='gate')
@test.idempotent_id('9bfaf98d-e2cb-44b0-a07e-2558b2821e4f')
def test_list_hosts(self):
hosts = self.client.list_hosts()
self.assertTrue(len(hosts) >= 2, str(hosts))
- @test.attr(type='gate')
@test.idempotent_id('5dc06f5b-d887-47a2-bb2a-67762ef3c6de')
def test_list_hosts_with_zone(self):
self.useFixture(fixtures.LockFixture('availability_zone'))
@@ -46,7 +44,6 @@ class HostsAdminTestJSON(base.BaseV2ComputeAdminTest):
self.assertTrue(len(hosts) >= 1)
self.assertIn(host, hosts)
- @test.attr(type='gate')
@test.idempotent_id('9af3c171-fbf4-4150-a624-22109733c2a6')
def test_list_hosts_with_a_blank_zone(self):
# If send the request with a blank zone, the request will be successful
@@ -55,7 +52,6 @@ class HostsAdminTestJSON(base.BaseV2ComputeAdminTest):
hosts = self.client.list_hosts(params)
self.assertNotEqual(0, len(hosts))
- @test.attr(type='gate')
@test.idempotent_id('c6ddbadb-c94e-4500-b12f-8ffc43843ff8')
def test_list_hosts_with_nonexistent_zone(self):
# If send the request with a nonexistent zone, the request will be
@@ -64,7 +60,6 @@ class HostsAdminTestJSON(base.BaseV2ComputeAdminTest):
hosts = self.client.list_hosts(params)
self.assertEqual(0, len(hosts))
- @test.attr(type='gate')
@test.idempotent_id('38adbb12-aee2-4498-8aec-329c72423aa4')
def test_show_host_detail(self):
hosts = self.client.list_hosts()
diff --git a/tempest/api/compute/admin/test_hosts_negative.py b/tempest/api/compute/admin/test_hosts_negative.py
index 95be59efc..042d1fb83 100644
--- a/tempest/api/compute/admin/test_hosts_negative.py
+++ b/tempest/api/compute/admin/test_hosts_negative.py
@@ -37,20 +37,20 @@ class HostsAdminNegativeTestJSON(base.BaseV2ComputeAdminTest):
hostname = hosts[0]['host_name']
return hostname
- @test.attr(type=['negative', 'gate'])
+ @test.attr(type=['negative'])
@test.idempotent_id('dd032027-0210-4d9c-860e-69b1b8deed5f')
def test_list_hosts_with_non_admin_user(self):
self.assertRaises(lib_exc.Forbidden,
self.non_admin_client.list_hosts)
- @test.attr(type=['negative', 'gate'])
+ @test.attr(type=['negative'])
@test.idempotent_id('e75b0a1a-041f-47a1-8b4a-b72a6ff36d3f')
def test_show_host_detail_with_nonexistent_hostname(self):
nonexitent_hostname = data_utils.rand_name('rand_hostname')
self.assertRaises(lib_exc.NotFound,
self.client.show_host_detail, nonexitent_hostname)
- @test.attr(type=['negative', 'gate'])
+ @test.attr(type=['negative'])
@test.idempotent_id('19ebe09c-bfd4-4b7c-81a2-e2e0710f59cc')
def test_show_host_detail_with_non_admin_user(self):
hostname = self._get_host_name()
@@ -59,7 +59,7 @@ class HostsAdminNegativeTestJSON(base.BaseV2ComputeAdminTest):
self.non_admin_client.show_host_detail,
hostname)
- @test.attr(type=['negative', 'gate'])
+ @test.attr(type=['negative'])
@test.idempotent_id('e40c72b1-0239-4ed6-ba21-81a184df1f7c')
def test_update_host_with_non_admin_user(self):
hostname = self._get_host_name()
@@ -70,7 +70,7 @@ class HostsAdminNegativeTestJSON(base.BaseV2ComputeAdminTest):
status='enable',
maintenance_mode='enable')
- @test.attr(type=['negative', 'gate'])
+ @test.attr(type=['negative'])
@test.idempotent_id('76e396fe-5418-4dd3-a186-5b301edc0721')
def test_update_host_with_extra_param(self):
# only 'status' and 'maintenance_mode' are the valid params.
@@ -83,7 +83,7 @@ class HostsAdminNegativeTestJSON(base.BaseV2ComputeAdminTest):
maintenance_mode='enable',
param='XXX')
- @test.attr(type=['negative', 'gate'])
+ @test.attr(type=['negative'])
@test.idempotent_id('fbe2bf3e-3246-4a95-a59f-94e4e298ec77')
def test_update_host_with_invalid_status(self):
# 'status' can only be 'enable' or 'disable'
@@ -95,7 +95,7 @@ class HostsAdminNegativeTestJSON(base.BaseV2ComputeAdminTest):
status='invalid',
maintenance_mode='enable')
- @test.attr(type=['negative', 'gate'])
+ @test.attr(type=['negative'])
@test.idempotent_id('ab1e230e-5e22-41a9-8699-82b9947915d4')
def test_update_host_with_invalid_maintenance_mode(self):
# 'maintenance_mode' can only be 'enable' or 'disable'
@@ -107,7 +107,7 @@ class HostsAdminNegativeTestJSON(base.BaseV2ComputeAdminTest):
status='enable',
maintenance_mode='invalid')
- @test.attr(type=['negative', 'gate'])
+ @test.attr(type=['negative'])
@test.idempotent_id('0cd85f75-6992-4a4a-b1bd-d11e37fd0eee')
def test_update_host_without_param(self):
# 'status' or 'maintenance_mode' needed for host update
@@ -117,7 +117,7 @@ class HostsAdminNegativeTestJSON(base.BaseV2ComputeAdminTest):
self.client.update_host,
hostname)
- @test.attr(type=['negative', 'gate'])
+ @test.attr(type=['negative'])
@test.idempotent_id('23c92146-2100-4d68-b2d6-c7ade970c9c1')
def test_update_nonexistent_host(self):
nonexitent_hostname = data_utils.rand_name('rand_hostname')
@@ -128,7 +128,7 @@ class HostsAdminNegativeTestJSON(base.BaseV2ComputeAdminTest):
status='enable',
maintenance_mode='enable')
- @test.attr(type=['negative', 'gate'])
+ @test.attr(type=['negative'])
@test.idempotent_id('0d981ac3-4320-4898-b674-82b61fbb60e4')
def test_startup_nonexistent_host(self):
nonexitent_hostname = data_utils.rand_name('rand_hostname')
@@ -137,7 +137,7 @@ class HostsAdminNegativeTestJSON(base.BaseV2ComputeAdminTest):
self.client.startup_host,
nonexitent_hostname)
- @test.attr(type=['negative', 'gate'])
+ @test.attr(type=['negative'])
@test.idempotent_id('9f4ebb7e-b2ae-4e5b-a38f-0fd1bb0ddfca')
def test_startup_host_with_non_admin_user(self):
hostname = self._get_host_name()
@@ -146,7 +146,7 @@ class HostsAdminNegativeTestJSON(base.BaseV2ComputeAdminTest):
self.non_admin_client.startup_host,
hostname)
- @test.attr(type=['negative', 'gate'])
+ @test.attr(type=['negative'])
@test.idempotent_id('9e637444-29cf-4244-88c8-831ae82c31b6')
def test_shutdown_nonexistent_host(self):
nonexitent_hostname = data_utils.rand_name('rand_hostname')
@@ -155,7 +155,7 @@ class HostsAdminNegativeTestJSON(base.BaseV2ComputeAdminTest):
self.client.shutdown_host,
nonexitent_hostname)
- @test.attr(type=['negative', 'gate'])
+ @test.attr(type=['negative'])
@test.idempotent_id('a803529c-7e3f-4d3c-a7d6-8e1c203d27f6')
def test_shutdown_host_with_non_admin_user(self):
hostname = self._get_host_name()
@@ -164,7 +164,7 @@ class HostsAdminNegativeTestJSON(base.BaseV2ComputeAdminTest):
self.non_admin_client.shutdown_host,
hostname)
- @test.attr(type=['negative', 'gate'])
+ @test.attr(type=['negative'])
@test.idempotent_id('f86bfd7b-0b13-4849-ae29-0322e83ee58b')
def test_reboot_nonexistent_host(self):
nonexitent_hostname = data_utils.rand_name('rand_hostname')
@@ -173,7 +173,7 @@ class HostsAdminNegativeTestJSON(base.BaseV2ComputeAdminTest):
self.client.reboot_host,
nonexitent_hostname)
- @test.attr(type=['negative', 'gate'])
+ @test.attr(type=['negative'])
@test.idempotent_id('02d79bb9-eb57-4612-abf6-2cb38897d2f8')
def test_reboot_host_with_non_admin_user(self):
hostname = self._get_host_name()
diff --git a/tempest/api/compute/admin/test_hypervisor.py b/tempest/api/compute/admin/test_hypervisor.py
index 5e83e9545..9483f52ea 100644
--- a/tempest/api/compute/admin/test_hypervisor.py
+++ b/tempest/api/compute/admin/test_hypervisor.py
@@ -36,21 +36,18 @@ class HypervisorAdminTestJSON(base.BaseV2ComputeAdminTest):
def assertHypervisors(self, hypers):
self.assertTrue(len(hypers) > 0, "No hypervisors found: %s" % hypers)
- @test.attr(type='gate')
@test.idempotent_id('7f0ceacd-c64d-4e96-b8ee-d02943142cc5')
def test_get_hypervisor_list(self):
# List of hypervisor and available hypervisors hostname
hypers = self._list_hypervisors()
self.assertHypervisors(hypers)
- @test.attr(type='gate')
@test.idempotent_id('1e7fdac2-b672-4ad1-97a4-bad0e3030118')
def test_get_hypervisor_list_details(self):
# Display the details of the all hypervisor
hypers = self.client.get_hypervisor_list_details()
self.assertHypervisors(hypers)
- @test.attr(type='gate')
@test.idempotent_id('94ff9eae-a183-428e-9cdb-79fde71211cc')
def test_get_hypervisor_show_details(self):
# Display the details of the specified hypervisor
@@ -62,7 +59,6 @@ class HypervisorAdminTestJSON(base.BaseV2ComputeAdminTest):
self.assertEqual(details['hypervisor_hostname'],
hypers[0]['hypervisor_hostname'])
- @test.attr(type='gate')
@test.idempotent_id('e81bba3f-6215-4e39-a286-d52d2f906862')
def test_get_hypervisor_show_servers(self):
# Show instances about the specific hypervisors
@@ -73,14 +69,12 @@ class HypervisorAdminTestJSON(base.BaseV2ComputeAdminTest):
hypervisors = self.client.get_hypervisor_servers(hostname)
self.assertTrue(len(hypervisors) > 0)
- @test.attr(type='gate')
@test.idempotent_id('797e4f28-b6e0-454d-a548-80cc77c00816')
def test_get_hypervisor_stats(self):
# Verify the stats of the all hypervisor
stats = self.client.get_hypervisor_stats()
self.assertTrue(len(stats) > 0)
- @test.attr(type='gate')
@test.idempotent_id('91a50d7d-1c2b-4f24-b55a-a1fe20efca70')
def test_get_hypervisor_uptime(self):
# Verify that GET shows the specified hypervisor uptime
@@ -118,7 +112,6 @@ class HypervisorAdminTestJSON(base.BaseV2ComputeAdminTest):
has_valid_uptime,
"None of the hypervisors had a valid uptime: %s" % hypers)
- @test.attr(type='gate')
@test.idempotent_id('d7e1805b-3b14-4a3b-b6fd-50ec6d9f361f')
def test_search_hypervisor(self):
hypers = self._list_hypervisors()
diff --git a/tempest/api/compute/admin/test_hypervisor_negative.py b/tempest/api/compute/admin/test_hypervisor_negative.py
index c7de6be91..24b0090c9 100644
--- a/tempest/api/compute/admin/test_hypervisor_negative.py
+++ b/tempest/api/compute/admin/test_hypervisor_negative.py
@@ -39,7 +39,7 @@ class HypervisorAdminNegativeTestJSON(base.BaseV2ComputeAdminTest):
hypers = self.client.get_hypervisor_list()
return hypers
- @test.attr(type=['negative', 'gate'])
+ @test.attr(type=['negative'])
@test.idempotent_id('c136086a-0f67-4b2b-bc61-8482bd68989f')
def test_show_nonexistent_hypervisor(self):
nonexistent_hypervisor_id = str(uuid.uuid4())
@@ -49,7 +49,7 @@ class HypervisorAdminNegativeTestJSON(base.BaseV2ComputeAdminTest):
self.client.get_hypervisor_show_details,
nonexistent_hypervisor_id)
- @test.attr(type=['negative', 'gate'])
+ @test.attr(type=['negative'])
@test.idempotent_id('51e663d0-6b89-4817-a465-20aca0667d03')
def test_show_hypervisor_with_non_admin_user(self):
hypers = self._list_hypervisors()
@@ -60,7 +60,7 @@ class HypervisorAdminNegativeTestJSON(base.BaseV2ComputeAdminTest):
self.non_adm_client.get_hypervisor_show_details,
hypers[0]['id'])
- @test.attr(type=['negative', 'gate'])
+ @test.attr(type=['negative'])
@test.idempotent_id('2a0a3938-832e-4859-95bf-1c57c236b924')
def test_show_servers_with_non_admin_user(self):
hypers = self._list_hypervisors()
@@ -71,7 +71,7 @@ class HypervisorAdminNegativeTestJSON(base.BaseV2ComputeAdminTest):
self.non_adm_client.get_hypervisor_servers,
hypers[0]['id'])
- @test.attr(type=['negative', 'gate'])
+ @test.attr(type=['negative'])
@test.idempotent_id('02463d69-0ace-4d33-a4a8-93d7883a2bba')
def test_show_servers_with_nonexistent_hypervisor(self):
nonexistent_hypervisor_id = str(uuid.uuid4())
@@ -81,14 +81,14 @@ class HypervisorAdminNegativeTestJSON(base.BaseV2ComputeAdminTest):
self.client.get_hypervisor_servers,
nonexistent_hypervisor_id)
- @test.attr(type=['negative', 'gate'])
+ @test.attr(type=['negative'])
@test.idempotent_id('e2b061bb-13f9-40d8-9d6e-d5bf17595849')
def test_get_hypervisor_stats_with_non_admin_user(self):
self.assertRaises(
lib_exc.Forbidden,
self.non_adm_client.get_hypervisor_stats)
- @test.attr(type=['negative', 'gate'])
+ @test.attr(type=['negative'])
@test.idempotent_id('f60aa680-9a3a-4c7d-90e1-fae3a4891303')
def test_get_nonexistent_hypervisor_uptime(self):
nonexistent_hypervisor_id = str(uuid.uuid4())
@@ -98,7 +98,7 @@ class HypervisorAdminNegativeTestJSON(base.BaseV2ComputeAdminTest):
self.client.get_hypervisor_uptime,
nonexistent_hypervisor_id)
- @test.attr(type=['negative', 'gate'])
+ @test.attr(type=['negative'])
@test.idempotent_id('6c3461f9-c04c-4e2a-bebb-71dc9cb47df2')
def test_get_hypervisor_uptime_with_non_admin_user(self):
hypers = self._list_hypervisors()
@@ -109,7 +109,7 @@ class HypervisorAdminNegativeTestJSON(base.BaseV2ComputeAdminTest):
self.non_adm_client.get_hypervisor_uptime,
hypers[0]['id'])
- @test.attr(type=['negative', 'gate'])
+ @test.attr(type=['negative'])
@test.idempotent_id('51b3d536-9b14-409c-9bce-c6f7c794994e')
def test_get_hypervisor_list_with_non_admin_user(self):
# List of hypervisor and available services with non admin user
@@ -117,7 +117,7 @@ class HypervisorAdminNegativeTestJSON(base.BaseV2ComputeAdminTest):
lib_exc.Forbidden,
self.non_adm_client.get_hypervisor_list)
- @test.attr(type=['negative', 'gate'])
+ @test.attr(type=['negative'])
@test.idempotent_id('dc02db05-e801-4c5f-bc8e-d915290ab345')
def test_get_hypervisor_list_details_with_non_admin_user(self):
# List of hypervisor details and available services with non admin user
@@ -125,7 +125,7 @@ class HypervisorAdminNegativeTestJSON(base.BaseV2ComputeAdminTest):
lib_exc.Forbidden,
self.non_adm_client.get_hypervisor_list_details)
- @test.attr(type=['negative', 'gate'])
+ @test.attr(type=['negative'])
@test.idempotent_id('19a45cc1-1000-4055-b6d2-28e8b2ec4faa')
def test_search_nonexistent_hypervisor(self):
nonexistent_hypervisor_name = data_utils.rand_name('test_hypervisor')
@@ -135,7 +135,7 @@ class HypervisorAdminNegativeTestJSON(base.BaseV2ComputeAdminTest):
self.client.search_hypervisor,
nonexistent_hypervisor_name)
- @test.attr(type=['negative', 'gate'])
+ @test.attr(type=['negative'])
@test.idempotent_id('5b6a6c79-5dc1-4fa5-9c58-9c8085948e74')
def test_search_hypervisor_with_non_admin_user(self):
hypers = self._list_hypervisors()
diff --git a/tempest/api/compute/admin/test_instance_usage_audit_log.py b/tempest/api/compute/admin/test_instance_usage_audit_log.py
index 656581003..66342908a 100644
--- a/tempest/api/compute/admin/test_instance_usage_audit_log.py
+++ b/tempest/api/compute/admin/test_instance_usage_audit_log.py
@@ -27,7 +27,6 @@ class InstanceUsageAuditLogTestJSON(base.BaseV2ComputeAdminTest):
super(InstanceUsageAuditLogTestJSON, cls).setup_clients()
cls.adm_client = cls.os_adm.instance_usages_audit_log_client
- @test.attr(type='gate')
@test.idempotent_id('25319919-33d9-424f-9f99-2c203ee48b9d')
def test_list_instance_usage_audit_logs(self):
# list instance usage audit logs
@@ -40,7 +39,6 @@ class InstanceUsageAuditLogTestJSON(base.BaseV2ComputeAdminTest):
for item in expected_items:
self.assertIn(item, body)
- @test.attr(type='gate')
@test.idempotent_id('6e40459d-7c5f-400b-9e83-449fbc8e7feb')
def test_get_instance_usage_audit_log(self):
# Get instance usage audit log before specified time
diff --git a/tempest/api/compute/admin/test_instance_usage_audit_log_negative.py b/tempest/api/compute/admin/test_instance_usage_audit_log_negative.py
index e9f337139..ec9ad1979 100644
--- a/tempest/api/compute/admin/test_instance_usage_audit_log_negative.py
+++ b/tempest/api/compute/admin/test_instance_usage_audit_log_negative.py
@@ -29,7 +29,7 @@ class InstanceUsageAuditLogNegativeTestJSON(base.BaseV2ComputeAdminTest):
super(InstanceUsageAuditLogNegativeTestJSON, cls).setup_clients()
cls.adm_client = cls.os_adm.instance_usages_audit_log_client
- @test.attr(type=['negative', 'gate'])
+ @test.attr(type=['negative'])
@test.idempotent_id('a9d33178-d2c9-4131-ad3b-f4ca8d0308a2')
def test_instance_usage_audit_logs_with_nonadmin_user(self):
# the instance_usage_audit_logs API just can be accessed by admin user
@@ -42,7 +42,7 @@ class InstanceUsageAuditLogNegativeTestJSON(base.BaseV2ComputeAdminTest):
get_instance_usage_audit_log,
urllib.quote(now.strftime("%Y-%m-%d %H:%M:%S")))
- @test.attr(type=['negative', 'gate'])
+ @test.attr(type=['negative'])
@test.idempotent_id('9b952047-3641-41c7-ba91-a809fc5974c8')
def test_get_instance_usage_audit_logs_with_invalid_time(self):
self.assertRaises(lib_exc.BadRequest,
diff --git a/tempest/api/compute/admin/test_live_migration.py b/tempest/api/compute/admin/test_live_migration.py
index c3f91eea2..8a92326ed 100644
--- a/tempest/api/compute/admin/test_live_migration.py
+++ b/tempest/api/compute/admin/test_live_migration.py
@@ -87,7 +87,6 @@ class LiveBlockMigrationTestJSON(base.BaseV2ComputeAdminTest):
@test.idempotent_id('1dce86b8-eb04-4c03-a9d8-9c1dc3ee0c7b')
@testtools.skipIf(not CONF.compute_feature_enabled.live_migration,
'Live migration not available')
- @test.attr(type='gate')
def test_live_block_migration(self):
# Live block migrate an instance to another host
if len(self._get_compute_hostnames()) < 2:
@@ -108,7 +107,6 @@ class LiveBlockMigrationTestJSON(base.BaseV2ComputeAdminTest):
@testtools.skipIf(not CONF.compute_feature_enabled.
block_migrate_cinder_iscsi,
'Block Live migration not configured for iSCSI')
- @test.attr(type='gate')
def test_iscsi_volume(self):
# Live block migrate an instance to another host
if len(self._get_compute_hostnames()) < 2:
diff --git a/tempest/api/compute/admin/test_migrations.py b/tempest/api/compute/admin/test_migrations.py
index 3c31e77c7..5434d930c 100644
--- a/tempest/api/compute/admin/test_migrations.py
+++ b/tempest/api/compute/admin/test_migrations.py
@@ -28,7 +28,6 @@ class MigrationsAdminTest(base.BaseV2ComputeAdminTest):
super(MigrationsAdminTest, cls).setup_clients()
cls.client = cls.os_adm.migrations_client
- @test.attr(type='gate')
@test.idempotent_id('75c0b83d-72a0-4cf8-a153-631e83e7d53f')
def test_list_migrations(self):
# Admin can get the migrations list
@@ -37,7 +36,6 @@ class MigrationsAdminTest(base.BaseV2ComputeAdminTest):
@test.idempotent_id('1b512062-8093-438e-b47a-37d2f597cd64')
@testtools.skipUnless(CONF.compute_feature_enabled.resize,
'Resize not available.')
- @test.attr(type='gate')
def test_list_migrations_in_flavor_resize_situation(self):
# Admin can get the migrations list which contains the resized server
server = self.create_test_server(wait_until="ACTIVE")
diff --git a/tempest/api/compute/admin/test_quotas.py b/tempest/api/compute/admin/test_quotas.py
index 7601b2546..8b571f20c 100644
--- a/tempest/api/compute/admin/test_quotas.py
+++ b/tempest/api/compute/admin/test_quotas.py
@@ -65,7 +65,6 @@ class QuotasAdminTestJSON(base.BaseV2ComputeAdminTest):
for quota in expected_quota_set:
self.assertIn(quota, quota_set.keys())
- @test.attr(type='gate')
@test.idempotent_id('55fbe2bf-21a9-435b-bbd2-4162b0ed799a')
def test_update_all_quota_resources_for_tenant(self):
# Admin can update all the resource quota limits for a tenant
@@ -97,7 +96,6 @@ class QuotasAdminTestJSON(base.BaseV2ComputeAdminTest):
self.assertIn(quota, quota_set.keys())
# TODO(afazekas): merge these test cases
- @test.attr(type='gate')
@test.idempotent_id('ce9e0815-8091-4abd-8345-7fe5b85faa1d')
def test_get_updated_quotas(self):
# Verify that GET shows the updated quota set of tenant
@@ -131,7 +129,6 @@ class QuotasAdminTestJSON(base.BaseV2ComputeAdminTest):
user_id=user_id)
self.assertEqual(2048, quota_set['ram'])
- @test.attr(type='gate')
@test.idempotent_id('389d04f0-3a41-405f-9317-e5f86e3c44f0')
def test_delete_quota(self):
# Admin can delete the resource quota set for a tenant
diff --git a/tempest/api/compute/admin/test_quotas_negative.py b/tempest/api/compute/admin/test_quotas_negative.py
index b74285d09..d20ebf398 100644
--- a/tempest/api/compute/admin/test_quotas_negative.py
+++ b/tempest/api/compute/admin/test_quotas_negative.py
@@ -40,7 +40,7 @@ class QuotasAdminNegativeTestJSON(base.BaseV2ComputeAdminTest):
# tenant most of them should be skipped if we can't do that
cls.demo_tenant_id = cls.client.tenant_id
- @test.attr(type=['negative', 'gate'])
+ @test.attr(type=['negative'])
@test.idempotent_id('733abfe8-166e-47bb-8363-23dbd7ff3476')
def test_update_quota_normal_user(self):
self.assertRaises(lib_exc.Forbidden,
@@ -50,7 +50,7 @@ class QuotasAdminNegativeTestJSON(base.BaseV2ComputeAdminTest):
# TODO(afazekas): Add dedicated tenant to the skiped quota tests
# it can be moved into the setUpClass as well
- @test.attr(type=['negative', 'gate'])
+ @test.attr(type=['negative'])
@test.idempotent_id('91058876-9947-4807-9f22-f6eb17140d9b')
def test_create_server_when_cpu_quota_is_full(self):
# Disallow server creation when tenant's vcpu quota is full
@@ -67,7 +67,7 @@ class QuotasAdminNegativeTestJSON(base.BaseV2ComputeAdminTest):
self.assertRaises((lib_exc.Forbidden, lib_exc.OverLimit),
self.create_test_server)
- @test.attr(type=['negative', 'gate'])
+ @test.attr(type=['negative'])
@test.idempotent_id('6fdd7012-584d-4327-a61c-49122e0d5864')
def test_create_server_when_memory_quota_is_full(self):
# Disallow server creation when tenant's memory quota is full
@@ -84,7 +84,7 @@ class QuotasAdminNegativeTestJSON(base.BaseV2ComputeAdminTest):
self.assertRaises((lib_exc.Forbidden, lib_exc.OverLimit),
self.create_test_server)
- @test.attr(type=['negative', 'gate'])
+ @test.attr(type=['negative'])
@test.idempotent_id('7c6be468-0274-449a-81c3-ac1c32ee0161')
def test_create_server_when_instances_quota_is_full(self):
# Once instances quota limit is reached, disallow server creation
@@ -102,7 +102,6 @@ class QuotasAdminNegativeTestJSON(base.BaseV2ComputeAdminTest):
@decorators.skip_because(bug="1186354",
condition=CONF.service_available.neutron)
- @test.attr(type='gate')
@test.idempotent_id('7c6c8f3b-2bf6-4918-b240-57b136a66aa0')
@test.services('network')
def test_security_groups_exceed_limit(self):
@@ -130,7 +129,7 @@ class QuotasAdminNegativeTestJSON(base.BaseV2ComputeAdminTest):
@decorators.skip_because(bug="1186354",
condition=CONF.service_available.neutron)
- @test.attr(type=['negative', 'gate'])
+ @test.attr(type=['negative'])
@test.idempotent_id('6e9f436d-f1ed-4f8e-a493-7275dfaa4b4d')
@test.services('network')
def test_security_groups_rules_exceed_limit(self):
diff --git a/tempest/api/compute/admin/test_servers.py b/tempest/api/compute/admin/test_servers.py
index ef3a029db..9c53e71b3 100644
--- a/tempest/api/compute/admin/test_servers.py
+++ b/tempest/api/compute/admin/test_servers.py
@@ -49,7 +49,6 @@ class ServersAdminTestJSON(base.BaseV2ComputeAdminTest):
wait_until='ACTIVE')
cls.s2_id = server['id']
- @test.attr(type='gate')
@test.idempotent_id('51717b38-bdc1-458b-b636-1cf82d99f62f')
def test_list_servers_by_admin(self):
# Listing servers by admin user returns empty list by default
@@ -57,7 +56,6 @@ class ServersAdminTestJSON(base.BaseV2ComputeAdminTest):
servers = body['servers']
self.assertEqual([], servers)
- @test.attr(type='gate')
@test.idempotent_id('06f960bb-15bb-48dc-873d-f96e89be7870')
def test_list_servers_filter_by_error_status(self):
# Filter the list of servers by server error status
@@ -74,7 +72,6 @@ class ServersAdminTestJSON(base.BaseV2ComputeAdminTest):
self.assertIn(self.s1_id, map(lambda x: x['id'], servers))
self.assertNotIn(self.s2_id, map(lambda x: x['id'], servers))
- @test.attr(type='gate')
@test.idempotent_id('9f5579ae-19b4-4985-a091-2a5d56106580')
def test_list_servers_by_admin_with_all_tenants(self):
# Listing servers by admin user with all tenants parameter
@@ -87,7 +84,6 @@ class ServersAdminTestJSON(base.BaseV2ComputeAdminTest):
self.assertIn(self.s1_name, servers_name)
self.assertIn(self.s2_name, servers_name)
- @test.attr(type='gate')
@test.idempotent_id('7e5d6b8f-454a-4ba1-8ae2-da857af8338b')
def test_list_servers_by_admin_with_specified_tenant(self):
# In nova v2, tenant_id is ignored unless all_tenants is specified
@@ -106,7 +102,6 @@ class ServersAdminTestJSON(base.BaseV2ComputeAdminTest):
servers = body['servers']
self.assertEqual([], servers)
- @test.attr(type='gate')
@test.idempotent_id('86c7a8f7-50cf-43a9-9bac-5b985317134f')
def test_list_servers_filter_by_exist_host(self):
# Filter the list of servers by existent host
@@ -132,7 +127,6 @@ class ServersAdminTestJSON(base.BaseV2ComputeAdminTest):
self.assertNotIn(test_server['id'],
map(lambda x: x['id'], nonexistent_servers))
- @test.attr(type='gate')
@test.idempotent_id('ee8ae470-db70-474d-b752-690b7892cab1')
def test_reset_state_server(self):
# Reset server's state to 'error'
@@ -149,7 +143,6 @@ class ServersAdminTestJSON(base.BaseV2ComputeAdminTest):
server = self.client.get_server(self.s1_id)
self.assertEqual(server['status'], 'ACTIVE')
- @test.attr(type='gate')
@decorators.skip_because(bug="1240043")
@test.idempotent_id('31ff3486-b8a0-4f56-a6c0-aab460531db3')
def test_get_server_diagnostics_by_admin(self):
@@ -161,7 +154,6 @@ class ServersAdminTestJSON(base.BaseV2ComputeAdminTest):
for key in basic_attrs:
self.assertIn(key, str(diagnostic.keys()))
- @test.attr(type='gate')
@test.idempotent_id('682cb127-e5bb-4f53-87ce-cb9003604442')
def test_rebuild_server_in_error_state(self):
# The server in error state should be rebuilt using the provided
@@ -189,7 +181,6 @@ class ServersAdminTestJSON(base.BaseV2ComputeAdminTest):
rebuilt_image_id = server['image']['id']
self.assertEqual(self.image_ref_alt, rebuilt_image_id)
- @test.attr(type='gate')
@test.idempotent_id('7a1323b4-a6a2-497a-96cb-76c07b945c71')
def test_reset_network_inject_network_info(self):
# Reset Network of a Server
@@ -198,7 +189,6 @@ class ServersAdminTestJSON(base.BaseV2ComputeAdminTest):
# Inject the Network Info into Server
self.client.inject_network_info(server['id'])
- @test.attr(type='gate')
@test.idempotent_id('fdcd9b33-0903-4e00-a1f7-b5f6543068d6')
def test_create_server_with_scheduling_hint(self):
# Create a server with scheduler hints.
diff --git a/tempest/api/compute/admin/test_servers_negative.py b/tempest/api/compute/admin/test_servers_negative.py
index d7e62dfde..7f78ce858 100644
--- a/tempest/api/compute/admin/test_servers_negative.py
+++ b/tempest/api/compute/admin/test_servers_negative.py
@@ -62,7 +62,7 @@ class ServersAdminNegativeTestJSON(base.BaseV2ComputeAdminTest):
@test.idempotent_id('28dcec23-f807-49da-822c-56a92ea3c687')
@testtools.skipUnless(CONF.compute_feature_enabled.resize,
'Resize not available.')
- @test.attr(type=['negative', 'gate'])
+ @test.attr(type=['negative'])
def test_resize_server_using_overlimit_ram(self):
# NOTE(mriedem): Avoid conflicts with os-quota-class-sets tests.
self.useFixture(fixtures.LockFixture('compute_quotas'))
@@ -84,7 +84,7 @@ class ServersAdminNegativeTestJSON(base.BaseV2ComputeAdminTest):
@test.idempotent_id('7368a427-2f26-4ad9-9ba9-911a0ec2b0db')
@testtools.skipUnless(CONF.compute_feature_enabled.resize,
'Resize not available.')
- @test.attr(type=['negative', 'gate'])
+ @test.attr(type=['negative'])
def test_resize_server_using_overlimit_vcpus(self):
# NOTE(mriedem): Avoid conflicts with os-quota-class-sets tests.
self.useFixture(fixtures.LockFixture('compute_quotas'))
@@ -103,27 +103,27 @@ class ServersAdminNegativeTestJSON(base.BaseV2ComputeAdminTest):
self.servers[0]['id'],
flavor_ref['id'])
- @test.attr(type=['negative', 'gate'])
+ @test.attr(type=['negative'])
@test.idempotent_id('b0b4d8af-1256-41ef-9ee7-25f1c19dde80')
def test_reset_state_server_invalid_state(self):
self.assertRaises(lib_exc.BadRequest,
self.client.reset_state, self.s1_id,
state='invalid')
- @test.attr(type=['negative', 'gate'])
+ @test.attr(type=['negative'])
@test.idempotent_id('4cdcc984-fab0-4577-9a9d-6d558527ee9d')
def test_reset_state_server_invalid_type(self):
self.assertRaises(lib_exc.BadRequest,
self.client.reset_state, self.s1_id,
state=1)
- @test.attr(type=['negative', 'gate'])
+ @test.attr(type=['negative'])
@test.idempotent_id('e741298b-8df2-46f0-81cb-8f814ff2504c')
def test_reset_state_server_nonexistent_server(self):
self.assertRaises(lib_exc.NotFound,
self.client.reset_state, '999')
- @test.attr(type=['negative', 'gate'])
+ @test.attr(type=['negative'])
@test.idempotent_id('e84e2234-60d2-42fa-8b30-e2d3049724ac')
def test_get_server_diagnostics_by_non_admin(self):
# Non-admin user can not view server diagnostics according to policy
@@ -131,7 +131,7 @@ class ServersAdminNegativeTestJSON(base.BaseV2ComputeAdminTest):
self.non_adm_client.get_server_diagnostics,
self.s1_id)
- @test.attr(type=['negative', 'gate'])
+ @test.attr(type=['negative'])
@test.idempotent_id('46a4e1ca-87ae-4d28-987a-1b6b136a0221')
def test_migrate_non_existent_server(self):
# migrate a non existent server
@@ -144,7 +144,7 @@ class ServersAdminNegativeTestJSON(base.BaseV2ComputeAdminTest):
'Resize not available.')
@testtools.skipUnless(CONF.compute_feature_enabled.suspend,
'Suspend is not available.')
- @test.attr(type=['negative', 'gate'])
+ @test.attr(type=['negative'])
def test_migrate_server_invalid_state(self):
# create server.
server = self.create_test_server(wait_until='ACTIVE')
diff --git a/tempest/api/compute/admin/test_services.py b/tempest/api/compute/admin/test_services.py
index 932a74e7d..dd3e78cdf 100644
--- a/tempest/api/compute/admin/test_services.py
+++ b/tempest/api/compute/admin/test_services.py
@@ -29,13 +29,11 @@ class ServicesAdminTestJSON(base.BaseV2ComputeAdminTest):
super(ServicesAdminTestJSON, cls).setup_clients()
cls.client = cls.os_adm.services_client
- @test.attr(type='gate')
@test.idempotent_id('5be41ef4-53d1-41cc-8839-5c2a48a1b283')
def test_list_services(self):
services = self.client.list_services()
self.assertNotEqual(0, len(services))
- @test.attr(type='gate')
@test.idempotent_id('f345b1ec-bc6e-4c38-a527-3ca2bc00bef5')
def test_get_service_by_service_binary_name(self):
binary_name = 'nova-compute'
@@ -45,7 +43,6 @@ class ServicesAdminTestJSON(base.BaseV2ComputeAdminTest):
for service in services:
self.assertEqual(binary_name, service['binary'])
- @test.attr(type='gate')
@test.idempotent_id('affb42d5-5b4b-43c8-8b0b-6dca054abcca')
def test_get_service_by_host_name(self):
services = self.client.list_services()
@@ -65,7 +62,6 @@ class ServicesAdminTestJSON(base.BaseV2ComputeAdminTest):
# on order.
self.assertEqual(sorted(s1), sorted(s2))
- @test.attr(type='gate')
@test.idempotent_id('39397f6f-37b8-4234-8671-281e44c74025')
def test_get_service_by_service_and_host_name(self):
services = self.client.list_services()
diff --git a/tempest/api/compute/admin/test_services_negative.py b/tempest/api/compute/admin/test_services_negative.py
index 2d4ec5131..99f31c51b 100644
--- a/tempest/api/compute/admin/test_services_negative.py
+++ b/tempest/api/compute/admin/test_services_negative.py
@@ -30,13 +30,13 @@ class ServicesAdminNegativeTestJSON(base.BaseV2ComputeAdminTest):
cls.client = cls.os_adm.services_client
cls.non_admin_client = cls.services_client
- @test.attr(type=['negative', 'gate'])
+ @test.attr(type=['negative'])
@test.idempotent_id('1126d1f8-266e-485f-a687-adc547492646')
def test_list_services_with_non_admin_user(self):
self.assertRaises(lib_exc.Forbidden,
self.non_admin_client.list_services)
- @test.attr(type=['negative', 'gate'])
+ @test.attr(type=['negative'])
@test.idempotent_id('d0884a69-f693-4e79-a9af-232d15643bf7')
def test_get_service_by_invalid_params(self):
# return all services if send the request with invalid parameter
@@ -45,7 +45,7 @@ class ServicesAdminNegativeTestJSON(base.BaseV2ComputeAdminTest):
services_xxx = self.client.list_services(params)
self.assertEqual(len(services), len(services_xxx))
- @test.attr(type=['negative', 'gate'])
+ @test.attr(type=['negative'])
@test.idempotent_id('1e966d4a-226e-47c7-b601-0b18a27add54')
def test_get_service_by_invalid_service_and_valid_host(self):
services = self.client.list_services()
@@ -54,7 +54,7 @@ class ServicesAdminNegativeTestJSON(base.BaseV2ComputeAdminTest):
services = self.client.list_services(params)
self.assertEqual(0, len(services))
- @test.attr(type=['negative', 'gate'])
+ @test.attr(type=['negative'])
@test.idempotent_id('64e7e7fb-69e8-4cb6-a71d-8d5eb0c98655')
def test_get_service_with_valid_service_and_invalid_host(self):
services = self.client.list_services()
diff --git a/tempest/api/compute/admin/test_simple_tenant_usage.py b/tempest/api/compute/admin/test_simple_tenant_usage.py
index cf7b6727e..98b7c5f08 100644
--- a/tempest/api/compute/admin/test_simple_tenant_usage.py
+++ b/tempest/api/compute/admin/test_simple_tenant_usage.py
@@ -46,7 +46,6 @@ class TenantUsagesTestJSON(base.BaseV2ComputeAdminTest):
# Returns formatted datetime
return at.strftime('%Y-%m-%dT%H:%M:%S.%f')
- @test.attr(type='gate')
@test.idempotent_id('062c8ae9-9912-4249-8b51-e38d664e926e')
def test_list_usage_all_tenants(self):
# Get usage for all tenants
@@ -56,7 +55,6 @@ class TenantUsagesTestJSON(base.BaseV2ComputeAdminTest):
tenant_usage = self.adm_client.list_tenant_usages(params)
self.assertEqual(len(tenant_usage), 8)
- @test.attr(type='gate')
@test.idempotent_id('94135049-a4c5-4934-ad39-08fa7da4f22e')
def test_get_usage_tenant(self):
# Get usage for a specific tenant
@@ -67,7 +65,6 @@ class TenantUsagesTestJSON(base.BaseV2ComputeAdminTest):
self.assertEqual(len(tenant_usage), 8)
- @test.attr(type='gate')
@test.idempotent_id('9d00a412-b40e-4fd9-8eba-97b496316116')
def test_get_usage_tenant_with_non_admin_user(self):
# Get usage for a specific tenant with non admin user
diff --git a/tempest/api/compute/admin/test_simple_tenant_usage_negative.py b/tempest/api/compute/admin/test_simple_tenant_usage_negative.py
index a83d7273d..5a3c9a48b 100644
--- a/tempest/api/compute/admin/test_simple_tenant_usage_negative.py
+++ b/tempest/api/compute/admin/test_simple_tenant_usage_negative.py
@@ -40,7 +40,7 @@ class TenantUsagesNegativeTestJSON(base.BaseV2ComputeAdminTest):
# Returns formatted datetime
return at.strftime('%Y-%m-%dT%H:%M:%S.%f')
- @test.attr(type=['negative', 'gate'])
+ @test.attr(type=['negative'])
@test.idempotent_id('8b21e135-d94b-4991-b6e9-87059609c8ed')
def test_get_usage_tenant_with_empty_tenant_id(self):
# Get usage for a specific tenant empty
@@ -50,7 +50,7 @@ class TenantUsagesNegativeTestJSON(base.BaseV2ComputeAdminTest):
self.adm_client.get_tenant_usage,
'', params)
- @test.attr(type=['negative', 'gate'])
+ @test.attr(type=['negative'])
@test.idempotent_id('4079dd2a-9e8d-479f-869d-6fa985ce45b6')
def test_get_usage_tenant_with_invalid_date(self):
# Get usage for tenant with invalid date
@@ -60,7 +60,7 @@ class TenantUsagesNegativeTestJSON(base.BaseV2ComputeAdminTest):
self.adm_client.get_tenant_usage,
self.client.tenant_id, params)
- @test.attr(type=['negative', 'gate'])
+ @test.attr(type=['negative'])
@test.idempotent_id('bbe6fe2c-15d8-404c-a0a2-44fad0ad5cc7')
def test_list_usage_all_tenants_with_non_admin_user(self):
# Get usage for all tenants with non admin user
diff --git a/tempest/api/compute/base.py b/tempest/api/compute/base.py
index 9f1a5488a..eca634dbe 100644
--- a/tempest/api/compute/base.py
+++ b/tempest/api/compute/base.py
@@ -20,8 +20,6 @@ from oslo_utils import excutils
from tempest_lib.common.utils import data_utils
from tempest_lib import exceptions as lib_exc
-from tempest import clients
-from tempest.common import credentials
from tempest.common import fixed_network
from tempest import config
from tempest import exceptions
@@ -38,6 +36,10 @@ class BaseComputeTest(tempest.test.BaseTestCase):
_api_version = 2
force_tenant_isolation = False
+ # TODO(andreaf) We should care also for the alt_manager here
+ # but only once client lazy load in the manager is done
+ credentials = ['primary']
+
@classmethod
def skip_checks(cls):
super(BaseComputeTest, cls).skip_checks()
@@ -50,12 +52,6 @@ class BaseComputeTest(tempest.test.BaseTestCase):
def setup_credentials(cls):
cls.set_network_resources()
super(BaseComputeTest, cls).setup_credentials()
- # TODO(andreaf) WE should care also for the alt_manager here
- # but only once client lazy load in the manager is done
- cls.os = cls.get_client_manager()
- # Note that we put this here and not in skip_checks because in
- # the case of preprovisioned users we won't know if we can get
- # two distinct users until we go and lock them
cls.multi_user = cls.check_multi_user()
@classmethod
@@ -350,18 +346,7 @@ class BaseV2ComputeTest(BaseComputeTest):
class BaseComputeAdminTest(BaseComputeTest):
"""Base test case class for Compute Admin API tests."""
- @classmethod
- def skip_checks(cls):
- super(BaseComputeAdminTest, cls).skip_checks()
- if not credentials.is_admin_available():
- msg = ("Missing Identity Admin API credentials in configuration.")
- raise cls.skipException(msg)
-
- @classmethod
- def setup_credentials(cls):
- super(BaseComputeAdminTest, cls).setup_credentials()
- creds = cls.isolated_creds.get_admin_creds()
- cls.os_adm = clients.Manager(credentials=creds)
+ credentials = ['primary', 'admin']
@classmethod
def setup_clients(cls):
diff --git a/tempest/api/compute/certificates/test_certificates.py b/tempest/api/compute/certificates/test_certificates.py
index 2be201a81..5f6878694 100644
--- a/tempest/api/compute/certificates/test_certificates.py
+++ b/tempest/api/compute/certificates/test_certificates.py
@@ -21,7 +21,6 @@ class CertificatesV2TestJSON(base.BaseComputeTest):
_api_version = 2
- @test.attr(type='gate')
@test.idempotent_id('c070a441-b08e-447e-a733-905909535b1b')
def test_create_root_certificate(self):
# create certificates
@@ -29,10 +28,9 @@ class CertificatesV2TestJSON(base.BaseComputeTest):
self.assertIn('data', body)
self.assertIn('private_key', body)
- @test.attr(type='gate')
@test.idempotent_id('3ac273d0-92d2-4632-bdfc-afbc21d4606c')
def test_get_root_certificate(self):
# get the root certificate
- body = self.certificates_client.get_certificate('root')
+ body = self.certificates_client.show_certificate('root')
self.assertIn('data', body)
self.assertIn('private_key', body)
diff --git a/tempest/api/compute/flavors/test_flavors.py b/tempest/api/compute/flavors/test_flavors.py
index 8a662828e..6c71c9461 100644
--- a/tempest/api/compute/flavors/test_flavors.py
+++ b/tempest/api/compute/flavors/test_flavors.py
@@ -53,7 +53,6 @@ class FlavorsV2TestJSON(base.BaseComputeTest):
flavor = self.client.get_flavor_details(self.flavor_ref)
self.assertEqual(self.flavor_ref, flavor['id'])
- @test.attr(type='gate')
@test.idempotent_id('8d7691b3-6ed4-411a-abc9-2839a765adab')
def test_list_flavors_limit_results(self):
# Only the expected number of flavors should be returned
@@ -61,7 +60,6 @@ class FlavorsV2TestJSON(base.BaseComputeTest):
flavors = self.client.list_flavors(params)
self.assertEqual(1, len(flavors))
- @test.attr(type='gate')
@test.idempotent_id('b26f6327-2886-467a-82be-cef7a27709cb')
def test_list_flavors_detailed_limit_results(self):
# Only the expected number of flavors (detailed) should be returned
@@ -69,7 +67,6 @@ class FlavorsV2TestJSON(base.BaseComputeTest):
flavors = self.client.list_flavors_with_detail(params)
self.assertEqual(1, len(flavors))
- @test.attr(type='gate')
@test.idempotent_id('e800f879-9828-4bd0-8eae-4f17189951fb')
def test_list_flavors_using_marker(self):
# The list of flavors should start from the provided marker
@@ -81,7 +78,6 @@ class FlavorsV2TestJSON(base.BaseComputeTest):
self.assertFalse(any([i for i in flavors if i['id'] == flavor_id]),
'The list of flavors did not start after the marker.')
- @test.attr(type='gate')
@test.idempotent_id('6db2f0c0-ddee-4162-9c84-0703d3dd1107')
def test_list_flavors_detailed_using_marker(self):
# The list of flavors should start from the provided marker
@@ -93,7 +89,6 @@ class FlavorsV2TestJSON(base.BaseComputeTest):
self.assertFalse(any([i for i in flavors if i['id'] == flavor_id]),
'The list of flavors did not start after the marker.')
- @test.attr(type='gate')
@test.idempotent_id('3df2743e-3034-4e57-a4cb-b6527f6eac79')
def test_list_flavors_detailed_filter_by_min_disk(self):
# The detailed list of flavors should be filtered by disk space
@@ -104,7 +99,6 @@ class FlavorsV2TestJSON(base.BaseComputeTest):
flavors = self.client.list_flavors_with_detail(params)
self.assertFalse(any([i for i in flavors if i['id'] == flavor_id]))
- @test.attr(type='gate')
@test.idempotent_id('09fe7509-b4ee-4b34-bf8b-39532dc47292')
def test_list_flavors_detailed_filter_by_min_ram(self):
# The detailed list of flavors should be filtered by RAM
@@ -115,7 +109,6 @@ class FlavorsV2TestJSON(base.BaseComputeTest):
flavors = self.client.list_flavors_with_detail(params)
self.assertFalse(any([i for i in flavors if i['id'] == flavor_id]))
- @test.attr(type='gate')
@test.idempotent_id('10645a4d-96f5-443f-831b-730711e11dd4')
def test_list_flavors_filter_by_min_disk(self):
# The list of flavors should be filtered by disk space
@@ -126,7 +119,6 @@ class FlavorsV2TestJSON(base.BaseComputeTest):
flavors = self.client.list_flavors(params)
self.assertFalse(any([i for i in flavors if i['id'] == flavor_id]))
- @test.attr(type='gate')
@test.idempotent_id('935cf550-e7c8-4da6-8002-00f92d5edfaa')
def test_list_flavors_filter_by_min_ram(self):
# The list of flavors should be filtered by RAM
diff --git a/tempest/api/compute/floating_ips/test_floating_ips_actions.py b/tempest/api/compute/floating_ips/test_floating_ips_actions.py
index 097c37fd5..5f438fb3e 100644
--- a/tempest/api/compute/floating_ips/test_floating_ips_actions.py
+++ b/tempest/api/compute/floating_ips/test_floating_ips_actions.py
@@ -57,7 +57,6 @@ class FloatingIPsTestJSON(base.BaseFloatingIPsTest):
except lib_exc.NotFound:
pass
- @test.attr(type='gate')
@test.idempotent_id('f7bfb946-297e-41b8-9e8c-aba8e9bb5194')
@test.services('network')
def test_allocate_floating_ip(self):
@@ -73,7 +72,6 @@ class FloatingIPsTestJSON(base.BaseFloatingIPsTest):
body = self.client.list_floating_ips()
self.assertIn(floating_ip_details, body)
- @test.attr(type='gate')
@test.idempotent_id('de45e989-b5ca-4a9b-916b-04a52e7bbb8b')
@test.services('network')
def test_delete_floating_ip(self):
@@ -87,7 +85,6 @@ class FloatingIPsTestJSON(base.BaseFloatingIPsTest):
# Check it was really deleted.
self.client.wait_for_resource_deletion(floating_ip_body['id'])
- @test.attr(type='gate')
@test.idempotent_id('307efa27-dc6f-48a0-8cd2-162ce3ef0b52')
@test.services('network')
def test_associate_disassociate_floating_ip(self):
@@ -108,7 +105,6 @@ class FloatingIPsTestJSON(base.BaseFloatingIPsTest):
self.floating_ip,
self.server_id)
- @test.attr(type='gate')
@test.idempotent_id('6edef4b2-aaf1-4abc-bbe3-993e2561e0fe')
@test.services('network')
def test_associate_already_associated_floating_ip(self):
diff --git a/tempest/api/compute/floating_ips/test_floating_ips_actions_negative.py b/tempest/api/compute/floating_ips/test_floating_ips_actions_negative.py
index 584b20297..d22d3341b 100644
--- a/tempest/api/compute/floating_ips/test_floating_ips_actions_negative.py
+++ b/tempest/api/compute/floating_ips/test_floating_ips_actions_negative.py
@@ -52,7 +52,7 @@ class FloatingIPsNegativeTestJSON(base.BaseFloatingIPsTest):
if cls.non_exist_id not in cls.floating_ip_ids:
break
- @test.attr(type=['negative', 'gate'])
+ @test.attr(type=['negative'])
@test.idempotent_id('6e0f059b-e4dd-48fb-8207-06e3bba5b074')
@test.services('network')
def test_allocate_floating_ip_from_nonexistent_pool(self):
@@ -62,7 +62,7 @@ class FloatingIPsNegativeTestJSON(base.BaseFloatingIPsTest):
self.client.create_floating_ip,
"non_exist_pool")
- @test.attr(type=['negative', 'gate'])
+ @test.attr(type=['negative'])
@test.idempotent_id('ae1c55a8-552b-44d4-bfb6-2a115a15d0ba')
@test.services('network')
def test_delete_nonexistent_floating_ip(self):
@@ -73,7 +73,7 @@ class FloatingIPsNegativeTestJSON(base.BaseFloatingIPsTest):
self.assertRaises(lib_exc.NotFound, self.client.delete_floating_ip,
self.non_exist_id)
- @test.attr(type=['negative', 'gate'])
+ @test.attr(type=['negative'])
@test.idempotent_id('595fa616-1a71-4670-9614-46564ac49a4c')
@test.services('network')
def test_associate_nonexistent_floating_ip(self):
@@ -84,7 +84,7 @@ class FloatingIPsNegativeTestJSON(base.BaseFloatingIPsTest):
self.client.associate_floating_ip_to_server,
"0.0.0.0", self.server_id)
- @test.attr(type=['negative', 'gate'])
+ @test.attr(type=['negative'])
@test.idempotent_id('0a081a66-e568-4e6b-aa62-9587a876dca8')
@test.services('network')
def test_dissociate_nonexistent_floating_ip(self):
@@ -94,7 +94,7 @@ class FloatingIPsNegativeTestJSON(base.BaseFloatingIPsTest):
self.client.disassociate_floating_ip_from_server,
"0.0.0.0", self.server_id)
- @test.attr(type=['negative', 'gate'])
+ @test.attr(type=['negative'])
@test.idempotent_id('804b4fcb-bbf5-412f-925d-896672b61eb3')
@test.services('network')
def test_associate_ip_to_server_without_passing_floating_ip(self):
diff --git a/tempest/api/compute/floating_ips/test_list_floating_ips.py b/tempest/api/compute/floating_ips/test_list_floating_ips.py
index c18ecb73b..62bc92c06 100644
--- a/tempest/api/compute/floating_ips/test_list_floating_ips.py
+++ b/tempest/api/compute/floating_ips/test_list_floating_ips.py
@@ -40,7 +40,6 @@ class FloatingIPDetailsTestJSON(base.BaseV2ComputeTest):
cls.client.delete_floating_ip(cls.floating_ip_id[i])
super(FloatingIPDetailsTestJSON, cls).resource_cleanup()
- @test.attr(type='gate')
@test.idempotent_id('16db31c3-fb85-40c9-bbe2-8cf7b67ff99f')
@test.services('network')
def test_list_floating_ips(self):
@@ -52,7 +51,6 @@ class FloatingIPDetailsTestJSON(base.BaseV2ComputeTest):
for i in range(3):
self.assertIn(self.floating_ip[i], floating_ips)
- @test.attr(type='gate')
@test.idempotent_id('eef497e0-8ff7-43c8-85ef-558440574f84')
@test.services('network')
def test_get_floating_ip_details(self):
@@ -74,7 +72,6 @@ class FloatingIPDetailsTestJSON(base.BaseV2ComputeTest):
body['fixed_ip'])
self.assertEqual(floating_ip_id, body['id'])
- @test.attr(type='gate')
@test.idempotent_id('df389fc8-56f5-43cc-b290-20eda39854d3')
@test.services('network')
def test_list_floating_ip_pools(self):
diff --git a/tempest/api/compute/floating_ips/test_list_floating_ips_negative.py b/tempest/api/compute/floating_ips/test_list_floating_ips_negative.py
index f0ce6ded0..e1e30a4b8 100644
--- a/tempest/api/compute/floating_ips/test_list_floating_ips_negative.py
+++ b/tempest/api/compute/floating_ips/test_list_floating_ips_negative.py
@@ -32,7 +32,7 @@ class FloatingIPDetailsNegativeTestJSON(base.BaseV2ComputeTest):
super(FloatingIPDetailsNegativeTestJSON, cls).setup_clients()
cls.client = cls.floating_ips_client
- @test.attr(type=['negative', 'gate'])
+ @test.attr(type=['negative'])
@test.idempotent_id('7ab18834-4a4b-4f28-a2c5-440579866695')
@test.services('network')
def test_get_nonexistent_floating_ip_details(self):
diff --git a/tempest/api/compute/images/test_image_metadata.py b/tempest/api/compute/images/test_image_metadata.py
index 52d47dd57..9664c6135 100644
--- a/tempest/api/compute/images/test_image_metadata.py
+++ b/tempest/api/compute/images/test_image_metadata.py
@@ -60,7 +60,6 @@ class ImagesMetadataTestJSON(base.BaseV2ComputeTest):
meta = {'os_version': 'value1', 'os_distro': 'value2'}
self.client.set_image_metadata(self.image_id, meta)
- @test.attr(type='gate')
@test.idempotent_id('37ec6edd-cf30-4c53-bd45-ae74db6b0531')
def test_list_image_metadata(self):
# All metadata key/value pairs for an image should be returned
@@ -68,7 +67,6 @@ class ImagesMetadataTestJSON(base.BaseV2ComputeTest):
expected = {'os_version': 'value1', 'os_distro': 'value2'}
self.assertEqual(expected, resp_metadata)
- @test.attr(type='gate')
@test.idempotent_id('ece7befc-d3ce-42a4-b4be-c3067a418c29')
def test_set_image_metadata(self):
# The metadata for the image should match the new values
@@ -79,7 +77,6 @@ class ImagesMetadataTestJSON(base.BaseV2ComputeTest):
resp_metadata = self.client.list_image_metadata(self.image_id)
self.assertEqual(req_metadata, resp_metadata)
- @test.attr(type='gate')
@test.idempotent_id('7b491c11-a9d5-40fe-a696-7f7e03d3fea2')
def test_update_image_metadata(self):
# The metadata for the image should match the updated values
@@ -93,7 +90,6 @@ class ImagesMetadataTestJSON(base.BaseV2ComputeTest):
'architecture': 'value3'}
self.assertEqual(expected, resp_metadata)
- @test.attr(type='gate')
@test.idempotent_id('4f5db52f-6685-4c75-b848-f4bb363f9aa6')
def test_get_image_metadata_item(self):
# The value for a specific metadata key should be returned
@@ -101,7 +97,6 @@ class ImagesMetadataTestJSON(base.BaseV2ComputeTest):
'os_distro')
self.assertEqual('value2', meta['os_distro'])
- @test.attr(type='gate')
@test.idempotent_id('f2de776a-4778-4d90-a5da-aae63aee64ae')
def test_set_image_metadata_item(self):
# The value provided for the given meta item should be set for
@@ -113,7 +108,6 @@ class ImagesMetadataTestJSON(base.BaseV2ComputeTest):
expected = {'os_version': 'alt', 'os_distro': 'value2'}
self.assertEqual(expected, resp_metadata)
- @test.attr(type='gate')
@test.idempotent_id('a013796c-ba37-4bb5-8602-d944511def14')
def test_delete_image_metadata_item(self):
# The metadata value/key pair should be deleted from the image
diff --git a/tempest/api/compute/images/test_image_metadata_negative.py b/tempest/api/compute/images/test_image_metadata_negative.py
index 3c2302a62..e44fbfc71 100644
--- a/tempest/api/compute/images/test_image_metadata_negative.py
+++ b/tempest/api/compute/images/test_image_metadata_negative.py
@@ -27,7 +27,7 @@ class ImagesMetadataTestJSON(base.BaseV2ComputeTest):
super(ImagesMetadataTestJSON, cls).setup_clients()
cls.client = cls.images_client
- @test.attr(type=['negative', 'gate'])
+ @test.attr(type=['negative'])
@test.idempotent_id('94069db2-792f-4fa8-8bd3-2271a6e0c095')
def test_list_nonexistent_image_metadata(self):
# Negative test: List on nonexistent image
@@ -35,7 +35,7 @@ class ImagesMetadataTestJSON(base.BaseV2ComputeTest):
self.assertRaises(lib_exc.NotFound, self.client.list_image_metadata,
data_utils.rand_uuid())
- @test.attr(type=['negative', 'gate'])
+ @test.attr(type=['negative'])
@test.idempotent_id('a403ef9e-9f95-427c-b70a-3ce3388796f1')
def test_update_nonexistent_image_metadata(self):
# Negative test:An update should not happen for a non-existent image
@@ -44,7 +44,7 @@ class ImagesMetadataTestJSON(base.BaseV2ComputeTest):
self.client.update_image_metadata,
data_utils.rand_uuid(), meta)
- @test.attr(type=['negative', 'gate'])
+ @test.attr(type=['negative'])
@test.idempotent_id('41ae052c-6ee6-405c-985e-5712393a620d')
def test_get_nonexistent_image_metadata_item(self):
# Negative test: Get on non-existent image should not happen
@@ -52,7 +52,7 @@ class ImagesMetadataTestJSON(base.BaseV2ComputeTest):
self.client.get_image_metadata_item,
data_utils.rand_uuid(), 'os_version')
- @test.attr(type=['negative', 'gate'])
+ @test.attr(type=['negative'])
@test.idempotent_id('dc64f2ce-77e8-45b0-88c8-e15041d08eaf')
def test_set_nonexistent_image_metadata(self):
# Negative test: Metadata should not be set to a non-existent image
@@ -60,7 +60,7 @@ class ImagesMetadataTestJSON(base.BaseV2ComputeTest):
self.assertRaises(lib_exc.NotFound, self.client.set_image_metadata,
data_utils.rand_uuid(), meta)
- @test.attr(type=['negative', 'gate'])
+ @test.attr(type=['negative'])
@test.idempotent_id('2154fd03-ab54-457c-8874-e6e3eb56e9cf')
def test_set_nonexistent_image_metadata_item(self):
# Negative test: Metadata item should not be set to a
@@ -71,7 +71,7 @@ class ImagesMetadataTestJSON(base.BaseV2ComputeTest):
data_utils.rand_uuid(), 'os_distro',
meta)
- @test.attr(type=['negative', 'gate'])
+ @test.attr(type=['negative'])
@test.idempotent_id('848e157f-6bcf-4b2e-a5dd-5124025a8518')
def test_delete_nonexistent_image_metadata_item(self):
# Negative test: Shouldn't be able to delete metadata
diff --git a/tempest/api/compute/images/test_images.py b/tempest/api/compute/images/test_images.py
index 9591b3835..2896f14e6 100644
--- a/tempest/api/compute/images/test_images.py
+++ b/tempest/api/compute/images/test_images.py
@@ -40,7 +40,6 @@ class ImagesTestJSON(base.BaseV2ComputeTest):
cls.client = cls.images_client
cls.servers_client = cls.servers_client
- @test.attr(type='gate')
@test.idempotent_id('aa06b52b-2db5-4807-b218-9441f75d74e3')
def test_delete_saving_image(self):
snapshot_name = data_utils.rand_name('test-snap')
diff --git a/tempest/api/compute/images/test_images_negative.py b/tempest/api/compute/images/test_images_negative.py
index ad502ad44..6555b6495 100644
--- a/tempest/api/compute/images/test_images_negative.py
+++ b/tempest/api/compute/images/test_images_negative.py
@@ -41,7 +41,7 @@ class ImagesNegativeTestJSON(base.BaseV2ComputeTest):
cls.client = cls.images_client
cls.servers_client = cls.servers_client
- @test.attr(type=['negative', 'gate'])
+ @test.attr(type=['negative'])
@test.idempotent_id('6cd5a89d-5b47-46a7-93bc-3916f0d84973')
def test_create_image_from_deleted_server(self):
# An image should not be created if the server instance is removed
@@ -57,7 +57,7 @@ class ImagesNegativeTestJSON(base.BaseV2ComputeTest):
self.create_image_from_server,
server['id'], name=name, meta=meta)
- @test.attr(type=['negative', 'gate'])
+ @test.attr(type=['negative'])
@test.idempotent_id('82c5b0c4-9dbd-463c-872b-20c4755aae7f')
def test_create_image_from_invalid_server(self):
# An image should not be created with invalid server id
@@ -69,7 +69,7 @@ class ImagesNegativeTestJSON(base.BaseV2ComputeTest):
self.assertRaises(lib_exc.NotFound, self.create_image_from_server,
'!@#$%^&*()', name=name, meta=meta)
- @test.attr(type=['negative', 'gate'])
+ @test.attr(type=['negative'])
@test.idempotent_id('aaacd1d0-55a2-4ce8-818a-b5439df8adc9')
def test_create_image_from_stopped_server(self):
server = self.create_test_server(wait_until='ACTIVE')
@@ -85,7 +85,7 @@ class ImagesNegativeTestJSON(base.BaseV2ComputeTest):
self.addCleanup(self.client.delete_image, image['id'])
self.assertEqual(snapshot_name, image['name'])
- @test.attr(type=['negative', 'gate'])
+ @test.attr(type=['negative'])
@test.idempotent_id('ec176029-73dc-4037-8d72-2e4ff60cf538')
def test_create_image_specify_uuid_35_characters_or_less(self):
# Return an error if Image ID passed is 35 characters or less
@@ -94,7 +94,7 @@ class ImagesNegativeTestJSON(base.BaseV2ComputeTest):
self.assertRaises(lib_exc.NotFound, self.client.create_image,
test_uuid, snapshot_name)
- @test.attr(type=['negative', 'gate'])
+ @test.attr(type=['negative'])
@test.idempotent_id('36741560-510e-4cc2-8641-55fe4dfb2437')
def test_create_image_specify_uuid_37_characters_or_more(self):
# Return an error if Image ID passed is 37 characters or more
@@ -103,14 +103,14 @@ class ImagesNegativeTestJSON(base.BaseV2ComputeTest):
self.assertRaises(lib_exc.NotFound, self.client.create_image,
test_uuid, snapshot_name)
- @test.attr(type=['negative', 'gate'])
+ @test.attr(type=['negative'])
@test.idempotent_id('381acb65-785a-4942-94ce-d8f8c84f1f0f')
def test_delete_image_with_invalid_image_id(self):
# An image should not be deleted with invalid image id
self.assertRaises(lib_exc.NotFound, self.client.delete_image,
'!@$%^&*()')
- @test.attr(type=['negative', 'gate'])
+ @test.attr(type=['negative'])
@test.idempotent_id('137aef61-39f7-44a1-8ddf-0adf82511701')
def test_delete_non_existent_image(self):
# Return an error while trying to delete a non-existent image
@@ -119,13 +119,13 @@ class ImagesNegativeTestJSON(base.BaseV2ComputeTest):
self.assertRaises(lib_exc.NotFound, self.client.delete_image,
non_existent_image_id)
- @test.attr(type=['negative', 'gate'])
+ @test.attr(type=['negative'])
@test.idempotent_id('e6e41425-af5c-4fe6-a4b5-7b7b963ffda5')
def test_delete_image_blank_id(self):
# Return an error while trying to delete an image with blank Id
self.assertRaises(lib_exc.NotFound, self.client.delete_image, '')
- @test.attr(type=['negative', 'gate'])
+ @test.attr(type=['negative'])
@test.idempotent_id('924540c3-f1f1-444c-8f58-718958b6724e')
def test_delete_image_non_hex_string_id(self):
# Return an error while trying to delete an image with non hex id
@@ -133,13 +133,13 @@ class ImagesNegativeTestJSON(base.BaseV2ComputeTest):
self.assertRaises(lib_exc.NotFound, self.client.delete_image,
image_id)
- @test.attr(type=['negative', 'gate'])
+ @test.attr(type=['negative'])
@test.idempotent_id('68e2c175-bd26-4407-ac0f-4ea9ce2139ea')
def test_delete_image_negative_image_id(self):
# Return an error while trying to delete an image with negative id
self.assertRaises(lib_exc.NotFound, self.client.delete_image, -1)
- @test.attr(type=['negative', 'gate'])
+ @test.attr(type=['negative'])
@test.idempotent_id('b340030d-82cd-4066-a314-c72fb7c59277')
def test_delete_image_id_is_over_35_character_limit(self):
# Return an error while trying to delete image with id over limit
diff --git a/tempest/api/compute/images/test_images_oneserver.py b/tempest/api/compute/images/test_images_oneserver.py
index 1d26a00c8..29682084b 100644
--- a/tempest/api/compute/images/test_images_oneserver.py
+++ b/tempest/api/compute/images/test_images_oneserver.py
@@ -103,7 +103,6 @@ class ImagesOneServerTestJSON(base.BaseV2ComputeTest):
self.client.delete_image(image_id)
self.client.wait_for_resource_deletion(image_id)
- @test.attr(type=['gate'])
@test.idempotent_id('3b7c6fe4-dfe7-477c-9243-b06359db51e6')
def test_create_image_specify_multibyte_character_image_name(self):
# prefix character is:
diff --git a/tempest/api/compute/images/test_images_oneserver_negative.py b/tempest/api/compute/images/test_images_oneserver_negative.py
index 18ce2118b..aa120446d 100644
--- a/tempest/api/compute/images/test_images_oneserver_negative.py
+++ b/tempest/api/compute/images/test_images_oneserver_negative.py
@@ -80,7 +80,7 @@ class ImagesOneServerNegativeTestJSON(base.BaseV2ComputeTest):
cls.image_ids = []
- @test.attr(type=['negative', 'gate'])
+ @test.attr(type=['negative'])
@test.idempotent_id('55d1d38c-dd66-4933-9c8e-7d92aeb60ddc')
def test_create_image_specify_invalid_metadata(self):
# Return an error when creating image with invalid metadata
@@ -89,7 +89,7 @@ class ImagesOneServerNegativeTestJSON(base.BaseV2ComputeTest):
self.assertRaises(lib_exc.BadRequest, self.client.create_image,
self.server_id, snapshot_name, meta)
- @test.attr(type=['negative', 'gate'])
+ @test.attr(type=['negative'])
@test.idempotent_id('3d24d11f-5366-4536-bd28-cff32b748eca')
def test_create_image_specify_metadata_over_limits(self):
# Return an error when creating image with meta data over 256 chars
@@ -98,7 +98,7 @@ class ImagesOneServerNegativeTestJSON(base.BaseV2ComputeTest):
self.assertRaises(lib_exc.BadRequest, self.client.create_image,
self.server_id, snapshot_name, meta)
- @test.attr(type=['negative', 'gate'])
+ @test.attr(type=['negative'])
@test.idempotent_id('0460efcf-ee88-4f94-acef-1bf658695456')
def test_create_second_image_when_first_image_is_being_saved(self):
# Disallow creating another image when first image is being saved
@@ -116,7 +116,7 @@ class ImagesOneServerNegativeTestJSON(base.BaseV2ComputeTest):
self.assertRaises(lib_exc.Conflict, self.client.create_image,
self.server_id, alt_snapshot_name)
- @test.attr(type=['negative', 'gate'])
+ @test.attr(type=['negative'])
@test.idempotent_id('084f0cbc-500a-4963-8a4e-312905862581')
def test_create_image_specify_name_over_256_chars(self):
# Return an error if snapshot name over 256 characters is passed
@@ -125,7 +125,7 @@ class ImagesOneServerNegativeTestJSON(base.BaseV2ComputeTest):
self.assertRaises(lib_exc.BadRequest, self.client.create_image,
self.server_id, snapshot_name)
- @test.attr(type=['negative', 'gate'])
+ @test.attr(type=['negative'])
@test.idempotent_id('0894954d-2db2-4195-a45b-ffec0bc0187e')
def test_delete_image_that_is_not_yet_active(self):
# Return an error while trying to delete an image what is creating
diff --git a/tempest/api/compute/images/test_list_image_filters.py b/tempest/api/compute/images/test_list_image_filters.py
index 430ca3572..abe7be541 100644
--- a/tempest/api/compute/images/test_list_image_filters.py
+++ b/tempest/api/compute/images/test_list_image_filters.py
@@ -100,7 +100,6 @@ class ListImageFiltersTestJSON(base.BaseV2ComputeTest):
cls.server1['id'], wait_until='ACTIVE')
cls.snapshot2_id = cls.snapshot2['id']
- @test.attr(type='gate')
@test.idempotent_id('a3f5b513-aeb3-42a9-b18e-f091ef73254d')
def test_list_images_filter_by_status(self):
# The list of images should contain only images with the
@@ -112,7 +111,6 @@ class ListImageFiltersTestJSON(base.BaseV2ComputeTest):
self.assertTrue(any([i for i in images if i['id'] == self.image2_id]))
self.assertTrue(any([i for i in images if i['id'] == self.image3_id]))
- @test.attr(type='gate')
@test.idempotent_id('33163b73-79f5-4d07-a7ea-9213bcc468ff')
def test_list_images_filter_by_name(self):
# List of all images should contain the expected images filtered
@@ -127,7 +125,6 @@ class ListImageFiltersTestJSON(base.BaseV2ComputeTest):
@test.idempotent_id('9f238683-c763-45aa-b848-232ec3ce3105')
@testtools.skipUnless(CONF.compute_feature_enabled.snapshot,
'Snapshotting is not available.')
- @test.attr(type='gate')
def test_list_images_filter_by_server_id(self):
# The images should contain images filtered by server id
params = {'server': self.server1['id']}
@@ -145,7 +142,6 @@ class ListImageFiltersTestJSON(base.BaseV2ComputeTest):
@test.idempotent_id('05a377b8-28cf-4734-a1e6-2ab5c38bf606')
@testtools.skipUnless(CONF.compute_feature_enabled.snapshot,
'Snapshotting is not available.')
- @test.attr(type='gate')
def test_list_images_filter_by_server_ref(self):
# The list of servers should be filtered by server ref
server_links = self.server2['links']
@@ -165,7 +161,6 @@ class ListImageFiltersTestJSON(base.BaseV2ComputeTest):
@test.idempotent_id('e3356918-4d3e-4756-81d5-abc4524ba29f')
@testtools.skipUnless(CONF.compute_feature_enabled.snapshot,
'Snapshotting is not available.')
- @test.attr(type='gate')
def test_list_images_filter_by_type(self):
# The list of servers should be filtered by image type
params = {'type': 'snapshot'}
@@ -180,7 +175,6 @@ class ListImageFiltersTestJSON(base.BaseV2ComputeTest):
self.assertFalse(any([i for i in images
if i['id'] == self.image_ref]))
- @test.attr(type='gate')
@test.idempotent_id('3a484ca9-67ba-451e-b494-7fcf28d32d62')
def test_list_images_limit_results(self):
# Verify only the expected number of results are returned
@@ -188,7 +182,6 @@ class ListImageFiltersTestJSON(base.BaseV2ComputeTest):
images = self.client.list_images(params)
self.assertEqual(1, len([x for x in images if 'id' in x]))
- @test.attr(type='gate')
@test.idempotent_id('18bac3ae-da27-436c-92a9-b22474d13aab')
def test_list_images_filter_by_changes_since(self):
# Verify only updated images are returned in the detailed list
@@ -200,7 +193,6 @@ class ListImageFiltersTestJSON(base.BaseV2ComputeTest):
found = any([i for i in images if i['id'] == self.image3_id])
self.assertTrue(found)
- @test.attr(type='gate')
@test.idempotent_id('9b0ea018-6185-4f71-948a-a123a107988e')
def test_list_images_with_detail_filter_by_status(self):
# Detailed list of all images should only contain images
@@ -212,7 +204,6 @@ class ListImageFiltersTestJSON(base.BaseV2ComputeTest):
self.assertTrue(any([i for i in images if i['id'] == self.image2_id]))
self.assertTrue(any([i for i in images if i['id'] == self.image3_id]))
- @test.attr(type='gate')
@test.idempotent_id('644ea267-9bd9-4f3b-af9f-dffa02396a17')
def test_list_images_with_detail_filter_by_name(self):
# Detailed list of all images should contain the expected
@@ -224,7 +215,6 @@ class ListImageFiltersTestJSON(base.BaseV2ComputeTest):
self.assertFalse(any([i for i in images if i['id'] == self.image2_id]))
self.assertFalse(any([i for i in images if i['id'] == self.image3_id]))
- @test.attr(type='gate')
@test.idempotent_id('ba2fa9a9-b672-47cc-b354-3b4c0600e2cb')
def test_list_images_with_detail_limit_results(self):
# Verify only the expected number of results (with full details)
@@ -236,7 +226,6 @@ class ListImageFiltersTestJSON(base.BaseV2ComputeTest):
@test.idempotent_id('8c78f822-203b-4bf6-8bba-56ebd551cf84')
@testtools.skipUnless(CONF.compute_feature_enabled.snapshot,
'Snapshotting is not available.')
- @test.attr(type='gate')
def test_list_images_with_detail_filter_by_server_ref(self):
# Detailed list of servers should be filtered by server ref
server_links = self.server2['links']
@@ -256,7 +245,6 @@ class ListImageFiltersTestJSON(base.BaseV2ComputeTest):
@test.idempotent_id('888c0cc0-7223-43c5-9db0-b125fd0a393b')
@testtools.skipUnless(CONF.compute_feature_enabled.snapshot,
'Snapshotting is not available.')
- @test.attr(type='gate')
def test_list_images_with_detail_filter_by_type(self):
# The detailed list of servers should be filtered by image type
params = {'type': 'snapshot'}
@@ -272,7 +260,6 @@ class ListImageFiltersTestJSON(base.BaseV2ComputeTest):
self.assertFalse(any([i for i in images
if i['id'] == self.image_ref]))
- @test.attr(type='gate')
@test.idempotent_id('7d439e18-ac2e-4827-b049-7e18004712c4')
def test_list_images_with_detail_filter_by_changes_since(self):
# Verify an update image is returned
diff --git a/tempest/api/compute/images/test_list_image_filters_negative.py b/tempest/api/compute/images/test_list_image_filters_negative.py
index 204bf3e09..334516b34 100644
--- a/tempest/api/compute/images/test_list_image_filters_negative.py
+++ b/tempest/api/compute/images/test_list_image_filters_negative.py
@@ -36,7 +36,7 @@ class ListImageFiltersNegativeTestJSON(base.BaseV2ComputeTest):
super(ListImageFiltersNegativeTestJSON, cls).setup_clients()
cls.client = cls.images_client
- @test.attr(type=['negative', 'gate'])
+ @test.attr(type=['negative'])
@test.idempotent_id('391b0440-432c-4d4b-b5da-c5096aa247eb')
def test_get_nonexistent_image(self):
# Check raises a NotFound
diff --git a/tempest/api/compute/keypairs/test_keypairs.py b/tempest/api/compute/keypairs/test_keypairs.py
index 20247d014..01e3c869e 100644
--- a/tempest/api/compute/keypairs/test_keypairs.py
+++ b/tempest/api/compute/keypairs/test_keypairs.py
@@ -36,7 +36,6 @@ class KeyPairsV2TestJSON(base.BaseComputeTest):
self.addCleanup(self._delete_keypair, keypair_name)
return body
- @test.attr(type='gate')
@test.idempotent_id('1d1dbedb-d7a0-432a-9d09-83f543c3c19b')
def test_keypairs_create_list_delete(self):
# Keypairs created should be available in the response list
@@ -65,7 +64,6 @@ class KeyPairsV2TestJSON(base.BaseComputeTest):
"Failed to find keypairs %s in fetched list"
% ', '.join(m_key['name'] for m_key in missing_kps))
- @test.attr(type='gate')
@test.idempotent_id('6c1d3123-4519-4742-9194-622cb1714b7d')
def test_keypair_create_delete(self):
# Keypair should be created, verified and deleted
@@ -79,7 +77,6 @@ class KeyPairsV2TestJSON(base.BaseComputeTest):
self.assertTrue(private_key is not None,
"Field private_key is empty or not found.")
- @test.attr(type='gate')
@test.idempotent_id('a4233d5d-52d8-47cc-9a25-e1864527e3df')
def test_get_keypair_detail(self):
# Keypair should be created, Got details by name and deleted
@@ -95,7 +92,6 @@ class KeyPairsV2TestJSON(base.BaseComputeTest):
self.assertTrue(public_key is not None,
"Field public_key is empty or not found.")
- @test.attr(type='gate')
@test.idempotent_id('39c90c6a-304a-49dd-95ec-2366129def05')
def test_keypair_create_with_pub_key(self):
# Keypair should be created with a given public key
diff --git a/tempest/api/compute/keypairs/test_keypairs_negative.py b/tempest/api/compute/keypairs/test_keypairs_negative.py
index 6aa0939e2..78db74eea 100644
--- a/tempest/api/compute/keypairs/test_keypairs_negative.py
+++ b/tempest/api/compute/keypairs/test_keypairs_negative.py
@@ -32,7 +32,7 @@ class KeyPairsNegativeTestJSON(base.BaseV2ComputeTest):
self.client.create_keypair(keypair_name, pub_key)
self.addCleanup(self.client.delete_keypair, keypair_name)
- @test.attr(type=['negative', 'gate'])
+ @test.attr(type=['negative'])
@test.idempotent_id('29cca892-46ae-4d48-bc32-8fe7e731eb81')
def test_keypair_create_with_invalid_pub_key(self):
# Keypair should not be created with a non RSA public key
@@ -41,7 +41,7 @@ class KeyPairsNegativeTestJSON(base.BaseV2ComputeTest):
self.assertRaises(lib_exc.BadRequest,
self._create_keypair, k_name, pub_key)
- @test.attr(type=['negative', 'gate'])
+ @test.attr(type=['negative'])
@test.idempotent_id('7cc32e47-4c42-489d-9623-c5e2cb5a2fa5')
def test_keypair_delete_nonexistent_key(self):
# Non-existent key deletion should throw a proper error
@@ -49,7 +49,7 @@ class KeyPairsNegativeTestJSON(base.BaseV2ComputeTest):
self.assertRaises(lib_exc.NotFound, self.client.delete_keypair,
k_name)
- @test.attr(type=['negative', 'gate'])
+ @test.attr(type=['negative'])
@test.idempotent_id('dade320e-69ca-42a9-ba4a-345300f127e0')
def test_create_keypair_with_empty_public_key(self):
# Keypair should not be created with an empty public key
@@ -58,7 +58,7 @@ class KeyPairsNegativeTestJSON(base.BaseV2ComputeTest):
self.assertRaises(lib_exc.BadRequest, self._create_keypair,
k_name, pub_key)
- @test.attr(type=['negative', 'gate'])
+ @test.attr(type=['negative'])
@test.idempotent_id('fc100c19-2926-4b9c-8fdc-d0589ee2f9ff')
def test_create_keypair_when_public_key_bits_exceeds_maximum(self):
# Keypair should not be created when public key bits are too long
@@ -67,7 +67,7 @@ class KeyPairsNegativeTestJSON(base.BaseV2ComputeTest):
self.assertRaises(lib_exc.BadRequest, self._create_keypair,
k_name, pub_key)
- @test.attr(type=['negative', 'gate'])
+ @test.attr(type=['negative'])
@test.idempotent_id('0359a7f1-f002-4682-8073-0c91e4011b7c')
def test_create_keypair_with_duplicate_name(self):
# Keypairs with duplicate names should not be created
@@ -78,14 +78,14 @@ class KeyPairsNegativeTestJSON(base.BaseV2ComputeTest):
k_name)
self.client.delete_keypair(k_name)
- @test.attr(type=['negative', 'gate'])
+ @test.attr(type=['negative'])
@test.idempotent_id('1398abe1-4a84-45fb-9294-89f514daff00')
def test_create_keypair_with_empty_name_string(self):
# Keypairs with name being an empty string should not be created
self.assertRaises(lib_exc.BadRequest, self._create_keypair,
'')
- @test.attr(type=['negative', 'gate'])
+ @test.attr(type=['negative'])
@test.idempotent_id('3faa916f-779f-4103-aca7-dc3538eee1b7')
def test_create_keypair_with_long_keynames(self):
# Keypairs with name longer than 255 chars should not be created
@@ -93,7 +93,7 @@ class KeyPairsNegativeTestJSON(base.BaseV2ComputeTest):
self.assertRaises(lib_exc.BadRequest, self._create_keypair,
k_name)
- @test.attr(type=['negative', 'gate'])
+ @test.attr(type=['negative'])
@test.idempotent_id('45fbe5e0-acb5-49aa-837a-ff8d0719db91')
def test_create_keypair_invalid_name(self):
# Keypairs with name being an invalid name should not be created
diff --git a/tempest/api/compute/limits/test_absolute_limits.py b/tempest/api/compute/limits/test_absolute_limits.py
index 39ed2a1ac..974814cf3 100644
--- a/tempest/api/compute/limits/test_absolute_limits.py
+++ b/tempest/api/compute/limits/test_absolute_limits.py
@@ -24,7 +24,6 @@ class AbsoluteLimitsTestJSON(base.BaseV2ComputeTest):
super(AbsoluteLimitsTestJSON, cls).setup_clients()
cls.client = cls.limits_client
- @test.attr(type='gate')
@test.idempotent_id('b54c66af-6ab6-4cf0-a9e5-a0cb58d75e0b')
def test_absLimits_get(self):
# To check if all limits are present in the response
diff --git a/tempest/api/compute/limits/test_absolute_limits_negative.py b/tempest/api/compute/limits/test_absolute_limits_negative.py
index 843dc1ac6..bdbe3f15c 100644
--- a/tempest/api/compute/limits/test_absolute_limits_negative.py
+++ b/tempest/api/compute/limits/test_absolute_limits_negative.py
@@ -33,7 +33,7 @@ class AbsoluteLimitsNegativeTestJSON(base.BaseV2ComputeTest):
cls.client = cls.limits_client
cls.server_client = cls.servers_client
- @test.attr(type=['negative', 'gate'])
+ @test.attr(type=['negative'])
@test.idempotent_id('215cd465-d8ae-49c9-bf33-9c911913a5c8')
def test_max_image_meta_exceed_limit(self):
# We should not create vm with image meta over maxImageMeta limit
diff --git a/tempest/api/compute/security_groups/test_security_groups_negative.py b/tempest/api/compute/security_groups/test_security_groups_negative.py
index e069f6e24..3a6b42d4f 100644
--- a/tempest/api/compute/security_groups/test_security_groups_negative.py
+++ b/tempest/api/compute/security_groups/test_security_groups_negative.py
@@ -156,7 +156,7 @@ class SecurityGroupsNegativeTestJSON(base.BaseSecurityGroupsTest):
@test.idempotent_id('00579617-fe04-4e1c-9d08-ca7467d2e34b')
@testtools.skipIf(CONF.service_available.neutron,
- "Neutron not check the security_group_id")
+ "Neutron does not check the security group ID")
@test.attr(type=['negative', 'smoke'])
@test.services('network')
def test_update_security_group_with_invalid_sg_id(self):
@@ -171,7 +171,7 @@ class SecurityGroupsNegativeTestJSON(base.BaseSecurityGroupsTest):
@test.idempotent_id('cda8d8b4-59f8-4087-821d-20cf5a03b3b1')
@testtools.skipIf(CONF.service_available.neutron,
- "Neutron not check the security_group_name")
+ "Neutron does not check the security group name")
@test.attr(type=['negative', 'smoke'])
@test.services('network')
def test_update_security_group_with_invalid_sg_name(self):
@@ -187,7 +187,7 @@ class SecurityGroupsNegativeTestJSON(base.BaseSecurityGroupsTest):
@test.idempotent_id('97d12b1c-a610-4194-93f1-ba859e718b45')
@testtools.skipIf(CONF.service_available.neutron,
- "Neutron not check the security_group_description")
+ "Neutron does not check the security group description")
@test.attr(type=['negative', 'smoke'])
@test.services('network')
def test_update_security_group_with_invalid_sg_des(self):
diff --git a/tempest/api/compute/servers/test_availability_zone.py b/tempest/api/compute/servers/test_availability_zone.py
index f3650ac8b..d1fbcec71 100644
--- a/tempest/api/compute/servers/test_availability_zone.py
+++ b/tempest/api/compute/servers/test_availability_zone.py
@@ -28,9 +28,8 @@ class AZV2TestJSON(base.BaseComputeTest):
super(AZV2TestJSON, cls).setup_clients()
cls.client = cls.availability_zone_client
- @test.attr(type='gate')
@test.idempotent_id('a8333aa2-205c-449f-a828-d38c2489bf25')
def test_get_availability_zone_list_with_non_admin_user(self):
# List of availability zone with non-administrator user
- availability_zone = self.client.get_availability_zone_list()
+ availability_zone = self.client.list_availability_zones()
self.assertTrue(len(availability_zone) > 0)
diff --git a/tempest/api/compute/servers/test_create_server.py b/tempest/api/compute/servers/test_create_server.py
index 7f3716c7a..ee756f4c6 100644
--- a/tempest/api/compute/servers/test_create_server.py
+++ b/tempest/api/compute/servers/test_create_server.py
@@ -97,7 +97,6 @@ class ServersTestJSON(base.BaseV2ComputeTest):
@test.idempotent_id('cbc0f52f-05aa-492b-bdc1-84b575ca294b')
@testtools.skipUnless(CONF.compute.run_ssh,
'Instance validation tests are disabled.')
- @test.attr(type='gate')
def test_verify_created_server_vcpus(self):
# Verify that the number of vcpus reported by the instance matches
# the amount stated by the flavor
@@ -109,14 +108,12 @@ class ServersTestJSON(base.BaseV2ComputeTest):
@test.idempotent_id('ac1ad47f-984b-4441-9274-c9079b7a0666')
@testtools.skipUnless(CONF.compute.run_ssh,
'Instance validation tests are disabled.')
- @test.attr(type='gate')
def test_host_name_is_same_as_server_name(self):
# Verify the instance host name is the same as the server name
linux_client = remote_client.RemoteClient(self.server, self.ssh_user,
self.password)
self.assertTrue(linux_client.hostname_equals_servername(self.name))
- @test.attr(type='gate')
@test.idempotent_id('ed20d3fb-9d1f-4329-b160-543fbd5d9811')
def test_create_server_with_scheduler_hint_group(self):
# Create a server with the scheduler hint "group".
@@ -211,7 +208,6 @@ class ServersWithSpecificFlavorTestJSON(base.BaseV2ComputeAdminTest):
@test.idempotent_id('b3c7bcfc-bb5b-4e22-b517-c7f686b802ca')
@testtools.skipUnless(CONF.compute.run_ssh,
'Instance validation tests are disabled.')
- @test.attr(type='gate')
def test_verify_created_server_ephemeral_disk(self):
# Verify that the ephemeral disk is created when creating server
diff --git a/tempest/api/compute/servers/test_delete_server.py b/tempest/api/compute/servers/test_delete_server.py
index 716026536..ac6ef4c71 100644
--- a/tempest/api/compute/servers/test_delete_server.py
+++ b/tempest/api/compute/servers/test_delete_server.py
@@ -32,7 +32,6 @@ class DeleteServersTestJSON(base.BaseV2ComputeTest):
super(DeleteServersTestJSON, cls).setup_clients()
cls.client = cls.servers_client
- @test.attr(type='gate')
@test.idempotent_id('9e6e0c87-3352-42f7-9faf-5d6210dbd159')
def test_delete_server_while_in_building_state(self):
# Delete a server while it's VM state is Building
@@ -40,7 +39,6 @@ class DeleteServersTestJSON(base.BaseV2ComputeTest):
self.client.delete_server(server['id'])
self.client.wait_for_server_termination(server['id'])
- @test.attr(type='gate')
@test.idempotent_id('925fdfb4-5b13-47ea-ac8a-c36ae6fddb05')
def test_delete_active_server(self):
# Delete a server while it's VM state is Active
@@ -48,7 +46,6 @@ class DeleteServersTestJSON(base.BaseV2ComputeTest):
self.client.delete_server(server['id'])
self.client.wait_for_server_termination(server['id'])
- @test.attr(type='gate')
@test.idempotent_id('546d368c-bb6c-4645-979a-83ed16f3a6be')
def test_delete_server_while_in_shutoff_state(self):
# Delete a server while it's VM state is Shutoff
@@ -61,7 +58,6 @@ class DeleteServersTestJSON(base.BaseV2ComputeTest):
@test.idempotent_id('943bd6e8-4d7a-4904-be83-7a6cc2d4213b')
@testtools.skipUnless(CONF.compute_feature_enabled.pause,
'Pause is not available.')
- @test.attr(type='gate')
def test_delete_server_while_in_pause_state(self):
# Delete a server while it's VM state is Pause
server = self.create_test_server(wait_until='ACTIVE')
@@ -73,7 +69,6 @@ class DeleteServersTestJSON(base.BaseV2ComputeTest):
@test.idempotent_id('1f82ebd3-8253-4f4e-b93f-de9b7df56d8b')
@testtools.skipUnless(CONF.compute_feature_enabled.suspend,
'Suspend is not available.')
- @test.attr(type='gate')
def test_delete_server_while_in_suspended_state(self):
# Delete a server while it's VM state is Suspended
server = self.create_test_server(wait_until='ACTIVE')
@@ -85,7 +80,6 @@ class DeleteServersTestJSON(base.BaseV2ComputeTest):
@test.idempotent_id('bb0cb402-09dd-4947-b6e5-5e7e1cfa61ad')
@testtools.skipUnless(CONF.compute_feature_enabled.shelve,
'Shelve is not available.')
- @test.attr(type='gate')
def test_delete_server_while_in_shelved_state(self):
# Delete a server while it's VM state is Shelved
server = self.create_test_server(wait_until='ACTIVE')
@@ -105,7 +99,6 @@ class DeleteServersTestJSON(base.BaseV2ComputeTest):
@test.idempotent_id('ab0c38b4-cdd8-49d3-9b92-0cb898723c01')
@testtools.skipIf(not CONF.compute_feature_enabled.resize,
'Resize not available.')
- @test.attr(type='gate')
def test_delete_server_while_in_verify_resize_state(self):
# Delete a server while it's VM state is VERIFY_RESIZE
server = self.create_test_server(wait_until='ACTIVE')
@@ -116,7 +109,6 @@ class DeleteServersTestJSON(base.BaseV2ComputeTest):
@test.idempotent_id('d0f3f0d6-d9b6-4a32-8da4-23015dcab23c')
@test.services('volume')
- @test.attr(type='gate')
def test_delete_server_while_in_attached_volume(self):
# Delete a server while a volume is attached to it
volumes_client = self.volumes_extensions_client
@@ -146,7 +138,6 @@ class DeleteServersAdminTestJSON(base.BaseV2ComputeAdminTest):
cls.non_admin_client = cls.servers_client
cls.admin_client = cls.os_adm.servers_client
- @test.attr(type='gate')
@test.idempotent_id('99774678-e072-49d1-9d2a-49a59bc56063')
def test_delete_server_while_in_error_state(self):
# Delete a server while it's VM state is error
@@ -159,7 +150,6 @@ class DeleteServersAdminTestJSON(base.BaseV2ComputeAdminTest):
self.servers_client.wait_for_server_termination(server['id'],
ignore_error=True)
- @test.attr(type='gate')
@test.idempotent_id('73177903-6737-4f27-a60c-379e8ae8cf48')
def test_admin_delete_servers_of_others(self):
# Administrator can delete servers of others
diff --git a/tempest/api/compute/servers/test_disk_config.py b/tempest/api/compute/servers/test_disk_config.py
index c4cb2bd0d..848280267 100644
--- a/tempest/api/compute/servers/test_disk_config.py
+++ b/tempest/api/compute/servers/test_disk_config.py
@@ -51,7 +51,6 @@ class ServerDiskConfigTestJSON(base.BaseV2ComputeTest):
server = self.client.get_server(server['id'])
self.assertEqual(disk_config, server['OS-DCF:diskConfig'])
- @test.attr(type='gate')
@test.idempotent_id('bef56b09-2e8c-4883-a370-4950812f430e')
def test_rebuild_server_with_manual_disk_config(self):
# A server should be rebuilt using the manual disk config option
@@ -68,7 +67,6 @@ class ServerDiskConfigTestJSON(base.BaseV2ComputeTest):
server = self.client.get_server(server['id'])
self.assertEqual('MANUAL', server['OS-DCF:diskConfig'])
- @test.attr(type='gate')
@test.idempotent_id('9c9fae77-4feb-402f-8450-bf1c8b609713')
def test_rebuild_server_with_auto_disk_config(self):
# A server should be rebuilt using the auto disk config option
@@ -96,7 +94,6 @@ class ServerDiskConfigTestJSON(base.BaseV2ComputeTest):
@test.idempotent_id('414e7e93-45b5-44bc-8e03-55159c6bfc97')
@testtools.skipUnless(CONF.compute_feature_enabled.resize,
'Resize not available.')
- @test.attr(type='gate')
def test_resize_server_from_manual_to_auto(self):
# A server should be resized from manual to auto disk config
self._update_server_with_disk_config(disk_config='MANUAL')
@@ -114,7 +111,6 @@ class ServerDiskConfigTestJSON(base.BaseV2ComputeTest):
@test.idempotent_id('693d16f3-556c-489a-8bac-3d0ca2490bad')
@testtools.skipUnless(CONF.compute_feature_enabled.resize,
'Resize not available.')
- @test.attr(type='gate')
def test_resize_server_from_auto_to_manual(self):
# A server should be resized from auto to manual disk config
self._update_server_with_disk_config(disk_config='AUTO')
@@ -129,7 +125,6 @@ class ServerDiskConfigTestJSON(base.BaseV2ComputeTest):
server = self.client.get_server(self.server_id)
self.assertEqual('MANUAL', server['OS-DCF:diskConfig'])
- @test.attr(type='gate')
@test.idempotent_id('5ef18867-358d-4de9-b3c9-94d4ba35742f')
def test_update_server_from_auto_to_manual(self):
# A server should be updated from auto to manual disk config
diff --git a/tempest/api/compute/servers/test_instance_actions.py b/tempest/api/compute/servers/test_instance_actions.py
index c80417032..6233c58c1 100644
--- a/tempest/api/compute/servers/test_instance_actions.py
+++ b/tempest/api/compute/servers/test_instance_actions.py
@@ -31,7 +31,6 @@ class InstanceActionsTestJSON(base.BaseV2ComputeTest):
cls.request_id = server.response['x-compute-request-id']
cls.server_id = server['id']
- @test.attr(type='gate')
@test.idempotent_id('77ca5cc5-9990-45e0-ab98-1de8fead201a')
def test_list_instance_actions(self):
# List actions of the provided server
@@ -43,7 +42,6 @@ class InstanceActionsTestJSON(base.BaseV2ComputeTest):
self.assertTrue(any([i for i in body if i['action'] == 'create']))
self.assertTrue(any([i for i in body if i['action'] == 'reboot']))
- @test.attr(type='gate')
@test.idempotent_id('aacc71ca-1d70-4aa5-bbf6-0ff71470e43c')
def test_get_instance_action(self):
# Get the action details of the provided server
diff --git a/tempest/api/compute/servers/test_instance_actions_negative.py b/tempest/api/compute/servers/test_instance_actions_negative.py
index 7635eb83a..afd3b7a31 100644
--- a/tempest/api/compute/servers/test_instance_actions_negative.py
+++ b/tempest/api/compute/servers/test_instance_actions_negative.py
@@ -33,7 +33,7 @@ class InstanceActionsNegativeTestJSON(base.BaseV2ComputeTest):
server = cls.create_test_server(wait_until='ACTIVE')
cls.server_id = server['id']
- @test.attr(type=['negative', 'gate'])
+ @test.attr(type=['negative'])
@test.idempotent_id('67e1fce6-7ec2-45c6-92d4-0a8f1a632910')
def test_list_instance_actions_non_existent_server(self):
# List actions of the non-existent server id
@@ -42,7 +42,7 @@ class InstanceActionsNegativeTestJSON(base.BaseV2ComputeTest):
self.client.list_instance_actions,
non_existent_server_id)
- @test.attr(type=['negative', 'gate'])
+ @test.attr(type=['negative'])
@test.idempotent_id('0269f40a-6f18-456c-b336-c03623c897f1')
def test_get_instance_action_invalid_request(self):
# Get the action details of the provided server with invalid request
diff --git a/tempest/api/compute/servers/test_list_server_filters.py b/tempest/api/compute/servers/test_list_server_filters.py
index eccd6006e..25b28626b 100644
--- a/tempest/api/compute/servers/test_list_server_filters.py
+++ b/tempest/api/compute/servers/test_list_server_filters.py
@@ -93,7 +93,6 @@ class ListServerFiltersTestJSON(base.BaseV2ComputeTest):
@test.idempotent_id('05e8a8e7-9659-459a-989d-92c2f501f4ba')
@utils.skip_unless_attr('multiple_images', 'Only one image found')
- @test.attr(type='gate')
def test_list_servers_filter_by_image(self):
# Filter the list of servers by image
params = {'image': self.image_ref}
@@ -104,7 +103,6 @@ class ListServerFiltersTestJSON(base.BaseV2ComputeTest):
self.assertNotIn(self.s2['id'], map(lambda x: x['id'], servers))
self.assertIn(self.s3['id'], map(lambda x: x['id'], servers))
- @test.attr(type='gate')
@test.idempotent_id('573637f5-7325-47bb-9144-3476d0416908')
def test_list_servers_filter_by_flavor(self):
# Filter the list of servers by flavor
@@ -116,7 +114,6 @@ class ListServerFiltersTestJSON(base.BaseV2ComputeTest):
self.assertNotIn(self.s2['id'], map(lambda x: x['id'], servers))
self.assertIn(self.s3['id'], map(lambda x: x['id'], servers))
- @test.attr(type='gate')
@test.idempotent_id('9b067a7b-7fee-4f6a-b29c-be43fe18fc5a')
def test_list_servers_filter_by_server_name(self):
# Filter the list of servers by server name
@@ -128,7 +125,6 @@ class ListServerFiltersTestJSON(base.BaseV2ComputeTest):
self.assertNotIn(self.s2_name, map(lambda x: x['name'], servers))
self.assertNotIn(self.s3_name, map(lambda x: x['name'], servers))
- @test.attr(type='gate')
@test.idempotent_id('ca78e20e-fddb-4ce6-b7f7-bcbf8605e66e')
def test_list_servers_filter_by_server_status(self):
# Filter the list of servers by server status
@@ -140,7 +136,6 @@ class ListServerFiltersTestJSON(base.BaseV2ComputeTest):
self.assertIn(self.s2['id'], map(lambda x: x['id'], servers))
self.assertIn(self.s3['id'], map(lambda x: x['id'], servers))
- @test.attr(type='gate')
@test.idempotent_id('451dbbb2-f330-4a9f-b0e1-5f5d2cb0f34c')
def test_list_servers_filter_by_shutoff_status(self):
# Filter the list of servers by server shutoff status
@@ -158,7 +153,6 @@ class ListServerFiltersTestJSON(base.BaseV2ComputeTest):
self.assertNotIn(self.s2['id'], map(lambda x: x['id'], servers))
self.assertNotIn(self.s3['id'], map(lambda x: x['id'], servers))
- @test.attr(type='gate')
@test.idempotent_id('614cdfc1-d557-4bac-915b-3e67b48eee76')
def test_list_servers_filter_by_limit(self):
# Verify only the expected number of servers are returned
@@ -166,7 +160,6 @@ class ListServerFiltersTestJSON(base.BaseV2ComputeTest):
servers = self.client.list_servers(params)
self.assertEqual(1, len([x for x in servers['servers'] if 'id' in x]))
- @test.attr(type='gate')
@test.idempotent_id('b1495414-2d93-414c-8019-849afe8d319e')
def test_list_servers_filter_by_zero_limit(self):
# Verify only the expected number of servers are returned
@@ -174,7 +167,6 @@ class ListServerFiltersTestJSON(base.BaseV2ComputeTest):
servers = self.client.list_servers(params)
self.assertEqual(0, len(servers['servers']))
- @test.attr(type='gate')
@test.idempotent_id('37791bbd-90c0-4de0-831e-5f38cba9c6b3')
def test_list_servers_filter_by_exceed_limit(self):
# Verify only the expected number of servers are returned
@@ -186,7 +178,6 @@ class ListServerFiltersTestJSON(base.BaseV2ComputeTest):
@test.idempotent_id('b3304c3b-97df-46d2-8cd3-e2b6659724e7')
@utils.skip_unless_attr('multiple_images', 'Only one image found')
- @test.attr(type='gate')
def test_list_servers_detailed_filter_by_image(self):
# Filter the detailed list of servers by image
params = {'image': self.image_ref}
@@ -197,7 +188,6 @@ class ListServerFiltersTestJSON(base.BaseV2ComputeTest):
self.assertNotIn(self.s2['id'], map(lambda x: x['id'], servers))
self.assertIn(self.s3['id'], map(lambda x: x['id'], servers))
- @test.attr(type='gate')
@test.idempotent_id('80c574cc-0925-44ba-8602-299028357dd9')
def test_list_servers_detailed_filter_by_flavor(self):
# Filter the detailed list of servers by flavor
@@ -209,7 +199,6 @@ class ListServerFiltersTestJSON(base.BaseV2ComputeTest):
self.assertNotIn(self.s2['id'], map(lambda x: x['id'], servers))
self.assertIn(self.s3['id'], map(lambda x: x['id'], servers))
- @test.attr(type='gate')
@test.idempotent_id('f9eb2b70-735f-416c-b260-9914ac6181e4')
def test_list_servers_detailed_filter_by_server_name(self):
# Filter the detailed list of servers by server name
@@ -221,7 +210,6 @@ class ListServerFiltersTestJSON(base.BaseV2ComputeTest):
self.assertNotIn(self.s2_name, map(lambda x: x['name'], servers))
self.assertNotIn(self.s3_name, map(lambda x: x['name'], servers))
- @test.attr(type='gate')
@test.idempotent_id('de2612ab-b7dd-4044-b0b1-d2539601911f')
def test_list_servers_detailed_filter_by_server_status(self):
# Filter the detailed list of servers by server status
@@ -236,7 +224,6 @@ class ListServerFiltersTestJSON(base.BaseV2ComputeTest):
self.assertEqual(['ACTIVE'] * 3, [x['status'] for x in servers
if x['id'] in test_ids])
- @test.attr(type='gate')
@test.idempotent_id('e9f624ee-92af-4562-8bec-437945a18dcb')
def test_list_servers_filtered_by_name_wildcard(self):
# List all servers that contains '-instance' in name
@@ -259,7 +246,6 @@ class ListServerFiltersTestJSON(base.BaseV2ComputeTest):
self.assertNotIn(self.s2_name, map(lambda x: x['name'], servers))
self.assertNotIn(self.s3_name, map(lambda x: x['name'], servers))
- @test.attr(type='gate')
@test.idempotent_id('24a89b0c-0d55-4a28-847f-45075f19b27b')
def test_list_servers_filtered_by_name_regex(self):
# list of regex that should match s1, s2 and s3
@@ -284,7 +270,6 @@ class ListServerFiltersTestJSON(base.BaseV2ComputeTest):
self.assertNotIn(self.s2_name, map(lambda x: x['name'], servers))
self.assertNotIn(self.s3_name, map(lambda x: x['name'], servers))
- @test.attr(type='gate')
@test.idempotent_id('43a1242e-7b31-48d1-88f2-3f72aa9f2077')
def test_list_servers_filtered_by_ip(self):
# Filter servers by ip
@@ -304,7 +289,6 @@ class ListServerFiltersTestJSON(base.BaseV2ComputeTest):
@decorators.skip_because(bug="1182883",
condition=CONF.service_available.neutron)
- @test.attr(type='gate')
@test.idempotent_id('a905e287-c35e-42f2-b132-d02b09f3654a')
def test_list_servers_filtered_by_ip_regex(self):
# Filter servers by regex ip
@@ -323,7 +307,6 @@ class ListServerFiltersTestJSON(base.BaseV2ComputeTest):
self.assertIn(self.s2_name, map(lambda x: x['name'], servers))
self.assertIn(self.s3_name, map(lambda x: x['name'], servers))
- @test.attr(type='gate')
@test.idempotent_id('67aec2d0-35fe-4503-9f92-f13272b867ed')
def test_list_servers_detailed_limit_results(self):
# Verify only the expected number of detailed results are returned
diff --git a/tempest/api/compute/servers/test_list_servers_negative.py b/tempest/api/compute/servers/test_list_servers_negative.py
index 1c466c580..0178c9e57 100644
--- a/tempest/api/compute/servers/test_list_servers_negative.py
+++ b/tempest/api/compute/servers/test_list_servers_negative.py
@@ -52,7 +52,7 @@ class ListServersNegativeTestJSON(base.BaseV2ComputeTest):
ignore_error=True)
cls.deleted_fixtures.append(srv)
- @test.attr(type=['negative', 'gate'])
+ @test.attr(type=['negative'])
@test.idempotent_id('24a26f1a-1ddc-4eea-b0d7-a90cc874ad8f')
def test_list_servers_with_a_deleted_server(self):
# Verify deleted servers do not show by default in list servers
@@ -64,7 +64,7 @@ class ListServersNegativeTestJSON(base.BaseV2ComputeTest):
if srv['id'] in deleted_ids]
self.assertEqual([], actual)
- @test.attr(type=['negative', 'gate'])
+ @test.attr(type=['negative'])
@test.idempotent_id('ff01387d-c7ad-47b4-ae9e-64fa214638fe')
def test_list_servers_by_non_existing_image(self):
# Listing servers for a non existing image returns empty list
@@ -73,7 +73,7 @@ class ListServersNegativeTestJSON(base.BaseV2ComputeTest):
servers = body['servers']
self.assertEqual([], servers)
- @test.attr(type=['negative', 'gate'])
+ @test.attr(type=['negative'])
@test.idempotent_id('5913660b-223b-44d4-a651-a0fbfd44ca75')
def test_list_servers_by_non_existing_flavor(self):
# Listing servers by non existing flavor returns empty list
@@ -82,7 +82,7 @@ class ListServersNegativeTestJSON(base.BaseV2ComputeTest):
servers = body['servers']
self.assertEqual([], servers)
- @test.attr(type=['negative', 'gate'])
+ @test.attr(type=['negative'])
@test.idempotent_id('e2c77c4a-000a-4af3-a0bd-629a328bde7c')
def test_list_servers_by_non_existing_server_name(self):
# Listing servers for a non existent server name returns empty list
@@ -91,7 +91,7 @@ class ListServersNegativeTestJSON(base.BaseV2ComputeTest):
servers = body['servers']
self.assertEqual([], servers)
- @test.attr(type=['negative', 'gate'])
+ @test.attr(type=['negative'])
@test.idempotent_id('fcdf192d-0f74-4d89-911f-1ec002b822c4')
def test_list_servers_status_non_existing(self):
# Return an empty list when invalid status is specified
@@ -100,42 +100,41 @@ class ListServersNegativeTestJSON(base.BaseV2ComputeTest):
servers = body['servers']
self.assertEqual([], servers)
- @test.attr(type='gate')
@test.idempotent_id('12c80a9f-2dec-480e-882b-98ba15757659')
def test_list_servers_by_limits(self):
# List servers by specifying limits
body = self.client.list_servers({'limit': 1})
self.assertEqual(1, len([x for x in body['servers'] if 'id' in x]))
- @test.attr(type=['negative', 'gate'])
+ @test.attr(type=['negative'])
@test.idempotent_id('d47c17fb-eebd-4287-8e95-f20a7e627b18')
def test_list_servers_by_limits_greater_than_actual_count(self):
# List servers by specifying a greater value for limit
body = self.client.list_servers({'limit': 100})
self.assertEqual(len(self.existing_fixtures), len(body['servers']))
- @test.attr(type=['negative', 'gate'])
+ @test.attr(type=['negative'])
@test.idempotent_id('679bc053-5e70-4514-9800-3dfab1a380a6')
def test_list_servers_by_limits_pass_string(self):
# Return an error if a string value is passed for limit
self.assertRaises(lib_exc.BadRequest, self.client.list_servers,
{'limit': 'testing'})
- @test.attr(type=['negative', 'gate'])
+ @test.attr(type=['negative'])
@test.idempotent_id('62610dd9-4713-4ee0-8beb-fd2c1aa7f950')
def test_list_servers_by_limits_pass_negative_value(self):
# Return an error if a negative value for limit is passed
self.assertRaises(lib_exc.BadRequest, self.client.list_servers,
{'limit': -1})
- @test.attr(type=['negative', 'gate'])
+ @test.attr(type=['negative'])
@test.idempotent_id('87d12517-e20a-4c9c-97b6-dd1628d6d6c9')
def test_list_servers_by_changes_since_invalid_date(self):
# Return an error when invalid date format is passed
self.assertRaises(lib_exc.BadRequest, self.client.list_servers,
{'changes-since': '2011/01/01'})
- @test.attr(type=['negative', 'gate'])
+ @test.attr(type=['negative'])
@test.idempotent_id('74745ad8-b346-45b5-b9b8-509d7447fc1f')
def test_list_servers_by_changes_since_future_date(self):
# Return an empty list when a date in the future is passed
@@ -143,7 +142,7 @@ class ListServersNegativeTestJSON(base.BaseV2ComputeTest):
body = self.client.list_servers(changes_since)
self.assertEqual(0, len(body['servers']))
- @test.attr(type=['negative', 'gate'])
+ @test.attr(type=['negative'])
@test.idempotent_id('93055106-2d34-46fe-af68-d9ddbf7ee570')
def test_list_servers_detail_server_is_deleted(self):
# Server details are not listed for a deleted server
diff --git a/tempest/api/compute/servers/test_multiple_create.py b/tempest/api/compute/servers/test_multiple_create.py
index 3be2b7936..eed3be8c0 100644
--- a/tempest/api/compute/servers/test_multiple_create.py
+++ b/tempest/api/compute/servers/test_multiple_create.py
@@ -35,7 +35,6 @@ class MultipleCreateTestJSON(base.BaseV2ComputeTest):
return body
- @test.attr(type='gate')
@test.idempotent_id('61e03386-89c3-449c-9bb1-a06f423fd9d1')
def test_multiple_create(self):
body = self._create_multiple_servers(wait_until='ACTIVE',
@@ -46,7 +45,6 @@ class MultipleCreateTestJSON(base.BaseV2ComputeTest):
# contains return_reservation_id=False
self.assertNotIn('reservation_id', body)
- @test.attr(type='gate')
@test.idempotent_id('864777fb-2f1e-44e3-b5b9-3eb6fa84f2f7')
def test_multiple_create_with_reservation_return(self):
body = self._create_multiple_servers(wait_until='ACTIVE',
diff --git a/tempest/api/compute/servers/test_multiple_create_negative.py b/tempest/api/compute/servers/test_multiple_create_negative.py
index ef47ad70c..bfc98ff7d 100644
--- a/tempest/api/compute/servers/test_multiple_create_negative.py
+++ b/tempest/api/compute/servers/test_multiple_create_negative.py
@@ -36,35 +36,35 @@ class MultipleCreateNegativeTestJSON(base.BaseV2ComputeTest):
return body
- @test.attr(type=['negative', 'gate'])
+ @test.attr(type=['negative'])
@test.idempotent_id('daf29d8d-e928-4a01-9a8c-b129603f3fc0')
def test_min_count_less_than_one(self):
invalid_min_count = 0
self.assertRaises(lib_exc.BadRequest, self._create_multiple_servers,
min_count=invalid_min_count)
- @test.attr(type=['negative', 'gate'])
+ @test.attr(type=['negative'])
@test.idempotent_id('999aa722-d624-4423-b813-0d1ac9884d7a')
def test_min_count_non_integer(self):
invalid_min_count = 2.5
self.assertRaises(lib_exc.BadRequest, self._create_multiple_servers,
min_count=invalid_min_count)
- @test.attr(type=['negative', 'gate'])
+ @test.attr(type=['negative'])
@test.idempotent_id('a6f9c2ab-e060-4b82-b23c-4532cb9390ff')
def test_max_count_less_than_one(self):
invalid_max_count = 0
self.assertRaises(lib_exc.BadRequest, self._create_multiple_servers,
max_count=invalid_max_count)
- @test.attr(type=['negative', 'gate'])
+ @test.attr(type=['negative'])
@test.idempotent_id('9c5698d1-d7af-4c80-b971-9d403135eea2')
def test_max_count_non_integer(self):
invalid_max_count = 2.5
self.assertRaises(lib_exc.BadRequest, self._create_multiple_servers,
max_count=invalid_max_count)
- @test.attr(type=['negative', 'gate'])
+ @test.attr(type=['negative'])
@test.idempotent_id('476da616-f1ef-4271-a9b1-b9fc87727cdf')
def test_max_count_less_than_min_count(self):
min_count = 3
diff --git a/tempest/api/compute/servers/test_server_actions.py b/tempest/api/compute/servers/test_server_actions.py
index 2ed4fc815..def4c47cf 100644
--- a/tempest/api/compute/servers/test_server_actions.py
+++ b/tempest/api/compute/servers/test_server_actions.py
@@ -66,7 +66,6 @@ class ServerActionsTestJSON(base.BaseV2ComputeTest):
@test.idempotent_id('6158df09-4b82-4ab3-af6d-29cf36af858d')
@testtools.skipUnless(CONF.compute_feature_enabled.change_password,
'Change password not available.')
- @test.attr(type='gate')
def test_change_server_password(self):
# The server's password should be set to the provided password
new_password = 'Newpass1234'
@@ -150,7 +149,6 @@ class ServerActionsTestJSON(base.BaseV2ComputeTest):
if self.image_ref_alt != self.image_ref:
self.client.rebuild(self.server_id, self.image_ref)
- @test.attr(type='gate')
@test.idempotent_id('30449a88-5aff-4f9b-9866-6ee9b17f906d')
def test_rebuild_server_in_stop_state(self):
# The server in stop state should be rebuilt using the provided
@@ -232,7 +230,6 @@ class ServerActionsTestJSON(base.BaseV2ComputeTest):
@test.idempotent_id('c03aab19-adb1-44f5-917d-c419577e9e68')
@testtools.skipUnless(CONF.compute_feature_enabled.resize,
'Resize not available.')
- @test.attr(type='gate')
def test_resize_server_revert(self):
# The server's RAM and disk space should return to its original
# values after a resize is reverted
@@ -252,7 +249,6 @@ class ServerActionsTestJSON(base.BaseV2ComputeTest):
@test.idempotent_id('b963d4f1-94b3-4c40-9e97-7b583f46e470')
@testtools.skipUnless(CONF.compute_feature_enabled.snapshot,
'Snapshotting not available, backup not possible.')
- @test.attr(type='gate')
@test.services('image')
def test_create_backup(self):
# Positive test:create backup successfully and rotate backups correctly
@@ -342,7 +338,6 @@ class ServerActionsTestJSON(base.BaseV2ComputeTest):
@test.idempotent_id('4b8867e6-fffa-4d54-b1d1-6fdda57be2f3')
@testtools.skipUnless(CONF.compute_feature_enabled.console_output,
'Console output not supported.')
- @test.attr(type='gate')
def test_get_console_output(self):
# Positive test:Should be able to GET the console output
# for a given server_id and number of lines
@@ -360,7 +355,6 @@ class ServerActionsTestJSON(base.BaseV2ComputeTest):
@test.idempotent_id('89104062-69d8-4b19-a71b-f47b7af093d7')
@testtools.skipUnless(CONF.compute_feature_enabled.console_output,
'Console output not supported.')
- @test.attr(type='gate')
def test_get_console_output_with_unlimited_size(self):
server = self.create_test_server(wait_until='ACTIVE')
@@ -380,7 +374,6 @@ class ServerActionsTestJSON(base.BaseV2ComputeTest):
@test.idempotent_id('5b65d4e7-4ecd-437c-83c0-d6b79d927568')
@testtools.skipUnless(CONF.compute_feature_enabled.console_output,
'Console output not supported.')
- @test.attr(type='gate')
def test_get_console_output_server_id_in_shutoff_status(self):
# Positive test:Should be able to GET the console output
# for a given server_id in SHUTOFF status
@@ -399,7 +392,6 @@ class ServerActionsTestJSON(base.BaseV2ComputeTest):
@test.idempotent_id('bd61a9fd-062f-4670-972b-2d6c3e3b9e73')
@testtools.skipUnless(CONF.compute_feature_enabled.pause,
'Pause is not available.')
- @test.attr(type='gate')
def test_pause_unpause_server(self):
self.client.pause_server(self.server_id)
self.client.wait_for_server_status(self.server_id, 'PAUSED')
@@ -409,7 +401,6 @@ class ServerActionsTestJSON(base.BaseV2ComputeTest):
@test.idempotent_id('0d8ee21e-b749-462d-83da-b85b41c86c7f')
@testtools.skipUnless(CONF.compute_feature_enabled.suspend,
'Suspend is not available.')
- @test.attr(type='gate')
def test_suspend_resume_server(self):
self.client.suspend_server(self.server_id)
self.client.wait_for_server_status(self.server_id, 'SUSPENDED')
@@ -419,7 +410,6 @@ class ServerActionsTestJSON(base.BaseV2ComputeTest):
@test.idempotent_id('77eba8e0-036e-4635-944b-f7a8f3b78dc9')
@testtools.skipUnless(CONF.compute_feature_enabled.shelve,
'Shelve is not available.')
- @test.attr(type='gate')
def test_shelve_unshelve_server(self):
self.client.shelve_server(self.server_id)
@@ -446,7 +436,6 @@ class ServerActionsTestJSON(base.BaseV2ComputeTest):
self.client.unshelve_server(self.server_id)
self.client.wait_for_server_status(self.server_id, 'ACTIVE')
- @test.attr(type='gate')
@test.idempotent_id('af8eafd4-38a7-4a4b-bdbc-75145a580560')
def test_stop_start_server(self):
self.servers_client.stop(self.server_id)
@@ -454,7 +443,6 @@ class ServerActionsTestJSON(base.BaseV2ComputeTest):
self.servers_client.start(self.server_id)
self.servers_client.wait_for_server_status(self.server_id, 'ACTIVE')
- @test.attr(type='gate')
@test.idempotent_id('80a8094c-211e-440a-ab88-9e59d556c7ee')
def test_lock_unlock_server(self):
# Lock the server,try server stop(exceptions throw),unlock it and retry
@@ -480,7 +468,6 @@ class ServerActionsTestJSON(base.BaseV2ComputeTest):
@test.idempotent_id('c6bc11bf-592e-4015-9319-1c98dc64daf5')
@testtools.skipUnless(CONF.compute_feature_enabled.vnc_console,
'VNC Console feature is disabled.')
- @test.attr(type='gate')
def test_get_vnc_console(self):
# Get the VNC console of type 'novnc' and 'xvpvnc'
console_types = ['novnc', 'xvpvnc']
diff --git a/tempest/api/compute/servers/test_server_addresses_negative.py b/tempest/api/compute/servers/test_server_addresses_negative.py
index dac5637bd..3503dc2a3 100644
--- a/tempest/api/compute/servers/test_server_addresses_negative.py
+++ b/tempest/api/compute/servers/test_server_addresses_negative.py
@@ -36,7 +36,7 @@ class ServerAddressesNegativeTestJSON(base.BaseV2ComputeTest):
super(ServerAddressesNegativeTestJSON, cls).resource_setup()
cls.server = cls.create_test_server(wait_until='ACTIVE')
- @test.attr(type=['negative', 'gate'])
+ @test.attr(type=['negative'])
@test.idempotent_id('02c3f645-2d2e-4417-8525-68c0407d001b')
@test.services('network')
def test_list_server_addresses_invalid_server_id(self):
@@ -44,7 +44,7 @@ class ServerAddressesNegativeTestJSON(base.BaseV2ComputeTest):
self.assertRaises(lib_exc.NotFound, self.client.list_addresses,
'999')
- @test.attr(type=['negative', 'gate'])
+ @test.attr(type=['negative'])
@test.idempotent_id('a2ab5144-78c0-4942-a0ed-cc8edccfd9ba')
@test.services('network')
def test_list_server_addresses_by_network_neg(self):
diff --git a/tempest/api/compute/servers/test_server_group.py b/tempest/api/compute/servers/test_server_group.py
index 12edfa5ec..ca808dd12 100644
--- a/tempest/api/compute/servers/test_server_group.py
+++ b/tempest/api/compute/servers/test_server_group.py
@@ -70,13 +70,11 @@ class ServerGroupTestJSON(base.BaseV2ComputeTest):
server_group = self._create_server_group(name, policy)
self._delete_server_group(server_group)
- @test.attr(type='gate')
@test.idempotent_id('5dc57eda-35b7-4af7-9e5f-3c2be3d2d68b')
def test_create_delete_server_group_with_affinity_policy(self):
# Create and Delete the server-group with affinity policy
self._create_delete_server_group(self.policy)
- @test.attr(type='gate')
@test.idempotent_id('3645a102-372f-4140-afad-13698d850d23')
def test_create_delete_server_group_with_anti_affinity_policy(self):
# Create and Delete the server-group with anti-affinity policy
@@ -84,14 +82,12 @@ class ServerGroupTestJSON(base.BaseV2ComputeTest):
self._create_delete_server_group(policy)
@decorators.skip_because(bug="1324348")
- @test.attr(type='gate')
@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.attr(type='gate')
@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
@@ -107,7 +103,6 @@ class ServerGroupTestJSON(base.BaseV2ComputeTest):
for i in range(0, 2):
self._delete_server_group(server_groups[i])
- @test.attr(type='gate')
@test.idempotent_id('b3545034-dd78-48f0-bdc2-a4adfa6d0ead')
def test_get_server_group(self):
# Get the server-group
@@ -115,7 +110,6 @@ class ServerGroupTestJSON(base.BaseV2ComputeTest):
self.created_server_group['id'])
self.assertEqual(self.created_server_group, body)
- @test.attr(type='gate')
@test.idempotent_id('d4874179-27b4-4d7d-80e4-6c560cdfe321')
def test_list_server_groups(self):
# List the server-group
diff --git a/tempest/api/compute/servers/test_server_metadata.py b/tempest/api/compute/servers/test_server_metadata.py
index 3bdd38017..234633b02 100644
--- a/tempest/api/compute/servers/test_server_metadata.py
+++ b/tempest/api/compute/servers/test_server_metadata.py
@@ -36,7 +36,6 @@ class ServerMetadataTestJSON(base.BaseV2ComputeTest):
meta = {'key1': 'value1', 'key2': 'value2'}
self.client.set_server_metadata(self.server_id, meta)
- @test.attr(type='gate')
@test.idempotent_id('479da087-92b3-4dcf-aeb3-fd293b2d14ce')
def test_list_server_metadata(self):
# All metadata key/value pairs for a server should be returned
@@ -46,7 +45,6 @@ class ServerMetadataTestJSON(base.BaseV2ComputeTest):
expected = {'key1': 'value1', 'key2': 'value2'}
self.assertEqual(expected, resp_metadata)
- @test.attr(type='gate')
@test.idempotent_id('211021f6-21de-4657-a68f-908878cfe251')
def test_set_server_metadata(self):
# The server's metadata should be replaced with the provided values
@@ -59,7 +57,6 @@ class ServerMetadataTestJSON(base.BaseV2ComputeTest):
resp_metadata = self.client.list_server_metadata(self.server_id)
self.assertEqual(resp_metadata, req_metadata)
- @test.attr(type='gate')
@test.idempotent_id('344d981e-0c33-4997-8a5d-6c1d803e4134')
def test_update_server_metadata(self):
# The server's metadata values should be updated to the
@@ -72,7 +69,6 @@ class ServerMetadataTestJSON(base.BaseV2ComputeTest):
expected = {'key1': 'alt1', 'key2': 'value2', 'key3': 'value3'}
self.assertEqual(expected, resp_metadata)
- @test.attr(type='gate')
@test.idempotent_id('0f58d402-e34a-481d-8af8-b392b17426d9')
def test_update_metadata_empty_body(self):
# The original metadata should not be lost if empty metadata body is
@@ -83,14 +79,12 @@ class ServerMetadataTestJSON(base.BaseV2ComputeTest):
expected = {'key1': 'value1', 'key2': 'value2'}
self.assertEqual(expected, resp_metadata)
- @test.attr(type='gate')
@test.idempotent_id('3043c57d-7e0e-49a6-9a96-ad569c265e6a')
def test_get_server_metadata_item(self):
# The value for a specific metadata key should be returned
meta = self.client.get_server_metadata_item(self.server_id, 'key2')
self.assertEqual('value2', meta['key2'])
- @test.attr(type='gate')
@test.idempotent_id('58c02d4f-5c67-40be-8744-d3fa5982eb1c')
def test_set_server_metadata_item(self):
# The item's value should be updated to the provided value
@@ -103,7 +97,6 @@ class ServerMetadataTestJSON(base.BaseV2ComputeTest):
expected = {'key1': 'value1', 'key2': 'value2', 'nova': 'alt'}
self.assertEqual(expected, resp_metadata)
- @test.attr(type='gate')
@test.idempotent_id('127642d6-4c7b-4486-b7cd-07265a378658')
def test_delete_server_metadata_item(self):
# The metadata value/key pair should be deleted from the server
diff --git a/tempest/api/compute/servers/test_server_metadata_negative.py b/tempest/api/compute/servers/test_server_metadata_negative.py
index 5e1765d04..1a977abe0 100644
--- a/tempest/api/compute/servers/test_server_metadata_negative.py
+++ b/tempest/api/compute/servers/test_server_metadata_negative.py
@@ -36,7 +36,7 @@ class ServerMetadataNegativeTestJSON(base.BaseV2ComputeTest):
cls.server_id = server['id']
- @test.attr(type=['gate', 'negative'])
+ @test.attr(type=['negative'])
@test.idempotent_id('fe114a8f-3a57-4eff-9ee2-4e14628df049')
def test_server_create_metadata_key_too_long(self):
# Attempt to start a server with a meta-data key that is > 255
@@ -52,7 +52,7 @@ class ServerMetadataNegativeTestJSON(base.BaseV2ComputeTest):
# no teardown - all creates should fail
- @test.attr(type=['negative', 'gate'])
+ @test.attr(type=['negative'])
@test.idempotent_id('92431555-4d8b-467c-b95b-b17daa5e57ff')
def test_create_server_metadata_blank_key(self):
# Blank key should trigger an error.
@@ -61,7 +61,7 @@ class ServerMetadataNegativeTestJSON(base.BaseV2ComputeTest):
self.create_test_server,
meta=meta)
- @test.attr(type=['negative', 'gate'])
+ @test.attr(type=['negative'])
@test.idempotent_id('4d9cd7a3-2010-4b41-b8fe-3bbf0b169466')
def test_server_metadata_non_existent_server(self):
# GET on a non-existent server should not succeed
@@ -71,7 +71,7 @@ class ServerMetadataNegativeTestJSON(base.BaseV2ComputeTest):
non_existent_server_id,
'test2')
- @test.attr(type=['negative', 'gate'])
+ @test.attr(type=['negative'])
@test.idempotent_id('f408e78e-3066-4097-9299-3b0182da812e')
def test_list_server_metadata_non_existent_server(self):
# List metadata on a non-existent server should not succeed
@@ -80,7 +80,7 @@ class ServerMetadataNegativeTestJSON(base.BaseV2ComputeTest):
self.client.list_server_metadata,
non_existent_server_id)
- @test.attr(type=['negative', 'gate'])
+ @test.attr(type=['negative'])
@test.idempotent_id('0025fbd6-a4ba-4cde-b8c2-96805dcfdabc')
def test_wrong_key_passed_in_body(self):
# Raise BadRequest if key in uri does not match
@@ -90,7 +90,7 @@ class ServerMetadataNegativeTestJSON(base.BaseV2ComputeTest):
self.client.set_server_metadata_item,
self.server_id, 'key', meta)
- @test.attr(type=['negative', 'gate'])
+ @test.attr(type=['negative'])
@test.idempotent_id('0df38c2a-3d4e-4db5-98d8-d4d9fa843a12')
def test_set_metadata_non_existent_server(self):
# Set metadata on a non-existent server should not succeed
@@ -101,7 +101,7 @@ class ServerMetadataNegativeTestJSON(base.BaseV2ComputeTest):
non_existent_server_id,
meta)
- @test.attr(type=['negative', 'gate'])
+ @test.attr(type=['negative'])
@test.idempotent_id('904b13dc-0ef2-4e4c-91cd-3b4a0f2f49d8')
def test_update_metadata_non_existent_server(self):
# An update should not happen for a non-existent server
@@ -112,7 +112,7 @@ class ServerMetadataNegativeTestJSON(base.BaseV2ComputeTest):
non_existent_server_id,
meta)
- @test.attr(type=['negative', 'gate'])
+ @test.attr(type=['negative'])
@test.idempotent_id('a452f38c-05c2-4b47-bd44-a4f0bf5a5e48')
def test_update_metadata_with_blank_key(self):
# Blank key should trigger an error
@@ -121,7 +121,7 @@ class ServerMetadataNegativeTestJSON(base.BaseV2ComputeTest):
self.client.update_server_metadata,
self.server_id, meta=meta)
- @test.attr(type=['negative', 'gate'])
+ @test.attr(type=['negative'])
@test.idempotent_id('6bbd88e1-f8b3-424d-ba10-ae21c45ada8d')
def test_delete_metadata_non_existent_server(self):
# Should not be able to delete metadata item from a non-existent server
@@ -131,7 +131,7 @@ class ServerMetadataNegativeTestJSON(base.BaseV2ComputeTest):
non_existent_server_id,
'd')
- @test.attr(type=['negative', 'gate'])
+ @test.attr(type=['negative'])
@test.idempotent_id('d8c0a210-a5c3-4664-be04-69d96746b547')
def test_metadata_items_limit(self):
# A 403 Forbidden or 413 Overlimit (old behaviour) exception
@@ -156,7 +156,7 @@ class ServerMetadataNegativeTestJSON(base.BaseV2ComputeTest):
self.client.update_server_metadata,
self.server_id, req_metadata)
- @test.attr(type=['negative', 'gate'])
+ @test.attr(type=['negative'])
@test.idempotent_id('96100343-7fa9-40d8-80fa-d29ef588ce1c')
def test_set_server_metadata_blank_key(self):
# Raise a bad request error for blank key.
@@ -166,7 +166,7 @@ class ServerMetadataNegativeTestJSON(base.BaseV2ComputeTest):
self.client.set_server_metadata,
self.server_id, meta=meta)
- @test.attr(type=['negative', 'gate'])
+ @test.attr(type=['negative'])
@test.idempotent_id('64a91aee-9723-4863-be44-4c9d9f1e7d0e')
def test_set_server_metadata_missing_metadata(self):
# Raise a bad request error for a missing metadata field
diff --git a/tempest/api/compute/servers/test_server_password.py b/tempest/api/compute/servers/test_server_password.py
index a82fddfd3..35c2cfde5 100644
--- a/tempest/api/compute/servers/test_server_password.py
+++ b/tempest/api/compute/servers/test_server_password.py
@@ -30,12 +30,10 @@ class ServerPasswordTestJSON(base.BaseV2ComputeTest):
super(ServerPasswordTestJSON, cls).resource_setup()
cls.server = cls.create_test_server(wait_until="ACTIVE")
- @test.attr(type='gate')
@test.idempotent_id('f83b582f-62a8-4f22-85b0-0dee50ff783a')
def test_get_server_password(self):
self.client.get_password(self.server['id'])
- @test.attr(type='gate')
@test.idempotent_id('f8229e8b-b625-4493-800a-bde86ac611ea')
def test_delete_server_password(self):
self.client.delete_password(self.server['id'])
diff --git a/tempest/api/compute/servers/test_server_personality.py b/tempest/api/compute/servers/test_server_personality.py
index dbfee8ff7..3a019b4d7 100644
--- a/tempest/api/compute/servers/test_server_personality.py
+++ b/tempest/api/compute/servers/test_server_personality.py
@@ -28,7 +28,6 @@ class ServerPersonalityTestJSON(base.BaseV2ComputeTest):
cls.client = cls.servers_client
cls.user_client = cls.limits_client
- @test.attr(type='gate')
@test.idempotent_id('176cd8c9-b9e8-48ee-a480-180beab292bf')
def test_personality_files_exceed_limit(self):
# Server creation should fail if greater than the maximum allowed
@@ -48,7 +47,6 @@ class ServerPersonalityTestJSON(base.BaseV2ComputeTest):
self.assertRaises((lib_exc.Forbidden, lib_exc.OverLimit),
self.create_test_server, personality=personality)
- @test.attr(type='gate')
@test.idempotent_id('52f12ee8-5180-40cc-b417-31572ea3d555')
def test_can_create_server_with_max_number_personality_files(self):
# Server should be created successfully if maximum allowed number of
diff --git a/tempest/api/compute/servers/test_server_rescue.py b/tempest/api/compute/servers/test_server_rescue.py
index 31d4cb325..4b1e8f01e 100644
--- a/tempest/api/compute/servers/test_server_rescue.py
+++ b/tempest/api/compute/servers/test_server_rescue.py
@@ -86,7 +86,6 @@ class ServerRescueTestJSON(base.BaseV2ComputeTest):
self.servers_client.unrescue_server(self.server_id)
self.servers_client.wait_for_server_status(self.server_id, 'ACTIVE')
- @test.attr(type='gate')
@test.idempotent_id('4842e0cf-e87d-4d9d-b61f-f4791da3cacc')
def test_rescued_vm_associate_dissociate_floating_ip(self):
# Rescue the server
@@ -104,7 +103,6 @@ class ServerRescueTestJSON(base.BaseV2ComputeTest):
client.disassociate_floating_ip_from_server(self.floating_ip,
self.server_id)
- @test.attr(type='gate')
@test.idempotent_id('affca41f-7195-492d-8065-e09eee245404')
def test_rescued_vm_add_remove_security_group(self):
# Rescue the server
diff --git a/tempest/api/compute/servers/test_server_rescue_negative.py b/tempest/api/compute/servers/test_server_rescue_negative.py
index 12b7c0a85..779800556 100644
--- a/tempest/api/compute/servers/test_server_rescue_negative.py
+++ b/tempest/api/compute/servers/test_server_rescue_negative.py
@@ -81,7 +81,7 @@ class ServerRescueNegativeTestJSON(base.BaseV2ComputeTest):
@test.idempotent_id('cc3a883f-43c0-4fb6-a9bb-5579d64984ed')
@testtools.skipUnless(CONF.compute_feature_enabled.pause,
'Pause is not available.')
- @test.attr(type=['negative', 'gate'])
+ @test.attr(type=['negative'])
def test_rescue_paused_instance(self):
# Rescue a paused server
self.servers_client.pause_server(self.server_id)
@@ -91,13 +91,13 @@ class ServerRescueNegativeTestJSON(base.BaseV2ComputeTest):
self.servers_client.rescue_server,
self.server_id)
- @test.attr(type=['negative', 'gate'])
+ @test.attr(type=['negative'])
@test.idempotent_id('db22b618-f157-4566-a317-1b6d467a8094')
def test_rescued_vm_reboot(self):
self.assertRaises(lib_exc.Conflict, self.servers_client.reboot,
self.rescue_id, 'HARD')
- @test.attr(type=['negative', 'gate'])
+ @test.attr(type=['negative'])
@test.idempotent_id('6dfc0a55-3a77-4564-a144-1587b7971dde')
def test_rescue_non_existent_server(self):
# Rescue a non-existing server
@@ -106,7 +106,7 @@ class ServerRescueNegativeTestJSON(base.BaseV2ComputeTest):
self.servers_client.rescue_server,
non_existent_server)
- @test.attr(type=['negative', 'gate'])
+ @test.attr(type=['negative'])
@test.idempotent_id('70cdb8a1-89f8-437d-9448-8844fd82bf46')
def test_rescued_vm_rebuild(self):
self.assertRaises(lib_exc.Conflict,
@@ -116,7 +116,7 @@ class ServerRescueNegativeTestJSON(base.BaseV2ComputeTest):
@test.idempotent_id('d0ccac79-0091-4cf4-a1ce-26162d0cc55f')
@test.services('volume')
- @test.attr(type=['negative', 'gate'])
+ @test.attr(type=['negative'])
def test_rescued_vm_attach_volume(self):
volume = self._create_volume()
@@ -135,7 +135,7 @@ class ServerRescueNegativeTestJSON(base.BaseV2ComputeTest):
@test.idempotent_id('f56e465b-fe10-48bf-b75d-646cda3a8bc9')
@test.services('volume')
- @test.attr(type=['negative', 'gate'])
+ @test.attr(type=['negative'])
def test_rescued_vm_detach_volume(self):
volume = self._create_volume()
diff --git a/tempest/api/compute/servers/test_servers.py b/tempest/api/compute/servers/test_servers.py
index 73ac9bede..b33312239 100644
--- a/tempest/api/compute/servers/test_servers.py
+++ b/tempest/api/compute/servers/test_servers.py
@@ -30,7 +30,6 @@ class ServersTestJSON(base.BaseV2ComputeTest):
self.clear_servers()
super(ServersTestJSON, self).tearDown()
- @test.attr(type='gate')
@test.idempotent_id('b92d5ec7-b1dd-44a2-87e4-45e888c46ef0')
def test_create_server_with_admin_password(self):
# If an admin password is provided on server creation, the server's
@@ -40,7 +39,6 @@ class ServersTestJSON(base.BaseV2ComputeTest):
# Verify the password is set correctly in the response
self.assertEqual('testpassword', server['adminPass'])
- @test.attr(type='gate')
@test.idempotent_id('8fea6be7-065e-47cf-89b8-496e6f96c699')
def test_create_with_existing_server_name(self):
# Creating a server with a name that already exists is allowed
@@ -60,7 +58,6 @@ class ServersTestJSON(base.BaseV2ComputeTest):
name2 = server['name']
self.assertEqual(name1, name2)
- @test.attr(type='gate')
@test.idempotent_id('f9e15296-d7f9-4e62-b53f-a04e89160833')
def test_create_specify_keypair(self):
# Specify a keypair while creating a server
@@ -86,7 +83,6 @@ class ServersTestJSON(base.BaseV2ComputeTest):
self.assertEqual(new_name, server['name'])
return server
- @test.attr(type='gate')
@test.idempotent_id('5e6ccff8-349d-4852-a8b3-055df7988dd2')
def test_update_server_name(self):
# The server name should be changed to the the provided value
@@ -94,7 +90,6 @@ class ServersTestJSON(base.BaseV2ComputeTest):
self._update_server_name(server['id'], 'ACTIVE')
- @test.attr(type='gate')
@test.idempotent_id('6ac19cb1-27a3-40ec-b350-810bdc04c08e')
def test_update_server_name_in_stop_state(self):
# The server name should be changed to the the provided value
@@ -104,7 +99,6 @@ class ServersTestJSON(base.BaseV2ComputeTest):
updated_server = self._update_server_name(server['id'], 'SHUTOFF')
self.assertNotIn('progress', updated_server)
- @test.attr(type='gate')
@test.idempotent_id('89b90870-bc13-4b73-96af-f9d4f2b70077')
def test_update_access_server_address(self):
# The server's access addresses should reflect the provided values
@@ -121,7 +115,6 @@ class ServersTestJSON(base.BaseV2ComputeTest):
self.assertEqual('1.1.1.1', server['accessIPv4'])
self.assertEqual('::babe:202:202', server['accessIPv6'])
- @test.attr(type='gate')
@test.idempotent_id('38fb1d02-c3c5-41de-91d3-9bc2025a75eb')
def test_create_server_with_ipv6_addr_only(self):
# Create a server without an IPv4 address(only IPv6 address).
diff --git a/tempest/api/compute/servers/test_servers_negative.py b/tempest/api/compute/servers/test_servers_negative.py
index 853e2621a..82ef7f547 100644
--- a/tempest/api/compute/servers/test_servers_negative.py
+++ b/tempest/api/compute/servers/test_servers_negative.py
@@ -20,7 +20,6 @@ from tempest_lib import exceptions as lib_exc
import testtools
from tempest.api.compute import base
-from tempest import clients
from tempest import config
from tempest import test
@@ -29,6 +28,8 @@ CONF = config.CONF
class ServersNegativeTestJSON(base.BaseV2ComputeTest):
+ credentials = ['primary', 'alt']
+
def setUp(self):
super(ServersNegativeTestJSON, self).setUp()
try:
@@ -41,15 +42,10 @@ class ServersNegativeTestJSON(base.BaseV2ComputeTest):
super(ServersNegativeTestJSON, self).tearDown()
@classmethod
- def setup_credentials(cls):
- super(ServersNegativeTestJSON, cls).setup_credentials()
- cls.alt_os = clients.Manager(cls.isolated_creds.get_alt_creds())
-
- @classmethod
def setup_clients(cls):
super(ServersNegativeTestJSON, cls).setup_clients()
cls.client = cls.servers_client
- cls.alt_client = cls.alt_os.servers_client
+ cls.alt_client = cls.os_alt.servers_client
@classmethod
def resource_setup(cls):
@@ -57,7 +53,7 @@ class ServersNegativeTestJSON(base.BaseV2ComputeTest):
server = cls.create_test_server(wait_until='ACTIVE')
cls.server_id = server['id']
- @test.attr(type=['negative', 'gate'])
+ @test.attr(type=['negative'])
@test.idempotent_id('dbbfd247-c40c-449e-8f6c-d2aa7c7da7cf')
def test_server_name_blank(self):
# Create a server with name parameter empty
@@ -66,7 +62,7 @@ class ServersNegativeTestJSON(base.BaseV2ComputeTest):
self.create_test_server,
name='')
- @test.attr(type=['negative', 'gate'])
+ @test.attr(type=['negative'])
@test.idempotent_id('b8a7235e-5246-4a8f-a08e-b34877c6586f')
def test_personality_file_contents_not_encoded(self):
# Use an unencoded file when creating a server with personality
@@ -79,7 +75,7 @@ class ServersNegativeTestJSON(base.BaseV2ComputeTest):
self.create_test_server,
personality=person)
- @test.attr(type=['negative', 'gate'])
+ @test.attr(type=['negative'])
@test.idempotent_id('fcba1052-0a50-4cf3-b1ac-fae241edf02f')
def test_create_with_invalid_image(self):
# Create a server with an unknown image
@@ -88,7 +84,7 @@ class ServersNegativeTestJSON(base.BaseV2ComputeTest):
self.create_test_server,
image_id=-1)
- @test.attr(type=['negative', 'gate'])
+ @test.attr(type=['negative'])
@test.idempotent_id('18f5227f-d155-4429-807c-ccb103887537')
def test_create_with_invalid_flavor(self):
# Create a server with an unknown flavor
@@ -97,7 +93,7 @@ class ServersNegativeTestJSON(base.BaseV2ComputeTest):
self.create_test_server,
flavor=-1,)
- @test.attr(type=['negative', 'gate'])
+ @test.attr(type=['negative'])
@test.idempotent_id('7f70a4d1-608f-4794-9e56-cb182765972c')
def test_invalid_access_ip_v4_address(self):
# An access IPv4 address must match a valid address pattern
@@ -106,7 +102,7 @@ class ServersNegativeTestJSON(base.BaseV2ComputeTest):
self.assertRaises(lib_exc.BadRequest,
self.create_test_server, accessIPv4=IPv4)
- @test.attr(type=['negative', 'gate'])
+ @test.attr(type=['negative'])
@test.idempotent_id('5226dd80-1e9c-4d8a-b5f9-b26ca4763fd0')
def test_invalid_ip_v6_address(self):
# An access IPv6 address must match a valid address pattern
@@ -119,7 +115,7 @@ class ServersNegativeTestJSON(base.BaseV2ComputeTest):
@test.idempotent_id('7ea45b3e-e770-46fa-bfcc-9daaf6d987c0')
@testtools.skipUnless(CONF.compute_feature_enabled.resize,
'Resize not available.')
- @test.attr(type=['negative', 'gate'])
+ @test.attr(type=['negative'])
def test_resize_nonexistent_server(self):
# Resize a non-existent server
nonexistent_server = data_utils.rand_uuid()
@@ -130,7 +126,7 @@ class ServersNegativeTestJSON(base.BaseV2ComputeTest):
@test.idempotent_id('ced1a1d7-2ab6-45c9-b90f-b27d87b30efd')
@testtools.skipUnless(CONF.compute_feature_enabled.resize,
'Resize not available.')
- @test.attr(type=['negative', 'gate'])
+ @test.attr(type=['negative'])
def test_resize_server_with_non_existent_flavor(self):
# Resize a server with non-existent flavor
nonexistent_flavor = data_utils.rand_uuid()
@@ -140,13 +136,13 @@ class ServersNegativeTestJSON(base.BaseV2ComputeTest):
@test.idempotent_id('45436a7d-a388-4a35-a9d8-3adc5d0d940b')
@testtools.skipUnless(CONF.compute_feature_enabled.resize,
'Resize not available.')
- @test.attr(type=['negative', 'gate'])
+ @test.attr(type=['negative'])
def test_resize_server_with_null_flavor(self):
# Resize a server with null flavor
self.assertRaises(lib_exc.BadRequest, self.client.resize,
self.server_id, flavor_ref="")
- @test.attr(type=['negative', 'gate'])
+ @test.attr(type=['negative'])
@test.idempotent_id('d4c023a0-9c55-4747-9dd5-413b820143c7')
def test_reboot_non_existent_server(self):
# Reboot a non existent server
@@ -157,7 +153,7 @@ class ServersNegativeTestJSON(base.BaseV2ComputeTest):
@test.idempotent_id('d1417e7f-a509-41b5-a102-d5eed8613369')
@testtools.skipUnless(CONF.compute_feature_enabled.pause,
'Pause is not available.')
- @test.attr(type=['negative', 'gate'])
+ @test.attr(type=['negative'])
def test_pause_paused_server(self):
# Pause a paused server.
self.client.pause_server(self.server_id)
@@ -167,7 +163,7 @@ class ServersNegativeTestJSON(base.BaseV2ComputeTest):
self.server_id)
self.client.unpause_server(self.server_id)
- @test.attr(type=['negative', 'gate'])
+ @test.attr(type=['negative'])
@test.idempotent_id('98fa0458-1485-440f-873b-fe7f0d714930')
def test_rebuild_reboot_deleted_server(self):
# Rebuild and Reboot a deleted server
@@ -181,7 +177,7 @@ class ServersNegativeTestJSON(base.BaseV2ComputeTest):
self.assertRaises(lib_exc.NotFound, self.client.reboot,
server['id'], 'SOFT')
- @test.attr(type=['negative', 'gate'])
+ @test.attr(type=['negative'])
@test.idempotent_id('d86141a7-906e-4731-b187-d64a2ea61422')
def test_rebuild_non_existent_server(self):
# Rebuild a non existent server
@@ -191,7 +187,7 @@ class ServersNegativeTestJSON(base.BaseV2ComputeTest):
nonexistent_server,
self.image_ref_alt)
- @test.attr(type=['negative', 'gate'])
+ @test.attr(type=['negative'])
@test.idempotent_id('fd57f159-68d6-4c2a-902b-03070828a87e')
def test_create_numeric_server_name(self):
server_name = 12345
@@ -199,7 +195,7 @@ class ServersNegativeTestJSON(base.BaseV2ComputeTest):
self.create_test_server,
name=server_name)
- @test.attr(type=['negative', 'gate'])
+ @test.attr(type=['negative'])
@test.idempotent_id('c3e0fb12-07fc-4d76-a22e-37409887afe8')
def test_create_server_name_length_exceeds_256(self):
# Create a server with name length exceeding 256 characters
@@ -209,7 +205,7 @@ class ServersNegativeTestJSON(base.BaseV2ComputeTest):
self.create_test_server,
name=server_name)
- @test.attr(type=['negative', 'gate'])
+ @test.attr(type=['negative'])
@test.idempotent_id('4e72dc2d-44c5-4336-9667-f7972e95c402')
def test_create_with_invalid_network_uuid(self):
# Pass invalid network uuid while creating a server
@@ -220,7 +216,7 @@ class ServersNegativeTestJSON(base.BaseV2ComputeTest):
self.create_test_server,
networks=networks)
- @test.attr(type=['negative', 'gate'])
+ @test.attr(type=['negative'])
@test.idempotent_id('7a2efc39-530c-47de-b875-2dd01c8d39bd')
def test_create_with_non_existent_keypair(self):
# Pass a non-existent keypair while creating a server
@@ -230,7 +226,7 @@ class ServersNegativeTestJSON(base.BaseV2ComputeTest):
self.create_test_server,
key_name=key_name)
- @test.attr(type=['negative', 'gate'])
+ @test.attr(type=['negative'])
@test.idempotent_id('7fc74810-0bd2-4cd7-8244-4f33a9db865a')
def test_create_server_metadata_exceeds_length_limit(self):
# Pass really long metadata while creating a server
@@ -240,7 +236,7 @@ class ServersNegativeTestJSON(base.BaseV2ComputeTest):
self.create_test_server,
meta=metadata)
- @test.attr(type=['negative', 'gate'])
+ @test.attr(type=['negative'])
@test.idempotent_id('aa8eed43-e2cb-4ebf-930b-da14f6a21d81')
def test_update_name_of_non_existent_server(self):
# Update name of a non-existent server
@@ -251,7 +247,7 @@ class ServersNegativeTestJSON(base.BaseV2ComputeTest):
self.assertRaises(lib_exc.NotFound, self.client.update_server,
server_name, name=new_name)
- @test.attr(type=['negative', 'gate'])
+ @test.attr(type=['negative'])
@test.idempotent_id('38204696-17c6-44da-9590-40f87fb5a899')
def test_update_server_set_empty_name(self):
# Update name of the server to an empty string
@@ -262,7 +258,7 @@ class ServersNegativeTestJSON(base.BaseV2ComputeTest):
self.assertRaises(lib_exc.BadRequest, self.client.update_server,
server_name, name=new_name)
- @test.attr(type=['negative', 'gate'])
+ @test.attr(type=['negative'])
@test.idempotent_id('543d84c1-dd2e-4c6d-8cb2-b9da0efaa384')
def test_update_server_of_another_tenant(self):
# Update name of a server that belongs to another tenant
@@ -272,7 +268,7 @@ class ServersNegativeTestJSON(base.BaseV2ComputeTest):
self.alt_client.update_server, self.server_id,
name=new_name)
- @test.attr(type=['negative', 'gate'])
+ @test.attr(type=['negative'])
@test.idempotent_id('5c8e244c-dada-4590-9944-749c455b431f')
def test_update_server_name_length_exceeds_256(self):
# Update name of server exceed the name length limit
@@ -283,7 +279,7 @@ class ServersNegativeTestJSON(base.BaseV2ComputeTest):
self.server_id,
name=new_name)
- @test.attr(type=['negative', 'gate'])
+ @test.attr(type=['negative'])
@test.idempotent_id('1041b4e6-514b-4855-96a5-e974b60870a3')
def test_delete_non_existent_server(self):
# Delete a non existent server
@@ -292,7 +288,7 @@ class ServersNegativeTestJSON(base.BaseV2ComputeTest):
self.assertRaises(lib_exc.NotFound, self.client.delete_server,
nonexistent_server)
- @test.attr(type=['negative', 'gate'])
+ @test.attr(type=['negative'])
@test.idempotent_id('5c75009d-3eea-423e-bea3-61b09fd25f9c')
def test_delete_a_server_of_another_tenant(self):
# Delete a server that belongs to another tenant
@@ -300,14 +296,14 @@ class ServersNegativeTestJSON(base.BaseV2ComputeTest):
self.alt_client.delete_server,
self.server_id)
- @test.attr(type=['negative', 'gate'])
+ @test.attr(type=['negative'])
@test.idempotent_id('75f79124-277c-45e6-a373-a1d6803f4cc4')
def test_delete_server_pass_negative_id(self):
# Pass an invalid string parameter to delete server
self.assertRaises(lib_exc.NotFound, self.client.delete_server, -1)
- @test.attr(type=['negative', 'gate'])
+ @test.attr(type=['negative'])
@test.idempotent_id('f4d7279b-5fd2-4bf2-9ba4-ae35df0d18c5')
def test_delete_server_pass_id_exceeding_length_limit(self):
# Pass a server ID that exceeds length limit to delete server
@@ -315,7 +311,7 @@ class ServersNegativeTestJSON(base.BaseV2ComputeTest):
self.assertRaises(lib_exc.NotFound, self.client.delete_server,
sys.maxint + 1)
- @test.attr(type=['negative', 'gate'])
+ @test.attr(type=['negative'])
@test.idempotent_id('c5fa6041-80cd-483b-aa6d-4e45f19d093c')
def test_create_with_nonexistent_security_group(self):
# Create a server with a nonexistent security group
@@ -325,7 +321,7 @@ class ServersNegativeTestJSON(base.BaseV2ComputeTest):
self.create_test_server,
security_groups=security_groups)
- @test.attr(type=['negative', 'gate'])
+ @test.attr(type=['negative'])
@test.idempotent_id('3436b02f-1b1e-4f03-881e-c6a602327439')
def test_get_non_existent_server(self):
# Get a non existent server details
@@ -333,7 +329,7 @@ class ServersNegativeTestJSON(base.BaseV2ComputeTest):
self.assertRaises(lib_exc.NotFound, self.client.get_server,
nonexistent_server)
- @test.attr(type=['negative', 'gate'])
+ @test.attr(type=['negative'])
@test.idempotent_id('a31460a9-49e1-42aa-82ee-06e0bb7c2d03')
def test_stop_non_existent_server(self):
# Stop a non existent server
@@ -344,7 +340,7 @@ class ServersNegativeTestJSON(base.BaseV2ComputeTest):
@test.idempotent_id('6a8dc0c6-6cd4-4c0a-9f32-413881828091')
@testtools.skipUnless(CONF.compute_feature_enabled.pause,
'Pause is not available.')
- @test.attr(type=['negative', 'gate'])
+ @test.attr(type=['negative'])
def test_pause_non_existent_server(self):
# pause a non existent server
nonexistent_server = data_utils.rand_uuid()
@@ -354,7 +350,7 @@ class ServersNegativeTestJSON(base.BaseV2ComputeTest):
@test.idempotent_id('705b8e3a-e8a7-477c-a19b-6868fc24ac75')
@testtools.skipUnless(CONF.compute_feature_enabled.pause,
'Pause is not available.')
- @test.attr(type=['negative', 'gate'])
+ @test.attr(type=['negative'])
def test_unpause_non_existent_server(self):
# unpause a non existent server
nonexistent_server = data_utils.rand_uuid()
@@ -364,7 +360,7 @@ class ServersNegativeTestJSON(base.BaseV2ComputeTest):
@test.idempotent_id('c8e639a7-ece8-42dd-a2e0-49615917ba4f')
@testtools.skipUnless(CONF.compute_feature_enabled.pause,
'Pause is not available.')
- @test.attr(type=['negative', 'gate'])
+ @test.attr(type=['negative'])
def test_unpause_server_invalid_state(self):
# unpause an active server.
self.assertRaises(lib_exc.Conflict,
@@ -374,7 +370,7 @@ class ServersNegativeTestJSON(base.BaseV2ComputeTest):
@test.idempotent_id('d1f032d5-7b6e-48aa-b252-d5f16dd994ca')
@testtools.skipUnless(CONF.compute_feature_enabled.suspend,
'Suspend is not available.')
- @test.attr(type=['negative', 'gate'])
+ @test.attr(type=['negative'])
def test_suspend_non_existent_server(self):
# suspend a non existent server
nonexistent_server = data_utils.rand_uuid()
@@ -384,7 +380,7 @@ class ServersNegativeTestJSON(base.BaseV2ComputeTest):
@test.idempotent_id('7f323206-05a9-4bf8-996b-dd5b2036501b')
@testtools.skipUnless(CONF.compute_feature_enabled.suspend,
'Suspend is not available.')
- @test.attr(type=['negative', 'gate'])
+ @test.attr(type=['negative'])
def test_suspend_server_invalid_state(self):
# suspend a suspended server.
self.client.suspend_server(self.server_id)
@@ -397,7 +393,7 @@ class ServersNegativeTestJSON(base.BaseV2ComputeTest):
@test.idempotent_id('221cd282-bddb-4837-a683-89c2487389b6')
@testtools.skipUnless(CONF.compute_feature_enabled.suspend,
'Suspend is not available.')
- @test.attr(type=['negative', 'gate'])
+ @test.attr(type=['negative'])
def test_resume_non_existent_server(self):
# resume a non existent server
nonexistent_server = data_utils.rand_uuid()
@@ -407,14 +403,14 @@ class ServersNegativeTestJSON(base.BaseV2ComputeTest):
@test.idempotent_id('ccb6294d-c4c9-498f-8a43-554c098bfadb')
@testtools.skipUnless(CONF.compute_feature_enabled.suspend,
'Suspend is not available.')
- @test.attr(type=['negative', 'gate'])
+ @test.attr(type=['negative'])
def test_resume_server_invalid_state(self):
# resume an active server.
self.assertRaises(lib_exc.Conflict,
self.client.resume_server,
self.server_id)
- @test.attr(type=['negative', 'gate'])
+ @test.attr(type=['negative'])
@test.idempotent_id('7dd919e7-413f-4198-bebb-35e2a01b13e9')
def test_get_console_output_of_non_existent_server(self):
# get the console output for a non existent server
@@ -423,7 +419,7 @@ class ServersNegativeTestJSON(base.BaseV2ComputeTest):
self.client.get_console_output,
nonexistent_server, 10)
- @test.attr(type=['negative', 'gate'])
+ @test.attr(type=['negative'])
@test.idempotent_id('6f47992b-5144-4250-9f8b-f00aa33950f3')
def test_force_delete_nonexistent_server_id(self):
# force-delete a non existent server
@@ -432,7 +428,7 @@ class ServersNegativeTestJSON(base.BaseV2ComputeTest):
self.client.force_delete_server,
nonexistent_server)
- @test.attr(type=['negative', 'gate'])
+ @test.attr(type=['negative'])
@test.idempotent_id('9c6d38cc-fcfb-437a-85b9-7b788af8bf01')
def test_restore_nonexistent_server_id(self):
# restore-delete a non existent server
@@ -441,7 +437,7 @@ class ServersNegativeTestJSON(base.BaseV2ComputeTest):
self.client.restore_soft_deleted_server,
nonexistent_server)
- @test.attr(type=['negative', 'gate'])
+ @test.attr(type=['negative'])
@test.idempotent_id('7fcadfab-bd6a-4753-8db7-4a51e51aade9')
def test_restore_server_invalid_state(self):
# we can only restore-delete a server in 'soft-delete' state
@@ -452,7 +448,7 @@ class ServersNegativeTestJSON(base.BaseV2ComputeTest):
@test.idempotent_id('abca56e2-a892-48ea-b5e5-e07e69774816')
@testtools.skipUnless(CONF.compute_feature_enabled.shelve,
'Shelve is not available.')
- @test.attr(type=['negative', 'gate'])
+ @test.attr(type=['negative'])
def test_shelve_non_existent_server(self):
# shelve a non existent server
nonexistent_server = data_utils.rand_uuid()
@@ -462,7 +458,7 @@ class ServersNegativeTestJSON(base.BaseV2ComputeTest):
@test.idempotent_id('443e4f9b-e6bf-4389-b601-3a710f15fddd')
@testtools.skipUnless(CONF.compute_feature_enabled.shelve,
'Shelve is not available.')
- @test.attr(type=['negative', 'gate'])
+ @test.attr(type=['negative'])
def test_shelve_shelved_server(self):
# shelve a shelved server.
self.client.shelve_server(self.server_id)
@@ -492,7 +488,7 @@ class ServersNegativeTestJSON(base.BaseV2ComputeTest):
@test.idempotent_id('23d23b37-afaf-40d7-aa5d-5726f82d8821')
@testtools.skipUnless(CONF.compute_feature_enabled.shelve,
'Shelve is not available.')
- @test.attr(type=['negative', 'gate'])
+ @test.attr(type=['negative'])
def test_unshelve_non_existent_server(self):
# unshelve a non existent server
nonexistent_server = data_utils.rand_uuid()
@@ -502,7 +498,7 @@ class ServersNegativeTestJSON(base.BaseV2ComputeTest):
@test.idempotent_id('8f198ded-1cca-4228-9e65-c6b449c54880')
@testtools.skipUnless(CONF.compute_feature_enabled.shelve,
'Shelve is not available.')
- @test.attr(type=['negative', 'gate'])
+ @test.attr(type=['negative'])
def test_unshelve_server_invalid_state(self):
# unshelve an active server.
self.assertRaises(lib_exc.Conflict,
diff --git a/tempest/api/compute/servers/test_virtual_interfaces.py b/tempest/api/compute/servers/test_virtual_interfaces.py
index 0b2f4c62c..85f004165 100644
--- a/tempest/api/compute/servers/test_virtual_interfaces.py
+++ b/tempest/api/compute/servers/test_virtual_interfaces.py
@@ -44,7 +44,6 @@ class VirtualInterfacesTestJSON(base.BaseV2ComputeTest):
@decorators.skip_because(bug="1183436",
condition=CONF.service_available.neutron)
- @test.attr(type='gate')
@test.idempotent_id('96c4e2ef-5e4d-4d7f-87f5-fed6dca18016')
@test.services('network')
def test_list_virtual_interfaces(self):
diff --git a/tempest/api/compute/servers/test_virtual_interfaces_negative.py b/tempest/api/compute/servers/test_virtual_interfaces_negative.py
index e5cb74450..577a673a9 100644
--- a/tempest/api/compute/servers/test_virtual_interfaces_negative.py
+++ b/tempest/api/compute/servers/test_virtual_interfaces_negative.py
@@ -34,7 +34,7 @@ class VirtualInterfacesNegativeTestJSON(base.BaseV2ComputeTest):
super(VirtualInterfacesNegativeTestJSON, cls).setup_clients()
cls.client = cls.servers_client
- @test.attr(type=['negative', 'gate'])
+ @test.attr(type=['negative'])
@test.idempotent_id('64ebd03c-1089-4306-93fa-60f5eb5c803c')
@test.services('network')
def test_list_virtual_interfaces_invalid_server_id(self):
diff --git a/tempest/api/compute/test_authorization.py b/tempest/api/compute/test_authorization.py
index 2baf608d2..258ff1f7a 100644
--- a/tempest/api/compute/test_authorization.py
+++ b/tempest/api/compute/test_authorization.py
@@ -20,7 +20,6 @@ from tempest_lib.common.utils import data_utils
from tempest_lib import exceptions as lib_exc
from tempest.api.compute import base
-from tempest import clients
from tempest import config
from tempest import test
@@ -31,6 +30,8 @@ LOG = logging.getLogger(__name__)
class AuthorizationTestJSON(base.BaseV2ComputeTest):
+ credentials = ['primary', 'alt']
+
@classmethod
def skip_checks(cls):
super(AuthorizationTestJSON, cls).skip_checks()
@@ -42,12 +43,6 @@ class AuthorizationTestJSON(base.BaseV2ComputeTest):
# No network resources required for this test
cls.set_network_resources()
super(AuthorizationTestJSON, cls).setup_credentials()
- if not cls.multi_user:
- msg = "Need >1 user"
- raise cls.skipException(msg)
-
- creds = cls.isolated_creds.get_alt_creds()
- cls.alt_manager = clients.Manager(credentials=creds)
@classmethod
def setup_clients(cls):
@@ -103,35 +98,30 @@ class AuthorizationTestJSON(base.BaseV2ComputeTest):
cls.security_client.delete_security_group(cls.security_group['id'])
super(AuthorizationTestJSON, cls).resource_cleanup()
- @test.attr(type='gate')
@test.idempotent_id('56816e4a-bd34-47b5-aee9-268c3efeb5d4')
def test_get_server_for_alt_account_fails(self):
# A GET request for a server on another user's account should fail
self.assertRaises(lib_exc.NotFound, self.alt_client.get_server,
self.server['id'])
- @test.attr(type='gate')
@test.idempotent_id('fb8a4870-6d9d-44ad-8375-95d52e98d9f6')
def test_delete_server_for_alt_account_fails(self):
# A DELETE request for another user's server should fail
self.assertRaises(lib_exc.NotFound, self.alt_client.delete_server,
self.server['id'])
- @test.attr(type='gate')
@test.idempotent_id('d792f91f-1d49-4eb5-b1ff-b229c4b9dc64')
def test_update_server_for_alt_account_fails(self):
# An update server request for another user's server should fail
self.assertRaises(lib_exc.NotFound, self.alt_client.update_server,
self.server['id'], name='test')
- @test.attr(type='gate')
@test.idempotent_id('488f24df-d7f7-4207-949a-f17fcb8e8769')
def test_list_server_addresses_for_alt_account_fails(self):
# A list addresses request for another user's server should fail
self.assertRaises(lib_exc.NotFound, self.alt_client.list_addresses,
self.server['id'])
- @test.attr(type='gate')
@test.idempotent_id('00b442d0-2e72-40e7-9b1f-31772e36da01')
def test_list_server_addresses_by_network_for_alt_account_fails(self):
# A list address/network request for another user's server should fail
@@ -140,7 +130,6 @@ class AuthorizationTestJSON(base.BaseV2ComputeTest):
self.alt_client.list_addresses_by_network, server_id,
'public')
- @test.attr(type='gate')
@test.idempotent_id('cc90b35a-19f0-45d2-b680-2aabf934aa22')
def test_list_servers_with_alternate_tenant(self):
# A list on servers from one tenant should not
@@ -151,35 +140,30 @@ class AuthorizationTestJSON(base.BaseV2ComputeTest):
alt_server_ids = [s['id'] for s in body['servers']]
self.assertNotIn(self.server['id'], alt_server_ids)
- @test.attr(type='gate')
@test.idempotent_id('376dbc16-0779-4384-a723-752774799641')
def test_change_password_for_alt_account_fails(self):
# A change password request for another user's server should fail
self.assertRaises(lib_exc.NotFound, self.alt_client.change_password,
self.server['id'], 'newpass')
- @test.attr(type='gate')
@test.idempotent_id('14cb5ff5-f646-45ca-8f51-09081d6c0c24')
def test_reboot_server_for_alt_account_fails(self):
# A reboot request for another user's server should fail
self.assertRaises(lib_exc.NotFound, self.alt_client.reboot,
self.server['id'], 'HARD')
- @test.attr(type='gate')
@test.idempotent_id('8a0bce51-cd00-480b-88ba-dbc7d8408a37')
def test_rebuild_server_for_alt_account_fails(self):
# A rebuild request for another user's server should fail
self.assertRaises(lib_exc.NotFound, self.alt_client.rebuild,
self.server['id'], self.image_ref_alt)
- @test.attr(type='gate')
@test.idempotent_id('e4da647e-f982-4e61-9dad-1d1abebfb933')
def test_resize_server_for_alt_account_fails(self):
# A resize request for another user's server should fail
self.assertRaises(lib_exc.NotFound, self.alt_client.resize,
self.server['id'], self.flavor_ref_alt)
- @test.attr(type='gate')
@test.idempotent_id('a9fe8112-0ffa-4902-b061-f892bd5fe0d3')
def test_create_image_for_alt_account_fails(self):
# A create image request for another user's server should fail
@@ -187,14 +171,12 @@ class AuthorizationTestJSON(base.BaseV2ComputeTest):
self.alt_images_client.create_image,
self.server['id'], 'testImage')
- @test.attr(type='gate')
@test.idempotent_id('95d445f6-babc-4f2e-aea3-aa24ec5e7f0d')
def test_create_server_with_unauthorized_image(self):
# Server creation with another user's image should fail
self.assertRaises(lib_exc.BadRequest, self.alt_client.create_server,
'test', self.image['id'], self.flavor_ref)
- @test.attr(type='gate')
@test.idempotent_id('acf8724b-142b-4044-82c3-78d31a533f24')
def test_create_server_fails_when_tenant_incorrect(self):
# A create server request should fail if the tenant id does not match
@@ -208,7 +190,6 @@ class AuthorizationTestJSON(base.BaseV2ComputeTest):
self.alt_client.create_server, 'test',
self.image['id'], self.flavor_ref)
- @test.attr(type='gate')
@test.idempotent_id('f03d1ded-7fd4-4d29-bc13-e2391f29c625')
def test_create_keypair_in_analt_user_tenant(self):
# A create keypair request should fail if the tenant id does not match
@@ -232,7 +213,6 @@ class AuthorizationTestJSON(base.BaseV2ComputeTest):
LOG.error("Create keypair request should not happen "
"if the tenant id does not match the current user")
- @test.attr(type='gate')
@test.idempotent_id('85bcdd8f-56b4-4868-ae56-63fbf6f7e405')
def test_get_keypair_of_alt_account_fails(self):
# A GET request for another user's keypair should fail
@@ -240,7 +220,6 @@ class AuthorizationTestJSON(base.BaseV2ComputeTest):
self.alt_keypairs_client.get_keypair,
self.keypairname)
- @test.attr(type='gate')
@test.idempotent_id('6d841683-a8e0-43da-a1b8-b339f7692b61')
def test_delete_keypair_of_alt_account_fails(self):
# A DELETE request for another user's keypair should fail
@@ -248,14 +227,12 @@ class AuthorizationTestJSON(base.BaseV2ComputeTest):
self.alt_keypairs_client.delete_keypair,
self.keypairname)
- @test.attr(type='gate')
@test.idempotent_id('fcb2e144-36e3-4dfb-9f9f-e72fcdec5656')
def test_get_image_for_alt_account_fails(self):
# A GET request for an image on another user's account should fail
self.assertRaises(lib_exc.NotFound,
self.alt_images_client.get_image, self.image['id'])
- @test.attr(type='gate')
@test.idempotent_id('9facb962-f043-4a9d-b9ee-166a32dea098')
def test_delete_image_for_alt_account_fails(self):
# A DELETE request for another user's image should fail
@@ -263,7 +240,6 @@ class AuthorizationTestJSON(base.BaseV2ComputeTest):
self.alt_images_client.delete_image,
self.image['id'])
- @test.attr(type='gate')
@test.idempotent_id('752c917e-83be-499d-a422-3559127f7d3c')
def test_create_security_group_in_analt_user_tenant(self):
# A create security group request should fail if the tenant id does not
@@ -289,7 +265,6 @@ class AuthorizationTestJSON(base.BaseV2ComputeTest):
LOG.error("Create Security Group request should not happen if"
"the tenant id does not match the current user")
- @test.attr(type='gate')
@test.idempotent_id('9db3590f-4d15-4e5f-985e-b28514919a6f')
def test_get_security_group_of_alt_account_fails(self):
# A GET request for another user's security group should fail
@@ -297,7 +272,6 @@ class AuthorizationTestJSON(base.BaseV2ComputeTest):
self.alt_security_client.get_security_group,
self.security_group['id'])
- @test.attr(type='gate')
@test.idempotent_id('155387a5-2bbc-4acf-ab06-698dae537ea5')
def test_delete_security_group_of_alt_account_fails(self):
# A DELETE request for another user's security group should fail
@@ -305,7 +279,6 @@ class AuthorizationTestJSON(base.BaseV2ComputeTest):
self.alt_security_client.delete_security_group,
self.security_group['id'])
- @test.attr(type='gate')
@test.idempotent_id('b2b76de0-210a-4089-b921-591c9ec552f6')
def test_create_security_group_rule_in_analt_user_tenant(self):
# A create security group rule request should fail if the tenant id
@@ -336,7 +309,6 @@ class AuthorizationTestJSON(base.BaseV2ComputeTest):
"happen if the tenant id does not match the"
" current user")
- @test.attr(type='gate')
@test.idempotent_id('c6044177-37ef-4ce4-b12c-270ddf26d7da')
def test_delete_security_group_rule_of_alt_account_fails(self):
# A DELETE request for another user's security group rule
@@ -345,7 +317,6 @@ class AuthorizationTestJSON(base.BaseV2ComputeTest):
self.alt_security_client.delete_security_group_rule,
self.rule['id'])
- @test.attr(type='gate')
@test.idempotent_id('c5f52351-53d9-4fc9-83e5-917f7f5e3d71')
def test_set_metadata_of_alt_account_server_fails(self):
# A set metadata for another user's server should fail
@@ -355,7 +326,6 @@ class AuthorizationTestJSON(base.BaseV2ComputeTest):
self.server['id'],
req_metadata)
- @test.attr(type='gate')
@test.idempotent_id('fb6f51e9-df15-4939-898d-1aca38c258f0')
def test_set_metadata_of_alt_account_image_fails(self):
# A set metadata for another user's image should fail
@@ -364,7 +334,6 @@ class AuthorizationTestJSON(base.BaseV2ComputeTest):
self.alt_images_client.set_image_metadata,
self.image['id'], req_metadata)
- @test.attr(type='gate')
@test.idempotent_id('dea1936a-473d-49f2-92ad-97bb7aded22e')
def test_get_metadata_of_alt_account_server_fails(self):
# A get metadata for another user's server should fail
@@ -376,7 +345,6 @@ class AuthorizationTestJSON(base.BaseV2ComputeTest):
self.alt_client.get_server_metadata_item,
self.server['id'], 'meta1')
- @test.attr(type='gate')
@test.idempotent_id('16b2d724-0d3b-4216-a9fa-97bd4d9cf670')
def test_get_metadata_of_alt_account_image_fails(self):
# A get metadata for another user's image should fail
@@ -389,7 +357,6 @@ class AuthorizationTestJSON(base.BaseV2ComputeTest):
self.alt_images_client.get_image_metadata_item,
self.image['id'], 'meta1')
- @test.attr(type='gate')
@test.idempotent_id('79531e2e-e721-493c-8b30-a35db36fdaa6')
def test_delete_metadata_of_alt_account_server_fails(self):
# A delete metadata for another user's server should fail
@@ -401,7 +368,6 @@ class AuthorizationTestJSON(base.BaseV2ComputeTest):
self.alt_client.delete_server_metadata_item,
self.server['id'], 'meta1')
- @test.attr(type='gate')
@test.idempotent_id('a5175dcf-cef8-43d6-9b77-3cb707d62e94')
def test_delete_metadata_of_alt_account_image_fails(self):
# A delete metadata for another user's image should fail
@@ -414,7 +380,6 @@ class AuthorizationTestJSON(base.BaseV2ComputeTest):
self.alt_images_client.delete_image_metadata_item,
self.image['id'], 'meta1')
- @test.attr(type='gate')
@test.idempotent_id('b0c1e7a0-8853-40fd-8384-01f93d116cae')
def test_get_console_output_of_alt_account_server_fails(self):
# A Get Console Output for another user's server should fail
diff --git a/tempest/api/compute/test_extensions.py b/tempest/api/compute/test_extensions.py
index 5b1407195..4cc432899 100644
--- a/tempest/api/compute/test_extensions.py
+++ b/tempest/api/compute/test_extensions.py
@@ -27,7 +27,6 @@ LOG = logging.getLogger(__name__)
class ExtensionsTestJSON(base.BaseV2ComputeTest):
- @test.attr(type='gate')
@test.idempotent_id('3bb27738-b759-4e0d-a5fa-37d7a6df07d1')
def test_list_extensions(self):
# List of all extensions
@@ -47,8 +46,7 @@ class ExtensionsTestJSON(base.BaseV2ComputeTest):
@test.idempotent_id('05762f39-bdfa-4cdb-9b46-b78f8e78e2fd')
@test.requires_ext(extension='os-consoles', service='compute')
- @test.attr(type='gate')
def test_get_extension(self):
# get the specified extensions
- extension = self.extensions_client.get_extension('os-consoles')
+ extension = self.extensions_client.show_extension('os-consoles')
self.assertEqual('os-consoles', extension['alias'])
diff --git a/tempest/api/compute/test_live_block_migration_negative.py b/tempest/api/compute/test_live_block_migration_negative.py
index b59e3343b..5ee76ca89 100644
--- a/tempest/api/compute/test_live_block_migration_negative.py
+++ b/tempest/api/compute/test_live_block_migration_negative.py
@@ -45,7 +45,7 @@ class LiveBlockMigrationNegativeTestJSON(base.BaseV2ComputeAdminTest):
block_migration_for_live_migration)
return body
- @test.attr(type=['negative', 'gate'])
+ @test.attr(type=['negative'])
@test.idempotent_id('7fb7856e-ae92-44c9-861a-af62d7830bcb')
def test_invalid_host_for_migration(self):
# Migrating to an invalid host should not change the status
diff --git a/tempest/api/compute/test_networks.py b/tempest/api/compute/test_networks.py
index 227972375..deb9ee2d8 100644
--- a/tempest/api/compute/test_networks.py
+++ b/tempest/api/compute/test_networks.py
@@ -31,7 +31,6 @@ class NetworksTestJSON(base.BaseV2ComputeTest):
super(NetworksTestJSON, cls).setup_clients()
cls.client = cls.os.networks_client
- @test.attr(type='gate')
@test.idempotent_id('3fe07175-312e-49a5-a623-5f52eeada4c2')
def test_list_networks(self):
networks = self.client.list_networks()
diff --git a/tempest/api/compute/test_tenant_networks.py b/tempest/api/compute/test_tenant_networks.py
index 3a712ddcd..a37dce1b5 100644
--- a/tempest/api/compute/test_tenant_networks.py
+++ b/tempest/api/compute/test_tenant_networks.py
@@ -23,7 +23,6 @@ class NetworksTestJSON(base.BaseV2ComputeTest):
super(NetworksTestJSON, cls).resource_setup()
cls.client = cls.os.tenant_networks_client
- @test.attr(type='gate')
@test.idempotent_id('edfea98e-bbe3-4c7a-9739-87b986baff26')
def test_list_show_tenant_networks(self):
tenant_networks = self.client.list_tenant_networks()
diff --git a/tempest/api/compute/volumes/test_attach_volume.py b/tempest/api/compute/volumes/test_attach_volume.py
index 12d5b0ef7..7f345aed9 100644
--- a/tempest/api/compute/volumes/test_attach_volume.py
+++ b/tempest/api/compute/volumes/test_attach_volume.py
@@ -86,7 +86,6 @@ class AttachVolumeTestJSON(base.BaseV2ComputeTest):
@test.idempotent_id('52e9045a-e90d-4c0d-9087-79d657faffff')
@testtools.skipUnless(CONF.compute.run_ssh, 'SSH required for this test')
- @test.attr(type='gate')
def test_attach_detach_volume(self):
# Stop and Start a server with an attached volume, ensuring that
# the volume remains attached.
@@ -120,7 +119,6 @@ class AttachVolumeTestJSON(base.BaseV2ComputeTest):
partitions = linux_client.get_partitions()
self.assertNotIn(self.device, partitions)
- @test.attr(type='gate')
@test.idempotent_id('7fa563fe-f0f7-43eb-9e22-a1ece036b513')
def test_list_get_volume_attachments(self):
# Create Server, Volume and attach that Volume to Server
diff --git a/tempest/api/compute/volumes/test_volumes_list.py b/tempest/api/compute/volumes/test_volumes_list.py
index cfdf1fc3a..fdece0ca5 100644
--- a/tempest/api/compute/volumes/test_volumes_list.py
+++ b/tempest/api/compute/volumes/test_volumes_list.py
@@ -83,7 +83,6 @@ class VolumesTestJSON(base.BaseV2ComputeTest):
cls.delete_volume(volume['id'])
super(VolumesTestJSON, cls).resource_cleanup()
- @test.attr(type='gate')
@test.idempotent_id('bc2dd1a0-15af-48e5-9990-f2e75a48325d')
def test_volume_list(self):
# Should return the list of Volumes
@@ -99,7 +98,6 @@ class VolumesTestJSON(base.BaseV2ComputeTest):
', '.join(m_vol['displayName']
for m_vol in missing_volumes))
- @test.attr(type='gate')
@test.idempotent_id('bad0567a-5a4f-420b-851e-780b55bb867c')
def test_volume_list_with_details(self):
# Should return the list of Volumes with details
@@ -115,7 +113,6 @@ class VolumesTestJSON(base.BaseV2ComputeTest):
', '.join(m_vol['displayName']
for m_vol in missing_volumes))
- @test.attr(type='gate')
@test.idempotent_id('1048ed81-2baf-487a-b284-c0622b86e7b8')
def test_volume_list_param_limit(self):
# Return the list of volumes based on limit set
@@ -125,7 +122,6 @@ class VolumesTestJSON(base.BaseV2ComputeTest):
self.assertEqual(len(fetched_vol_list), params['limit'],
"Failed to list volumes by limit set")
- @test.attr(type='gate')
@test.idempotent_id('33985568-4965-49d5-9bcc-0aa007ca5b7a')
def test_volume_list_with_detail_param_limit(self):
# Return the list of volumes with details based on limit set.
@@ -135,7 +131,6 @@ class VolumesTestJSON(base.BaseV2ComputeTest):
self.assertEqual(len(fetched_vol_list), params['limit'],
"Failed to list volume details by limit set")
- @test.attr(type='gate')
@test.idempotent_id('51c22651-a074-4ea7-af0b-094f9331303e')
def test_volume_list_param_offset_and_limit(self):
# Return the list of volumes based on offset and limit set.
@@ -153,7 +148,6 @@ class VolumesTestJSON(base.BaseV2ComputeTest):
all_vol_list[index + params['offset']]['id'],
"Failed to list volumes by offset and limit")
- @test.attr(type='gate')
@test.idempotent_id('06b6abc4-3f10-48e9-a7a1-3facc98f03e5')
def test_volume_list_with_detail_param_offset_and_limit(self):
# Return the list of volumes details based on offset and limit set.
diff --git a/tempest/api/compute/volumes/test_volumes_negative.py b/tempest/api/compute/volumes/test_volumes_negative.py
index fb9f365e8..65d9def9c 100644
--- a/tempest/api/compute/volumes/test_volumes_negative.py
+++ b/tempest/api/compute/volumes/test_volumes_negative.py
@@ -39,7 +39,7 @@ class VolumesNegativeTest(base.BaseV2ComputeTest):
super(VolumesNegativeTest, cls).setup_clients()
cls.client = cls.volumes_extensions_client
- @test.attr(type=['negative', 'gate'])
+ @test.attr(type=['negative'])
@test.idempotent_id('c03ea686-905b-41a2-8748-9635154b7c57')
def test_volume_get_nonexistent_volume_id(self):
# Negative: Should not be able to get details of nonexistent volume
@@ -48,7 +48,7 @@ class VolumesNegativeTest(base.BaseV2ComputeTest):
self.assertRaises(lib_exc.NotFound, self.client.get_volume,
str(uuid.uuid4()))
- @test.attr(type=['negative', 'gate'])
+ @test.attr(type=['negative'])
@test.idempotent_id('54a34226-d910-4b00-9ef8-8683e6c55846')
def test_volume_delete_nonexistent_volume_id(self):
# Negative: Should not be able to delete nonexistent Volume
@@ -57,7 +57,7 @@ class VolumesNegativeTest(base.BaseV2ComputeTest):
self.assertRaises(lib_exc.NotFound, self.client.delete_volume,
str(uuid.uuid4()))
- @test.attr(type=['negative', 'gate'])
+ @test.attr(type=['negative'])
@test.idempotent_id('5125ae14-152b-40a7-b3c5-eae15e9022ef')
def test_create_volume_with_invalid_size(self):
# Negative: Should not be able to create volume with invalid size
@@ -67,7 +67,7 @@ class VolumesNegativeTest(base.BaseV2ComputeTest):
self.assertRaises(lib_exc.BadRequest, self.client.create_volume,
size='#$%', display_name=v_name, metadata=metadata)
- @test.attr(type=['negative', 'gate'])
+ @test.attr(type=['negative'])
@test.idempotent_id('131cb3a1-75cc-4d40-b4c3-1317f64719b0')
def test_create_volume_with_out_passing_size(self):
# Negative: Should not be able to create volume without passing size
@@ -77,7 +77,7 @@ class VolumesNegativeTest(base.BaseV2ComputeTest):
self.assertRaises(lib_exc.BadRequest, self.client.create_volume,
size='', display_name=v_name, metadata=metadata)
- @test.attr(type=['negative', 'gate'])
+ @test.attr(type=['negative'])
@test.idempotent_id('8cce995e-0a83-479a-b94d-e1e40b8a09d1')
def test_create_volume_with_size_zero(self):
# Negative: Should not be able to create volume with size zero
@@ -86,20 +86,20 @@ class VolumesNegativeTest(base.BaseV2ComputeTest):
self.assertRaises(lib_exc.BadRequest, self.client.create_volume,
size='0', display_name=v_name, metadata=metadata)
- @test.attr(type=['negative', 'gate'])
+ @test.attr(type=['negative'])
@test.idempotent_id('f01904f2-e975-4915-98ce-cb5fa27bde4f')
def test_get_invalid_volume_id(self):
# Negative: Should not be able to get volume with invalid id
self.assertRaises(lib_exc.NotFound,
self.client.get_volume, '#$%%&^&^')
- @test.attr(type=['negative', 'gate'])
+ @test.attr(type=['negative'])
@test.idempotent_id('62bab09a-4c03-4617-8cca-8572bc94af9b')
def test_get_volume_without_passing_volume_id(self):
# Negative: Should not be able to get volume when empty ID is passed
self.assertRaises(lib_exc.NotFound, self.client.get_volume, '')
- @test.attr(type=['negative', 'gate'])
+ @test.attr(type=['negative'])
@test.idempotent_id('62972737-124b-4513-b6cf-2f019f178494')
def test_delete_invalid_volume_id(self):
# Negative: Should not be able to delete volume when invalid ID is
@@ -107,7 +107,7 @@ class VolumesNegativeTest(base.BaseV2ComputeTest):
self.assertRaises(lib_exc.NotFound,
self.client.delete_volume, '!@#$%^&*()')
- @test.attr(type=['negative', 'gate'])
+ @test.attr(type=['negative'])
@test.idempotent_id('0d1417c5-4ae8-4c2c-adc5-5f0b864253e5')
def test_delete_volume_without_passing_volume_id(self):
# Negative: Should not be able to delete volume when empty ID is passed
diff --git a/tempest/api/data_processing/base.py b/tempest/api/data_processing/base.py
index d91fbaa40..904cbb6db 100644
--- a/tempest/api/data_processing/base.py
+++ b/tempest/api/data_processing/base.py
@@ -12,27 +12,227 @@
# License for the specific language governing permissions and limitations
# under the License.
+from collections import OrderedDict
+
+import six
from tempest_lib import exceptions as lib_exc
from tempest import config
+from tempest import exceptions
import tempest.test
CONF = config.CONF
+"""Default templates.
+There should always be at least a master1 and a worker1 node
+group template."""
+DEFAULT_TEMPLATES = {
+ 'vanilla': OrderedDict([
+ ('2.6.0', {
+ 'NODES': {
+ 'master1': {
+ 'count': 1,
+ 'node_processes': ['namenode', 'resourcemanager',
+ 'hiveserver']
+ },
+ 'master2': {
+ 'count': 1,
+ 'node_processes': ['oozie', 'historyserver',
+ 'secondarynamenode']
+ },
+ 'worker1': {
+ 'count': 1,
+ 'node_processes': ['datanode', 'nodemanager'],
+ 'node_configs': {
+ 'MapReduce': {
+ 'yarn.app.mapreduce.am.resource.mb': 256,
+ 'yarn.app.mapreduce.am.command-opts': '-Xmx256m'
+ },
+ 'YARN': {
+ 'yarn.scheduler.minimum-allocation-mb': 256,
+ 'yarn.scheduler.maximum-allocation-mb': 1024,
+ 'yarn.nodemanager.vmem-check-enabled': False
+ }
+ }
+ }
+ },
+ 'cluster_configs': {
+ 'HDFS': {
+ 'dfs.replication': 1
+ }
+ }
+ }),
+ ('1.2.1', {
+ 'NODES': {
+ 'master1': {
+ 'count': 1,
+ 'node_processes': ['namenode', 'jobtracker']
+ },
+ 'worker1': {
+ 'count': 1,
+ 'node_processes': ['datanode', 'tasktracker'],
+ 'node_configs': {
+ 'HDFS': {
+ 'Data Node Heap Size': 1024
+ },
+ 'MapReduce': {
+ 'Task Tracker Heap Size': 1024
+ }
+ }
+ }
+ },
+ 'cluster_configs': {
+ 'HDFS': {
+ 'dfs.replication': 1
+ },
+ 'MapReduce': {
+ 'mapred.map.tasks.speculative.execution': False,
+ 'mapred.child.java.opts': '-Xmx500m'
+ },
+ 'general': {
+ 'Enable Swift': False
+ }
+ }
+ })
+ ]),
+ 'hdp': OrderedDict([
+ ('2.0.6', {
+ 'NODES': {
+ 'master1': {
+ 'count': 1,
+ 'node_processes': ['NAMENODE', 'SECONDARY_NAMENODE',
+ 'ZOOKEEPER_SERVER', 'AMBARI_SERVER',
+ 'HISTORYSERVER', 'RESOURCEMANAGER',
+ 'GANGLIA_SERVER', 'NAGIOS_SERVER',
+ 'OOZIE_SERVER']
+ },
+ 'worker1': {
+ 'count': 1,
+ 'node_processes': ['HDFS_CLIENT', 'DATANODE',
+ 'YARN_CLIENT', 'ZOOKEEPER_CLIENT',
+ 'MAPREDUCE2_CLIENT', 'NODEMANAGER',
+ 'PIG', 'OOZIE_CLIENT']
+ }
+ },
+ 'cluster_configs': {
+ 'HDFS': {
+ 'dfs.replication': 1
+ }
+ }
+ })
+ ]),
+ 'spark': OrderedDict([
+ ('1.0.0', {
+ 'NODES': {
+ 'master1': {
+ 'count': 1,
+ 'node_processes': ['namenode', 'master']
+ },
+ 'worker1': {
+ 'count': 1,
+ 'node_processes': ['datanode', 'slave']
+ }
+ },
+ 'cluster_configs': {
+ 'HDFS': {
+ 'dfs.replication': 1
+ }
+ }
+ })
+ ]),
+ 'cdh': OrderedDict([
+ ('5.3.0', {
+ 'NODES': {
+ 'master1': {
+ 'count': 1,
+ 'node_processes': ['CLOUDERA_MANAGER']
+ },
+ 'master2': {
+ 'count': 1,
+ 'node_processes': ['HDFS_NAMENODE',
+ 'YARN_RESOURCEMANAGER']
+ },
+ 'master3': {
+ 'count': 1,
+ 'node_processes': ['OOZIE_SERVER', 'YARN_JOBHISTORY',
+ 'HDFS_SECONDARYNAMENODE',
+ 'HIVE_METASTORE', 'HIVE_SERVER2']
+ },
+ 'worker1': {
+ 'count': 1,
+ 'node_processes': ['YARN_NODEMANAGER', 'HDFS_DATANODE']
+ }
+ },
+ 'cluster_configs': {
+ 'HDFS': {
+ 'dfs_replication': 1
+ }
+ }
+ }),
+ ('5', {
+ 'NODES': {
+ 'master1': {
+ 'count': 1,
+ 'node_processes': ['CLOUDERA_MANAGER']
+ },
+ 'master2': {
+ 'count': 1,
+ 'node_processes': ['HDFS_NAMENODE',
+ 'YARN_RESOURCEMANAGER']
+ },
+ 'master3': {
+ 'count': 1,
+ 'node_processes': ['OOZIE_SERVER', 'YARN_JOBHISTORY',
+ 'HDFS_SECONDARYNAMENODE',
+ 'HIVE_METASTORE', 'HIVE_SERVER2']
+ },
+ 'worker1': {
+ 'count': 1,
+ 'node_processes': ['YARN_NODEMANAGER', 'HDFS_DATANODE']
+ }
+ },
+ 'cluster_configs': {
+ 'HDFS': {
+ 'dfs_replication': 1
+ }
+ }
+ })
+ ]),
+ 'mapr': OrderedDict([
+ ('4.0.1.mrv2', {
+ 'NODES': {
+ 'master1': {
+ 'count': 1,
+ 'node_processes': ['CLDB', 'FileServer', 'ZooKeeper',
+ 'NodeManager', 'ResourceManager',
+ 'HistoryServer', 'Oozie']
+ },
+ 'worker1': {
+ 'count': 1,
+ 'node_processes': ['FileServer', 'NodeManager', 'Pig']
+ }
+ },
+ 'cluster_configs': {
+ 'Hive': {
+ 'Hive Version': '0.13',
+ }
+ }
+ })
+ ]),
+}
+
class BaseDataProcessingTest(tempest.test.BaseTestCase):
+ credentials = ['primary']
+
@classmethod
def skip_checks(cls):
super(BaseDataProcessingTest, cls).skip_checks()
if not CONF.service_available.sahara:
raise cls.skipException('Sahara support is required')
-
- @classmethod
- def setup_credentials(cls):
- super(BaseDataProcessingTest, cls).setup_credentials()
- cls.os = cls.get_client_manager()
+ cls.default_plugin = cls._get_default_plugin()
@classmethod
def setup_clients(cls):
@@ -43,6 +243,10 @@ class BaseDataProcessingTest(tempest.test.BaseTestCase):
def resource_setup(cls):
super(BaseDataProcessingTest, cls).resource_setup()
+ cls.default_version = cls._get_default_version()
+ if cls.default_plugin is not None and cls.default_version is None:
+ raise exceptions.InvalidConfiguration(
+ message="No known Sahara plugin version was found")
cls.flavor_ref = CONF.compute.flavor_ref
# add lists for watched resources
@@ -172,3 +376,100 @@ class BaseDataProcessingTest(tempest.test.BaseTestCase):
cls._jobs.append(resp_body['id'])
return resp_body
+
+ @classmethod
+ def _get_default_plugin(cls):
+ """Returns the default plugin used for testing."""
+ if len(CONF.data_processing_feature_enabled.plugins) == 0:
+ return None
+
+ for plugin in CONF.data_processing_feature_enabled.plugins:
+ if plugin in DEFAULT_TEMPLATES.keys():
+ break
+ else:
+ plugin = ''
+ return plugin
+
+ @classmethod
+ def _get_default_version(cls):
+ """Returns the default plugin version used for testing.
+ This is gathered separately from the plugin to allow
+ the usage of plugin name in skip_checks. This method is
+ rather invoked into resource_setup, which allows API calls
+ and exceptions.
+ """
+ if not cls.default_plugin:
+ return None
+ plugin = cls.client.get_plugin(cls.default_plugin)
+
+ for version in DEFAULT_TEMPLATES[cls.default_plugin].keys():
+ if version in plugin['versions']:
+ break
+ else:
+ version = None
+
+ return version
+
+ @classmethod
+ def get_node_group_template(cls, nodegroup='worker1'):
+ """Returns a node group template for the default plugin."""
+ try:
+ plugin_data = (
+ DEFAULT_TEMPLATES[cls.default_plugin][cls.default_version]
+ )
+ nodegroup_data = plugin_data['NODES'][nodegroup]
+ node_group_template = {
+ 'description': 'Test node group template',
+ 'plugin_name': cls.default_plugin,
+ 'hadoop_version': cls.default_version,
+ 'node_processes': nodegroup_data['node_processes'],
+ 'flavor_id': cls.flavor_ref,
+ 'node_configs': nodegroup_data.get('node_configs', {}),
+ }
+ return node_group_template
+ except (IndexError, KeyError):
+ return None
+
+ @classmethod
+ def get_cluster_template(cls, node_group_template_ids=None):
+ """Returns a cluster template for the default plugin.
+ node_group_template_defined contains the type and ID of pre-defined
+ node group templates that have to be used in the cluster template
+ (instead of dynamically defining them with 'node_processes').
+ """
+ if node_group_template_ids is None:
+ node_group_template_ids = {}
+ try:
+ plugin_data = (
+ DEFAULT_TEMPLATES[cls.default_plugin][cls.default_version]
+ )
+
+ all_node_groups = []
+ for ng_name, ng_data in six.iteritems(plugin_data['NODES']):
+ node_group = {
+ 'name': '%s-node' % (ng_name),
+ 'flavor_id': cls.flavor_ref,
+ 'count': ng_data['count']
+ }
+ if ng_name in node_group_template_ids.keys():
+ # node group already defined, use it
+ node_group['node_group_template_id'] = (
+ node_group_template_ids[ng_name]
+ )
+ else:
+ # node_processes list defined on-the-fly
+ node_group['node_processes'] = ng_data['node_processes']
+ if 'node_configs' in ng_data:
+ node_group['node_configs'] = ng_data['node_configs']
+ all_node_groups.append(node_group)
+
+ cluster_template = {
+ 'description': 'Test cluster template',
+ 'plugin_name': cls.default_plugin,
+ 'hadoop_version': cls.default_version,
+ 'cluster_configs': plugin_data.get('cluster_configs', {}),
+ 'node_groups': all_node_groups,
+ }
+ return cluster_template
+ except (IndexError, KeyError):
+ return None
diff --git a/tempest/api/data_processing/test_cluster_templates.py b/tempest/api/data_processing/test_cluster_templates.py
index 8a63c3f68..cebf493fb 100644
--- a/tempest/api/data_processing/test_cluster_templates.py
+++ b/tempest/api/data_processing/test_cluster_templates.py
@@ -15,6 +15,7 @@
from tempest_lib.common.utils import data_utils
from tempest.api.data_processing import base as dp_base
+from tempest import exceptions
from tempest import test
@@ -23,55 +24,30 @@ class ClusterTemplateTest(dp_base.BaseDataProcessingTest):
sahara/restapi/rest_api_v1.0.html#cluster-templates
"""
@classmethod
+ def skip_checks(cls):
+ super(ClusterTemplateTest, cls).skip_checks()
+ if cls.default_plugin is None:
+ raise cls.skipException("No Sahara plugins configured")
+
+ @classmethod
def resource_setup(cls):
super(ClusterTemplateTest, cls).resource_setup()
- # create node group template
- node_group_template = {
- 'name': data_utils.rand_name('sahara-ng-template'),
- 'description': 'Test node group template',
- 'plugin_name': 'vanilla',
- 'hadoop_version': '1.2.1',
- 'node_processes': ['datanode'],
- 'flavor_id': cls.flavor_ref,
- 'node_configs': {
- 'HDFS': {
- 'Data Node Heap Size': 1024
- }
- }
- }
- resp_body = cls.create_node_group_template(**node_group_template)
+
+ # pre-define a node group templates
+ node_group_template_w = cls.get_node_group_template('worker1')
+ if node_group_template_w is None:
+ raise exceptions.InvalidConfiguration(
+ message="No known Sahara plugin was found")
+
+ node_group_template_w['name'] = data_utils.rand_name(
+ 'sahara-ng-template')
+ resp_body = cls.create_node_group_template(**node_group_template_w)
node_group_template_id = resp_body['id']
+ configured_node_group_templates = {'worker1': node_group_template_id}
+
+ cls.full_cluster_template = cls.get_cluster_template(
+ configured_node_group_templates)
- cls.full_cluster_template = {
- 'description': 'Test cluster template',
- 'plugin_name': 'vanilla',
- 'hadoop_version': '1.2.1',
- 'cluster_configs': {
- 'HDFS': {
- 'dfs.replication': 2
- },
- 'MapReduce': {
- 'mapred.map.tasks.speculative.execution': False,
- 'mapred.child.java.opts': '-Xmx500m'
- },
- 'general': {
- 'Enable Swift': False
- }
- },
- 'node_groups': [
- {
- 'name': 'master-node',
- 'flavor_id': cls.flavor_ref,
- 'node_processes': ['namenode'],
- 'count': 1
- },
- {
- 'name': 'worker-node',
- 'node_group_template_id': node_group_template_id,
- 'count': 3
- }
- ]
- }
# create cls.cluster_template variable to use for comparison to cluster
# template response body. The 'node_groups' field in the response body
# has some extra info that post body does not have. The 'node_groups'
diff --git a/tempest/api/data_processing/test_node_group_templates.py b/tempest/api/data_processing/test_node_group_templates.py
index d7381f4d0..4068027e9 100644
--- a/tempest/api/data_processing/test_node_group_templates.py
+++ b/tempest/api/data_processing/test_node_group_templates.py
@@ -19,27 +19,16 @@ from tempest import test
class NodeGroupTemplateTest(dp_base.BaseDataProcessingTest):
+
+ @classmethod
+ def skip_checks(cls):
+ super(NodeGroupTemplateTest, cls).skip_checks()
+ if cls.default_plugin is None:
+ raise cls.skipException("No Sahara plugins configured")
+
@classmethod
def resource_setup(cls):
super(NodeGroupTemplateTest, cls).resource_setup()
- cls.node_group_template = {
- 'description': 'Test node group template',
- 'plugin_name': 'vanilla',
- 'hadoop_version': '1.2.1',
- 'node_processes': [
- 'datanode',
- 'tasktracker'
- ],
- 'flavor_id': cls.flavor_ref,
- 'node_configs': {
- 'HDFS': {
- 'Data Node Heap Size': 1024
- },
- 'MapReduce': {
- 'Task Tracker Heap Size': 1024
- }
- }
- }
def _create_node_group_template(self, template_name=None):
"""Creates Node Group Template with optional name specified.
@@ -47,6 +36,10 @@ class NodeGroupTemplateTest(dp_base.BaseDataProcessingTest):
It creates template, ensures template name and response body.
Returns id and name of created template.
"""
+ self.node_group_template = self.get_node_group_template()
+ self.assertIsNotNone(self.node_group_template,
+ "No known Sahara plugin was found")
+
if not template_name:
# generate random name if it's not specified
template_name = data_utils.rand_name('sahara-ng-template')
diff --git a/tempest/api/database/base.py b/tempest/api/database/base.py
index 1868f2326..f4c1881bb 100644
--- a/tempest/api/database/base.py
+++ b/tempest/api/database/base.py
@@ -25,6 +25,8 @@ LOG = logging.getLogger(__name__)
class BaseDatabaseTest(tempest.test.BaseTestCase):
"""Base test case class for all Database API tests."""
+ credentials = ['primary']
+
@classmethod
def skip_checks(cls):
super(BaseDatabaseTest, cls).skip_checks()
@@ -33,11 +35,6 @@ class BaseDatabaseTest(tempest.test.BaseTestCase):
raise cls.skipException(skip_msg)
@classmethod
- def setup_credentials(cls):
- super(BaseDatabaseTest, cls).setup_credentials()
- cls.os = cls.get_client_manager()
-
- @classmethod
def setup_clients(cls):
super(BaseDatabaseTest, cls).setup_clients()
cls.database_flavors_client = cls.os.database_flavors_client
diff --git a/tempest/api/database/flavors/test_flavors_negative.py b/tempest/api/database/flavors/test_flavors_negative.py
index 1b2c88cac..68cb7d684 100644
--- a/tempest/api/database/flavors/test_flavors_negative.py
+++ b/tempest/api/database/flavors/test_flavors_negative.py
@@ -26,7 +26,7 @@ class DatabaseFlavorsNegativeTest(base.BaseDatabaseTest):
super(DatabaseFlavorsNegativeTest, cls).setup_clients()
cls.client = cls.database_flavors_client
- @test.attr(type=['negative', 'gate'])
+ @test.attr(type=['negative'])
@test.idempotent_id('f8e7b721-373f-4a64-8e9c-5327e975af3e')
def test_get_non_existent_db_flavor(self):
# flavor details are not returned for non-existent flavors
diff --git a/tempest/api/identity/admin/v2/test_roles.py b/tempest/api/identity/admin/v2/test_roles.py
index b3746f291..4e89bfea8 100644
--- a/tempest/api/identity/admin/v2/test_roles.py
+++ b/tempest/api/identity/admin/v2/test_roles.py
@@ -45,7 +45,6 @@ class RolesTestJSON(base.BaseIdentityV2AdminTest):
found = True
self.assertTrue(found, "assigned role was not in list")
- @test.attr(type='gate')
@test.idempotent_id('75d9593f-50b7-4fcf-bd64-e3fb4a278e23')
def test_list_roles(self):
"""Return a list of all roles."""
@@ -54,7 +53,6 @@ class RolesTestJSON(base.BaseIdentityV2AdminTest):
self.assertTrue(any(found))
self.assertEqual(len(found), len(self.data.roles))
- @test.attr(type='gate')
@test.idempotent_id('c62d909d-6c21-48c0-ae40-0a0760e6db5e')
def test_role_create_delete(self):
"""Role should be created, verified, and deleted."""
@@ -72,7 +70,6 @@ class RolesTestJSON(base.BaseIdentityV2AdminTest):
found = [role for role in body if role['name'] == role_name]
self.assertFalse(any(found))
- @test.attr(type='gate')
@test.idempotent_id('db6870bd-a6ed-43be-a9b1-2f10a5c9994f')
def test_get_role_by_id(self):
"""Get a role by its id."""
@@ -83,7 +80,6 @@ class RolesTestJSON(base.BaseIdentityV2AdminTest):
self.assertEqual(role_id, body['id'])
self.assertEqual(role_name, body['name'])
- @test.attr(type='gate')
@test.idempotent_id('0146f675-ffbd-4208-b3a4-60eb628dbc5e')
def test_assign_user_role(self):
"""Assign a role to a user on a tenant."""
@@ -92,7 +88,6 @@ class RolesTestJSON(base.BaseIdentityV2AdminTest):
roles = self.client.list_user_roles(tenant['id'], user['id'])
self.assert_role_in_role_list(role, roles)
- @test.attr(type='gate')
@test.idempotent_id('f0b9292c-d3ba-4082-aa6c-440489beef69')
def test_remove_user_role(self):
"""Remove a role assigned to a user on a tenant."""
@@ -102,7 +97,6 @@ class RolesTestJSON(base.BaseIdentityV2AdminTest):
self.client.remove_user_role(tenant['id'], user['id'],
user_role['id'])
- @test.attr(type='gate')
@test.idempotent_id('262e1e3e-ed71-4edd-a0e5-d64e83d66d05')
def test_list_user_roles(self):
"""List roles assigned to a user on tenant."""
diff --git a/tempest/api/identity/admin/v2/test_roles_negative.py b/tempest/api/identity/admin/v2/test_roles_negative.py
index 5e197ece6..3654f9cb3 100644
--- a/tempest/api/identity/admin/v2/test_roles_negative.py
+++ b/tempest/api/identity/admin/v2/test_roles_negative.py
@@ -32,14 +32,14 @@ class RolesNegativeTestJSON(base.BaseIdentityV2AdminTest):
role = self.get_role_by_name(self.data.test_role)
return (user, tenant, role)
- @test.attr(type=['negative', 'gate'])
+ @test.attr(type=['negative'])
@test.idempotent_id('d5d5f1df-f8ca-4de0-b2ef-259c1cc67025')
def test_list_roles_by_unauthorized_user(self):
# Non-administrator user should not be able to list roles
self.assertRaises(lib_exc.Forbidden,
self.non_admin_client.list_roles)
- @test.attr(type=['negative', 'gate'])
+ @test.attr(type=['negative'])
@test.idempotent_id('11a3c7da-df6c-40c2-abc2-badd682edf9f')
def test_list_roles_request_without_token(self):
# Request to list roles without a valid token should fail
@@ -48,13 +48,13 @@ class RolesNegativeTestJSON(base.BaseIdentityV2AdminTest):
self.assertRaises(lib_exc.Unauthorized, self.client.list_roles)
self.client.auth_provider.clear_auth()
- @test.attr(type=['negative', 'gate'])
+ @test.attr(type=['negative'])
@test.idempotent_id('c0b89e56-accc-4c73-85f8-9c0f866104c1')
def test_role_create_blank_name(self):
# Should not be able to create a role with a blank name
self.assertRaises(lib_exc.BadRequest, self.client.create_role, '')
- @test.attr(type=['negative', 'gate'])
+ @test.attr(type=['negative'])
@test.idempotent_id('585c8998-a8a4-4641-a5dd-abef7a8ced00')
def test_create_role_by_unauthorized_user(self):
# Non-administrator user should not be able to create role
@@ -62,7 +62,7 @@ class RolesNegativeTestJSON(base.BaseIdentityV2AdminTest):
self.assertRaises(lib_exc.Forbidden,
self.non_admin_client.create_role, role_name)
- @test.attr(type=['negative', 'gate'])
+ @test.attr(type=['negative'])
@test.idempotent_id('a7edd17a-e34a-4aab-8bb7-fa6f498645b8')
def test_create_role_request_without_token(self):
# Request to create role without a valid token should fail
@@ -73,7 +73,7 @@ class RolesNegativeTestJSON(base.BaseIdentityV2AdminTest):
self.client.create_role, role_name)
self.client.auth_provider.clear_auth()
- @test.attr(type=['negative', 'gate'])
+ @test.attr(type=['negative'])
@test.idempotent_id('c0cde2c8-81c1-4bb0-8fe2-cf615a3547a8')
def test_role_create_duplicate(self):
# Role names should be unique
@@ -84,7 +84,7 @@ class RolesNegativeTestJSON(base.BaseIdentityV2AdminTest):
self.assertRaises(lib_exc.Conflict, self.client.create_role,
role_name)
- @test.attr(type=['negative', 'gate'])
+ @test.attr(type=['negative'])
@test.idempotent_id('15347635-b5b1-4a87-a280-deb2bd6d865e')
def test_delete_role_by_unauthorized_user(self):
# Non-administrator user should not be able to delete role
@@ -95,7 +95,7 @@ class RolesNegativeTestJSON(base.BaseIdentityV2AdminTest):
self.assertRaises(lib_exc.Forbidden,
self.non_admin_client.delete_role, role_id)
- @test.attr(type=['negative', 'gate'])
+ @test.attr(type=['negative'])
@test.idempotent_id('44b60b20-70de-4dac-beaf-a3fc2650a16b')
def test_delete_role_request_without_token(self):
# Request to delete role without a valid token should fail
@@ -110,7 +110,7 @@ class RolesNegativeTestJSON(base.BaseIdentityV2AdminTest):
role_id)
self.client.auth_provider.clear_auth()
- @test.attr(type=['negative', 'gate'])
+ @test.attr(type=['negative'])
@test.idempotent_id('38373691-8551-453a-b074-4260ad8298ef')
def test_delete_role_non_existent(self):
# Attempt to delete a non existent role should fail
@@ -118,7 +118,7 @@ class RolesNegativeTestJSON(base.BaseIdentityV2AdminTest):
self.assertRaises(lib_exc.NotFound, self.client.delete_role,
non_existent_role)
- @test.attr(type=['negative', 'gate'])
+ @test.attr(type=['negative'])
@test.idempotent_id('391df5cf-3ec3-46c9-bbe5-5cb58dd4dc41')
def test_assign_user_role_by_unauthorized_user(self):
# Non-administrator user should not be authorized to
@@ -128,7 +128,7 @@ class RolesNegativeTestJSON(base.BaseIdentityV2AdminTest):
self.non_admin_client.assign_user_role,
tenant['id'], user['id'], role['id'])
- @test.attr(type=['negative', 'gate'])
+ @test.attr(type=['negative'])
@test.idempotent_id('f0d2683c-5603-4aee-95d7-21420e87cfd8')
def test_assign_user_role_request_without_token(self):
# Request to assign a role to a user without a valid token
@@ -140,7 +140,7 @@ class RolesNegativeTestJSON(base.BaseIdentityV2AdminTest):
user['id'], role['id'])
self.client.auth_provider.clear_auth()
- @test.attr(type=['negative', 'gate'])
+ @test.attr(type=['negative'])
@test.idempotent_id('99b297f6-2b5d-47c7-97a9-8b6bb4f91042')
def test_assign_user_role_for_non_existent_role(self):
# Attempt to assign a non existent role to user should fail
@@ -149,7 +149,7 @@ class RolesNegativeTestJSON(base.BaseIdentityV2AdminTest):
self.assertRaises(lib_exc.NotFound, self.client.assign_user_role,
tenant['id'], user['id'], non_existent_role)
- @test.attr(type=['negative', 'gate'])
+ @test.attr(type=['negative'])
@test.idempotent_id('b2285aaa-9e76-4704-93a9-7a8acd0a6c8f')
def test_assign_user_role_for_non_existent_tenant(self):
# Attempt to assign a role on a non existent tenant should fail
@@ -158,7 +158,7 @@ class RolesNegativeTestJSON(base.BaseIdentityV2AdminTest):
self.assertRaises(lib_exc.NotFound, self.client.assign_user_role,
non_existent_tenant, user['id'], role['id'])
- @test.attr(type=['negative', 'gate'])
+ @test.attr(type=['negative'])
@test.idempotent_id('5c3132cd-c4c8-4402-b5ea-71eb44e97793')
def test_assign_duplicate_user_role(self):
# Duplicate user role should not get assigned
@@ -167,7 +167,7 @@ class RolesNegativeTestJSON(base.BaseIdentityV2AdminTest):
self.assertRaises(lib_exc.Conflict, self.client.assign_user_role,
tenant['id'], user['id'], role['id'])
- @test.attr(type=['negative', 'gate'])
+ @test.attr(type=['negative'])
@test.idempotent_id('d0537987-0977-448f-a435-904c15de7298')
def test_remove_user_role_by_unauthorized_user(self):
# Non-administrator user should not be authorized to
@@ -180,7 +180,7 @@ class RolesNegativeTestJSON(base.BaseIdentityV2AdminTest):
self.non_admin_client.remove_user_role,
tenant['id'], user['id'], role['id'])
- @test.attr(type=['negative', 'gate'])
+ @test.attr(type=['negative'])
@test.idempotent_id('cac81cf4-c1d2-47dc-90d3-f2b7eb572286')
def test_remove_user_role_request_without_token(self):
# Request to remove a user's role without a valid token
@@ -195,7 +195,7 @@ class RolesNegativeTestJSON(base.BaseIdentityV2AdminTest):
user['id'], role['id'])
self.client.auth_provider.clear_auth()
- @test.attr(type=['negative', 'gate'])
+ @test.attr(type=['negative'])
@test.idempotent_id('ab32d759-cd16-41f1-a86e-44405fa9f6d2')
def test_remove_user_role_non_existent_role(self):
# Attempt to delete a non existent role from a user should fail
@@ -207,7 +207,7 @@ class RolesNegativeTestJSON(base.BaseIdentityV2AdminTest):
self.assertRaises(lib_exc.NotFound, self.client.remove_user_role,
tenant['id'], user['id'], non_existent_role)
- @test.attr(type=['negative', 'gate'])
+ @test.attr(type=['negative'])
@test.idempotent_id('67a679ec-03dd-4551-bbfc-d1c93284f023')
def test_remove_user_role_non_existent_tenant(self):
# Attempt to remove a role from a non existent tenant should fail
@@ -219,7 +219,7 @@ class RolesNegativeTestJSON(base.BaseIdentityV2AdminTest):
self.assertRaises(lib_exc.NotFound, self.client.remove_user_role,
non_existent_tenant, user['id'], role['id'])
- @test.attr(type=['negative', 'gate'])
+ @test.attr(type=['negative'])
@test.idempotent_id('7391ab4c-06f3-477a-a64a-c8e55ce89837')
def test_list_user_roles_by_unauthorized_user(self):
# Non-administrator user should not be authorized to list
@@ -230,7 +230,7 @@ class RolesNegativeTestJSON(base.BaseIdentityV2AdminTest):
self.non_admin_client.list_user_roles, tenant['id'],
user['id'])
- @test.attr(type=['negative', 'gate'])
+ @test.attr(type=['negative'])
@test.idempotent_id('682adfb2-fd5f-4b0a-a9ca-322e9bebb907')
def test_list_user_roles_request_without_token(self):
# Request to list user's roles without a valid token should fail
diff --git a/tempest/api/identity/admin/v2/test_services.py b/tempest/api/identity/admin/v2/test_services.py
index 326c78bd4..aa7e3d27a 100644
--- a/tempest/api/identity/admin/v2/test_services.py
+++ b/tempest/api/identity/admin/v2/test_services.py
@@ -63,7 +63,6 @@ class ServicesTestJSON(base.BaseIdentityV2AdminTest):
self.assertEqual(fetched_service['description'],
service_data['description'])
- @test.attr(type='gate')
@test.idempotent_id('5d3252c8-e555-494b-a6c8-e11d7335da42')
def test_create_service_without_description(self):
# Create a service only with name and type
diff --git a/tempest/api/identity/admin/v2/test_tenant_negative.py b/tempest/api/identity/admin/v2/test_tenant_negative.py
index 3ee412b3e..367b69950 100644
--- a/tempest/api/identity/admin/v2/test_tenant_negative.py
+++ b/tempest/api/identity/admin/v2/test_tenant_negative.py
@@ -24,14 +24,14 @@ from tempest import test
class TenantsNegativeTestJSON(base.BaseIdentityV2AdminTest):
- @test.attr(type=['negative', 'gate'])
+ @test.attr(type=['negative'])
@test.idempotent_id('ca9bb202-63dd-4240-8a07-8ef9c19c04bb')
def test_list_tenants_by_unauthorized_user(self):
# Non-administrator user should not be able to list tenants
self.assertRaises(lib_exc.Forbidden,
self.non_admin_client.list_tenants)
- @test.attr(type=['negative', 'gate'])
+ @test.attr(type=['negative'])
@test.idempotent_id('df33926c-1c96-4d8d-a762-79cc6b0c3cf4')
def test_list_tenant_request_without_token(self):
# Request to list tenants without a valid token should fail
@@ -40,7 +40,7 @@ class TenantsNegativeTestJSON(base.BaseIdentityV2AdminTest):
self.assertRaises(lib_exc.Unauthorized, self.client.list_tenants)
self.client.auth_provider.clear_auth()
- @test.attr(type=['negative', 'gate'])
+ @test.attr(type=['negative'])
@test.idempotent_id('162ba316-f18b-4987-8c0c-fd9140cd63ed')
def test_tenant_delete_by_unauthorized_user(self):
# Non-administrator user should not be able to delete a tenant
@@ -50,7 +50,7 @@ class TenantsNegativeTestJSON(base.BaseIdentityV2AdminTest):
self.assertRaises(lib_exc.Forbidden,
self.non_admin_client.delete_tenant, tenant['id'])
- @test.attr(type=['negative', 'gate'])
+ @test.attr(type=['negative'])
@test.idempotent_id('e450db62-2e9d-418f-893a-54772d6386b1')
def test_tenant_delete_request_without_token(self):
# Request to delete a tenant without a valid token should fail
@@ -63,14 +63,14 @@ class TenantsNegativeTestJSON(base.BaseIdentityV2AdminTest):
tenant['id'])
self.client.auth_provider.clear_auth()
- @test.attr(type=['negative', 'gate'])
+ @test.attr(type=['negative'])
@test.idempotent_id('9c9a2aed-6e3c-467a-8f5c-89da9d1b516b')
def test_delete_non_existent_tenant(self):
# Attempt to delete a non existent tenant should fail
self.assertRaises(lib_exc.NotFound, self.client.delete_tenant,
str(uuid.uuid4().hex))
- @test.attr(type=['negative', 'gate'])
+ @test.attr(type=['negative'])
@test.idempotent_id('af16f44b-a849-46cb-9f13-a751c388f739')
def test_tenant_create_duplicate(self):
# Tenant names should be unique
@@ -85,7 +85,7 @@ class TenantsNegativeTestJSON(base.BaseIdentityV2AdminTest):
self.assertRaises(lib_exc.Conflict, self.client.create_tenant,
tenant_name)
- @test.attr(type=['negative', 'gate'])
+ @test.attr(type=['negative'])
@test.idempotent_id('d26b278a-6389-4702-8d6e-5980d80137e0')
def test_create_tenant_by_unauthorized_user(self):
# Non-administrator user should not be authorized to create a tenant
@@ -93,7 +93,7 @@ class TenantsNegativeTestJSON(base.BaseIdentityV2AdminTest):
self.assertRaises(lib_exc.Forbidden,
self.non_admin_client.create_tenant, tenant_name)
- @test.attr(type=['negative', 'gate'])
+ @test.attr(type=['negative'])
@test.idempotent_id('a3ee9d7e-6920-4dd5-9321-d4b2b7f0a638')
def test_create_tenant_request_without_token(self):
# Create tenant request without a token should not be authorized
@@ -104,14 +104,14 @@ class TenantsNegativeTestJSON(base.BaseIdentityV2AdminTest):
tenant_name)
self.client.auth_provider.clear_auth()
- @test.attr(type=['negative', 'gate'])
+ @test.attr(type=['negative'])
@test.idempotent_id('5a2e4ca9-b0c0-486c-9c48-64a94fba2395')
def test_create_tenant_with_empty_name(self):
# Tenant name should not be empty
self.assertRaises(lib_exc.BadRequest, self.client.create_tenant,
name='')
- @test.attr(type=['negative', 'gate'])
+ @test.attr(type=['negative'])
@test.idempotent_id('2ff18d1e-dfe3-4359-9dc3-abf582c196b9')
def test_create_tenants_name_length_over_64(self):
# Tenant name length should not be greater than 64 characters
@@ -119,14 +119,14 @@ class TenantsNegativeTestJSON(base.BaseIdentityV2AdminTest):
self.assertRaises(lib_exc.BadRequest, self.client.create_tenant,
tenant_name)
- @test.attr(type=['negative', 'gate'])
+ @test.attr(type=['negative'])
@test.idempotent_id('bd20dc2a-9557-4db7-b755-f48d952ad706')
def test_update_non_existent_tenant(self):
# Attempt to update a non existent tenant should fail
self.assertRaises(lib_exc.NotFound, self.client.update_tenant,
str(uuid.uuid4().hex))
- @test.attr(type=['negative', 'gate'])
+ @test.attr(type=['negative'])
@test.idempotent_id('41704dc5-c5f7-4f79-abfa-76e6fedc570b')
def test_tenant_update_by_unauthorized_user(self):
# Non-administrator user should not be able to update a tenant
@@ -136,7 +136,7 @@ class TenantsNegativeTestJSON(base.BaseIdentityV2AdminTest):
self.assertRaises(lib_exc.Forbidden,
self.non_admin_client.update_tenant, tenant['id'])
- @test.attr(type=['negative', 'gate'])
+ @test.attr(type=['negative'])
@test.idempotent_id('7a421573-72c7-4c22-a98e-ce539219c657')
def test_tenant_update_request_without_token(self):
# Request to update a tenant without a valid token should fail
diff --git a/tempest/api/identity/admin/v2/test_tenants.py b/tempest/api/identity/admin/v2/test_tenants.py
index 5dba65a46..cfd3d7fd8 100644
--- a/tempest/api/identity/admin/v2/test_tenants.py
+++ b/tempest/api/identity/admin/v2/test_tenants.py
@@ -22,7 +22,6 @@ from tempest import test
class TenantsTestJSON(base.BaseIdentityV2AdminTest):
- @test.attr(type='gate')
@test.idempotent_id('16c6e05c-6112-4b0e-b83f-5e43f221b6b0')
def test_tenant_list_delete(self):
# Create several tenants and delete them
@@ -45,7 +44,6 @@ class TenantsTestJSON(base.BaseIdentityV2AdminTest):
found = [tenant for tenant in body if tenant['id'] in tenant_ids]
self.assertFalse(any(found), 'Tenants failed to delete')
- @test.attr(type='gate')
@test.idempotent_id('d25e9f24-1310-4d29-b61b-d91299c21d6d')
def test_tenant_create_with_description(self):
# Create tenant with a description
@@ -66,7 +64,6 @@ class TenantsTestJSON(base.BaseIdentityV2AdminTest):
self.client.delete_tenant(tenant_id)
self.data.tenants.remove(tenant)
- @test.attr(type='gate')
@test.idempotent_id('670bdddc-1cd7-41c7-b8e2-751cfb67df50')
def test_tenant_create_enabled(self):
# Create a tenant that is enabled
@@ -83,7 +80,6 @@ class TenantsTestJSON(base.BaseIdentityV2AdminTest):
self.client.delete_tenant(tenant_id)
self.data.tenants.remove(tenant)
- @test.attr(type='gate')
@test.idempotent_id('3be22093-b30f-499d-b772-38340e5e16fb')
def test_tenant_create_not_enabled(self):
# Create a tenant that is not enabled
@@ -102,7 +98,6 @@ class TenantsTestJSON(base.BaseIdentityV2AdminTest):
self.client.delete_tenant(tenant_id)
self.data.tenants.remove(tenant)
- @test.attr(type='gate')
@test.idempotent_id('781f2266-d128-47f3-8bdb-f70970add238')
def test_tenant_update_name(self):
# Update name attribute of a tenant
@@ -129,7 +124,6 @@ class TenantsTestJSON(base.BaseIdentityV2AdminTest):
self.client.delete_tenant(t_id)
self.data.tenants.remove(tenant)
- @test.attr(type='gate')
@test.idempotent_id('859fcfe1-3a03-41ef-86f9-b19a47d1cd87')
def test_tenant_update_desc(self):
# Update description attribute of a tenant
@@ -157,7 +151,6 @@ class TenantsTestJSON(base.BaseIdentityV2AdminTest):
self.client.delete_tenant(t_id)
self.data.tenants.remove(tenant)
- @test.attr(type='gate')
@test.idempotent_id('8fc8981f-f12d-4c66-9972-2bdcf2bc2e1a')
def test_tenant_update_enable(self):
# Update the enabled attribute of a tenant
diff --git a/tempest/api/identity/admin/v2/test_tokens.py b/tempest/api/identity/admin/v2/test_tokens.py
index 860e5af7e..ee2530b02 100644
--- a/tempest/api/identity/admin/v2/test_tokens.py
+++ b/tempest/api/identity/admin/v2/test_tokens.py
@@ -21,7 +21,6 @@ from tempest import test
class TokensTestJSON(base.BaseIdentityV2AdminTest):
- @test.attr(type='gate')
@test.idempotent_id('453ad4d5-e486-4b2f-be72-cffc8149e586')
def test_create_get_delete_token(self):
# get a token by username and password
@@ -52,7 +51,6 @@ class TokensTestJSON(base.BaseIdentityV2AdminTest):
# then delete the token
self.client.delete_token(token_id)
- @test.attr(type='gate')
@test.idempotent_id('25ba82ee-8a32-4ceb-8f50-8b8c71e8765e')
def test_rescope_token(self):
"""An unscoped token can be requested, that token can be used to
diff --git a/tempest/api/identity/admin/v2/test_users.py b/tempest/api/identity/admin/v2/test_users.py
index f47f9850f..385f87856 100644
--- a/tempest/api/identity/admin/v2/test_users.py
+++ b/tempest/api/identity/admin/v2/test_users.py
@@ -105,7 +105,6 @@ class UsersTestJSON(base.BaseIdentityV2AdminTest):
self.data.test_password,
self.data.test_tenant)
- @test.attr(type='gate')
@test.idempotent_id('5d1fa498-4c2d-4732-a8fe-2b054598cfdd')
def test_authentication_request_without_token(self):
# Request for token authentication with a valid token in header
@@ -132,7 +131,6 @@ class UsersTestJSON(base.BaseIdentityV2AdminTest):
matchers.Contains(self.data.test_user),
"Could not find %s" % self.data.test_user)
- @test.attr(type='gate')
@test.idempotent_id('6e317209-383a-4bed-9f10-075b7c82c79a')
def test_list_users_for_tenant(self):
# Return a list of all users for a tenant
@@ -163,7 +161,6 @@ class UsersTestJSON(base.BaseIdentityV2AdminTest):
"Failed to find user %s in fetched list" %
', '.join(m_user for m_user in missing_users))
- @test.attr(type='gate')
@test.idempotent_id('a8b54974-40e1-41c0-b812-50fc90827971')
def test_list_users_with_roles_for_tenant(self):
# Return list of users on tenant when roles are assigned to users
diff --git a/tempest/api/identity/admin/v2/test_users_negative.py b/tempest/api/identity/admin/v2/test_users_negative.py
index dcf55653d..3c1500694 100644
--- a/tempest/api/identity/admin/v2/test_users_negative.py
+++ b/tempest/api/identity/admin/v2/test_users_negative.py
@@ -31,7 +31,7 @@ class UsersNegativeTestJSON(base.BaseIdentityV2AdminTest):
cls.alt_password = data_utils.rand_name('pass')
cls.alt_email = cls.alt_user + '@testmail.tm'
- @test.attr(type=['negative', 'gate'])
+ @test.attr(type=['negative'])
@test.idempotent_id('60a1f5fa-5744-4cdf-82bf-60b7de2d29a4')
def test_create_user_by_unauthorized_user(self):
# Non-administrator should not be authorized to create a user
@@ -41,7 +41,7 @@ class UsersNegativeTestJSON(base.BaseIdentityV2AdminTest):
self.alt_password, self.data.tenant['id'],
self.alt_email)
- @test.attr(type=['negative', 'gate'])
+ @test.attr(type=['negative'])
@test.idempotent_id('d80d0c2f-4514-4d1e-806d-0930dfc5a187')
def test_create_user_with_empty_name(self):
# User with an empty name should not be created
@@ -50,7 +50,7 @@ class UsersNegativeTestJSON(base.BaseIdentityV2AdminTest):
self.alt_password, self.data.tenant['id'],
self.alt_email)
- @test.attr(type=['negative', 'gate'])
+ @test.attr(type=['negative'])
@test.idempotent_id('7704b4f3-3b75-4b82-87cc-931d41c8f780')
def test_create_user_with_name_length_over_255(self):
# Length of user name filed should be restricted to 255 characters
@@ -59,7 +59,7 @@ class UsersNegativeTestJSON(base.BaseIdentityV2AdminTest):
'a' * 256, self.alt_password,
self.data.tenant['id'], self.alt_email)
- @test.attr(type=['negative', 'gate'])
+ @test.attr(type=['negative'])
@test.idempotent_id('57ae8558-120c-4723-9308-3751474e7ecf')
def test_create_user_with_duplicate_name(self):
# Duplicate user should not be created
@@ -68,7 +68,7 @@ class UsersNegativeTestJSON(base.BaseIdentityV2AdminTest):
self.data.test_user, self.data.test_password,
self.data.tenant['id'], self.data.test_email)
- @test.attr(type=['negative', 'gate'])
+ @test.attr(type=['negative'])
@test.idempotent_id('0132cc22-7c4f-42e1-9e50-ac6aad31d59a')
def test_create_user_for_non_existent_tenant(self):
# Attempt to create a user in a non-existent tenant should fail
@@ -76,7 +76,7 @@ class UsersNegativeTestJSON(base.BaseIdentityV2AdminTest):
self.alt_user, self.alt_password, '49ffgg99999',
self.alt_email)
- @test.attr(type=['negative', 'gate'])
+ @test.attr(type=['negative'])
@test.idempotent_id('55bbb103-d1ae-437b-989b-bcdf8175c1f4')
def test_create_user_request_without_a_token(self):
# Request to create a user without a valid token should fail
@@ -92,7 +92,7 @@ class UsersNegativeTestJSON(base.BaseIdentityV2AdminTest):
# Unset the token to allow further tests to generate a new token
self.client.auth_provider.clear_auth()
- @test.attr(type=['negative', 'gate'])
+ @test.attr(type=['negative'])
@test.idempotent_id('23a2f3da-4a1a-41da-abdd-632328a861ad')
def test_create_user_with_enabled_non_bool(self):
# Attempt to create a user with valid enabled para should fail
@@ -103,7 +103,7 @@ class UsersNegativeTestJSON(base.BaseIdentityV2AdminTest):
self.data.tenant['id'],
self.alt_email, enabled=3)
- @test.attr(type=['negative', 'gate'])
+ @test.attr(type=['negative'])
@test.idempotent_id('3d07e294-27a0-4144-b780-a2a1bf6fee19')
def test_update_user_for_non_existent_user(self):
# Attempt to update a user non-existent user should fail
@@ -112,7 +112,7 @@ class UsersNegativeTestJSON(base.BaseIdentityV2AdminTest):
self.assertRaises(lib_exc.NotFound, self.client.update_user,
non_existent_id, name=user_name)
- @test.attr(type=['negative', 'gate'])
+ @test.attr(type=['negative'])
@test.idempotent_id('3cc2a64b-83aa-4b02-88f0-d6ab737c4466')
def test_update_user_request_without_a_token(self):
# Request to update a user without a valid token should fail
@@ -127,7 +127,7 @@ class UsersNegativeTestJSON(base.BaseIdentityV2AdminTest):
# Unset the token to allow further tests to generate a new token
self.client.auth_provider.clear_auth()
- @test.attr(type=['negative', 'gate'])
+ @test.attr(type=['negative'])
@test.idempotent_id('424868d5-18a7-43e1-8903-a64f95ee3aac')
def test_update_user_by_unauthorized_user(self):
# Non-administrator should not be authorized to update user
@@ -135,7 +135,7 @@ class UsersNegativeTestJSON(base.BaseIdentityV2AdminTest):
self.assertRaises(lib_exc.Forbidden,
self.non_admin_client.update_user, self.alt_user)
- @test.attr(type=['negative', 'gate'])
+ @test.attr(type=['negative'])
@test.idempotent_id('d45195d5-33ed-41b9-a452-7d0d6a00f6e9')
def test_delete_users_by_unauthorized_user(self):
# Non-administrator user should not be authorized to delete a user
@@ -144,14 +144,14 @@ class UsersNegativeTestJSON(base.BaseIdentityV2AdminTest):
self.non_admin_client.delete_user,
self.data.user['id'])
- @test.attr(type=['negative', 'gate'])
+ @test.attr(type=['negative'])
@test.idempotent_id('7cc82f7e-9998-4f89-abae-23df36495867')
def test_delete_non_existent_user(self):
# Attempt to delete a non-existent user should fail
self.assertRaises(lib_exc.NotFound, self.client.delete_user,
'junk12345123')
- @test.attr(type=['negative', 'gate'])
+ @test.attr(type=['negative'])
@test.idempotent_id('57fe1df8-0aa7-46c0-ae9f-c2e785c7504a')
def test_delete_user_request_without_a_token(self):
# Request to delete a user without a valid token should fail
@@ -166,7 +166,7 @@ class UsersNegativeTestJSON(base.BaseIdentityV2AdminTest):
# Unset the token to allow further tests to generate a new token
self.client.auth_provider.clear_auth()
- @test.attr(type=['negative', 'gate'])
+ @test.attr(type=['negative'])
@test.idempotent_id('593a4981-f6d4-460a-99a1-57a78bf20829')
def test_authentication_for_disabled_user(self):
# Disabled user's token should not get authenticated
@@ -177,7 +177,7 @@ class UsersNegativeTestJSON(base.BaseIdentityV2AdminTest):
self.data.test_password,
self.data.test_tenant)
- @test.attr(type=['negative', 'gate'])
+ @test.attr(type=['negative'])
@test.idempotent_id('440a7a8d-9328-4b7b-83e0-d717010495e4')
def test_authentication_when_tenant_is_disabled(self):
# User's token for a disabled tenant should not be authenticated
@@ -188,7 +188,7 @@ class UsersNegativeTestJSON(base.BaseIdentityV2AdminTest):
self.data.test_password,
self.data.test_tenant)
- @test.attr(type=['negative', 'gate'])
+ @test.attr(type=['negative'])
@test.idempotent_id('921f1ad6-7907-40b8-853f-637e7ee52178')
def test_authentication_with_invalid_tenant(self):
# User's token for an invalid tenant should not be authenticated
@@ -198,7 +198,7 @@ class UsersNegativeTestJSON(base.BaseIdentityV2AdminTest):
self.data.test_password,
'junktenant1234')
- @test.attr(type=['negative', 'gate'])
+ @test.attr(type=['negative'])
@test.idempotent_id('bde9aecd-3b1c-4079-858f-beb5deaa5b5e')
def test_authentication_with_invalid_username(self):
# Non-existent user's token should not get authenticated
@@ -207,7 +207,7 @@ class UsersNegativeTestJSON(base.BaseIdentityV2AdminTest):
'junkuser123', self.data.test_password,
self.data.test_tenant)
- @test.attr(type=['negative', 'gate'])
+ @test.attr(type=['negative'])
@test.idempotent_id('d5308b33-3574-43c3-8d87-1c090c5e1eca')
def test_authentication_with_invalid_password(self):
# User's token with invalid password should not be authenticated
@@ -216,7 +216,7 @@ class UsersNegativeTestJSON(base.BaseIdentityV2AdminTest):
self.data.test_user, 'junkpass1234',
self.data.test_tenant)
- @test.attr(type=['negative', 'gate'])
+ @test.attr(type=['negative'])
@test.idempotent_id('284192ce-fb7c-4909-a63b-9a502e0ddd11')
def test_get_users_by_unauthorized_user(self):
# Non-administrator user should not be authorized to get user list
@@ -224,7 +224,7 @@ class UsersNegativeTestJSON(base.BaseIdentityV2AdminTest):
self.assertRaises(lib_exc.Forbidden,
self.non_admin_client.get_users)
- @test.attr(type=['negative', 'gate'])
+ @test.attr(type=['negative'])
@test.idempotent_id('a73591ec-1903-4ffe-be42-282b39fefc9d')
def test_get_users_request_without_token(self):
# Request to get list of users without a valid token should fail
@@ -233,7 +233,7 @@ class UsersNegativeTestJSON(base.BaseIdentityV2AdminTest):
self.assertRaises(lib_exc.Unauthorized, self.client.get_users)
self.client.auth_provider.clear_auth()
- @test.attr(type=['negative', 'gate'])
+ @test.attr(type=['negative'])
@test.idempotent_id('f5d39046-fc5f-425c-b29e-bac2632da28e')
def test_list_users_with_invalid_tenant(self):
# Should not be able to return a list of all
diff --git a/tempest/api/identity/admin/v3/test_endpoints.py b/tempest/api/identity/admin/v3/test_endpoints.py
index 2d8c04f60..1672d4773 100644
--- a/tempest/api/identity/admin/v3/test_endpoints.py
+++ b/tempest/api/identity/admin/v3/test_endpoints.py
@@ -57,7 +57,6 @@ class EndPointsTestJSON(base.BaseIdentityV3AdminTest):
cls.service_client.delete_service(s)
super(EndPointsTestJSON, cls).resource_cleanup()
- @test.attr(type='gate')
@test.idempotent_id('c19ecf90-240e-4e23-9966-21cee3f6a618')
def test_list_endpoints(self):
# Get a list of endpoints
@@ -69,7 +68,6 @@ class EndPointsTestJSON(base.BaseIdentityV3AdminTest):
"Failed to find endpoint %s in fetched list" %
', '.join(str(e) for e in missing_endpoints))
- @test.attr(type='gate')
@test.idempotent_id('0e2446d2-c1fd-461b-a729-b9e73e3e3b37')
def test_create_list_delete_endpoint(self):
region = data_utils.rand_name('region')
diff --git a/tempest/api/identity/admin/v3/test_endpoints_negative.py b/tempest/api/identity/admin/v3/test_endpoints_negative.py
index 8b855665c..7972dbb3a 100644
--- a/tempest/api/identity/admin/v3/test_endpoints_negative.py
+++ b/tempest/api/identity/admin/v3/test_endpoints_negative.py
@@ -48,7 +48,7 @@ class EndpointsNegativeTestJSON(base.BaseIdentityV3AdminTest):
cls.service_client.delete_service(s)
super(EndpointsNegativeTestJSON, cls).resource_cleanup()
- @test.attr(type=['negative', 'gate'])
+ @test.attr(type=['negative'])
@test.idempotent_id('ac6c137e-4d3d-448f-8c83-4f13d0942651')
def test_create_with_enabled_False(self):
# Enabled should be a boolean, not a string like 'False'
@@ -59,7 +59,7 @@ class EndpointsNegativeTestJSON(base.BaseIdentityV3AdminTest):
self.service_id, interface, url, region=region,
force_enabled='False')
- @test.attr(type=['negative', 'gate'])
+ @test.attr(type=['negative'])
@test.idempotent_id('9c43181e-0627-484a-8c79-923e8a59598b')
def test_create_with_enabled_True(self):
# Enabled should be a boolean, not a string like 'True'
@@ -84,13 +84,13 @@ class EndpointsNegativeTestJSON(base.BaseIdentityV3AdminTest):
self.assertRaises(lib_exc.BadRequest, self.client.update_endpoint,
endpoint_for_update['id'], force_enabled=enabled)
- @test.attr(type=['negative', 'gate'])
+ @test.attr(type=['negative'])
@test.idempotent_id('65e41f32-5eb7-498f-a92a-a6ccacf7439a')
def test_update_with_enabled_False(self):
# Enabled should be a boolean, not a string like 'False'
self._assert_update_raises_bad_request('False')
- @test.attr(type=['negative', 'gate'])
+ @test.attr(type=['negative'])
@test.idempotent_id('faba3587-f066-4757-a48e-b4a3f01803bb')
def test_update_with_enabled_True(self):
# Enabled should be a boolean, not a string like 'True'
diff --git a/tempest/api/identity/admin/v3/test_list_projects.py b/tempest/api/identity/admin/v3/test_list_projects.py
index 7b092fd80..d88b00dcf 100644
--- a/tempest/api/identity/admin/v3/test_list_projects.py
+++ b/tempest/api/identity/admin/v3/test_list_projects.py
@@ -38,7 +38,6 @@ class ListProjectsTestJSON(base.BaseIdentityV3AdminTest):
cls.data.projects.append(cls.p2)
cls.project_ids.append(cls.p2['id'])
- @test.attr(type='gate')
@test.idempotent_id('1d830662-22ad-427c-8c3e-4ec854b0af44')
def test_projects_list(self):
# List projects
@@ -48,20 +47,17 @@ class ListProjectsTestJSON(base.BaseIdentityV3AdminTest):
get_project = self.client.get_project(p)
self.assertIn(get_project, list_projects)
- @test.attr(type='gate')
@test.idempotent_id('fab13f3c-f6a6-4b9f-829b-d32fd44fdf10')
def test_list_projects_with_domains(self):
# List projects with domain
self._list_projects_with_params(
{'domain_id': self.data.domain['id']}, 'domain_id')
- @test.attr(type='gate')
@test.idempotent_id('0fe7a334-675a-4509-b00e-1c4b95d5dae8')
def test_list_projects_with_enabled(self):
# List the projects with enabled
self._list_projects_with_params({'enabled': False}, 'enabled')
- @test.attr(type='gate')
@test.idempotent_id('fa178524-4e6d-4925-907c-7ab9f42c7e26')
def test_list_projects_with_name(self):
# List projects with name
diff --git a/tempest/api/identity/admin/v3/test_list_users.py b/tempest/api/identity/admin/v3/test_list_users.py
index 6a073ced8..eeee3bb99 100644
--- a/tempest/api/identity/admin/v3/test_list_users.py
+++ b/tempest/api/identity/admin/v3/test_list_users.py
@@ -51,7 +51,6 @@ class UsersV3TestJSON(base.BaseIdentityV3AdminTest):
email=cls.alt_email, enabled=False)
cls.data.v3_users.append(cls.non_domain_enabled_user)
- @test.attr(type='gate')
@test.idempotent_id('08f9aabb-dcfe-41d0-8172-82b5fa0bd73d')
def test_list_user_domains(self):
# List users with domain
@@ -60,7 +59,6 @@ class UsersV3TestJSON(base.BaseIdentityV3AdminTest):
self.domain_enabled_user,
self.non_domain_enabled_user)
- @test.attr(type='gate')
@test.idempotent_id('bff8bf2f-9408-4ef5-b63a-753c8c2124eb')
def test_list_users_with_not_enabled(self):
# List the users with not enabled
@@ -69,7 +67,6 @@ class UsersV3TestJSON(base.BaseIdentityV3AdminTest):
self.non_domain_enabled_user,
self.domain_enabled_user)
- @test.attr(type='gate')
@test.idempotent_id('c285bb37-7325-4c02-bff3-3da5d946d683')
def test_list_users_with_name(self):
# List users with name
@@ -78,7 +75,6 @@ class UsersV3TestJSON(base.BaseIdentityV3AdminTest):
self.domain_enabled_user,
self.non_domain_enabled_user)
- @test.attr(type='gate')
@test.idempotent_id('b30d4651-a2ea-4666-8551-0c0e49692635')
def test_list_users(self):
# List users
@@ -90,7 +86,6 @@ class UsersV3TestJSON(base.BaseIdentityV3AdminTest):
"Failed to find user %s in fetched list" %
', '.join(m_user for m_user in missing_users))
- @test.attr(type='gate')
@test.idempotent_id('b4baa3ae-ac00-4b4e-9e27-80deaad7771f')
def test_get_user(self):
# Get a user detail
diff --git a/tempest/api/identity/admin/v3/test_projects.py b/tempest/api/identity/admin/v3/test_projects.py
index 5f8b3d198..41cf840a6 100644
--- a/tempest/api/identity/admin/v3/test_projects.py
+++ b/tempest/api/identity/admin/v3/test_projects.py
@@ -21,7 +21,6 @@ from tempest import test
class ProjectsTestJSON(base.BaseIdentityV3AdminTest):
- @test.attr(type='gate')
@test.idempotent_id('0ecf465c-0dc4-4532-ab53-91ffeb74d12d')
def test_project_create_with_description(self):
# Create project with a description
@@ -39,7 +38,6 @@ class ProjectsTestJSON(base.BaseIdentityV3AdminTest):
self.assertEqual(desc2, project_desc, 'Description does not appear'
'to be set')
- @test.attr(type='gate')
@test.idempotent_id('5f50fe07-8166-430b-a882-3b2ee0abe26f')
def test_project_create_with_domain(self):
# Create project with a domain
@@ -55,7 +53,6 @@ class ProjectsTestJSON(base.BaseIdentityV3AdminTest):
self.assertEqual(project_name, body['name'])
self.assertEqual(self.data.domain['id'], body['domain_id'])
- @test.attr(type='gate')
@test.idempotent_id('1f66dc76-50cc-4741-a200-af984509e480')
def test_project_create_enabled(self):
# Create a project that is enabled
@@ -70,7 +67,6 @@ class ProjectsTestJSON(base.BaseIdentityV3AdminTest):
en2 = body['enabled']
self.assertTrue(en2, 'Enable should be True in lookup')
- @test.attr(type='gate')
@test.idempotent_id('78f96a9c-e0e0-4ee6-a3ba-fbf6dfd03207')
def test_project_create_not_enabled(self):
# Create a project that is not enabled
@@ -86,7 +82,6 @@ class ProjectsTestJSON(base.BaseIdentityV3AdminTest):
self.assertEqual('false', str(en2).lower(),
'Enable should be False in lookup')
- @test.attr(type='gate')
@test.idempotent_id('f608f368-048c-496b-ad63-d286c26dab6b')
def test_project_update_name(self):
# Update name attribute of a project
@@ -108,7 +103,6 @@ class ProjectsTestJSON(base.BaseIdentityV3AdminTest):
self.assertEqual(p_name1, resp1_name)
self.assertEqual(resp2_name, resp3_name)
- @test.attr(type='gate')
@test.idempotent_id('f138b715-255e-4a7d-871d-351e1ef2e153')
def test_project_update_desc(self):
# Update description attribute of a project
@@ -132,7 +126,6 @@ class ProjectsTestJSON(base.BaseIdentityV3AdminTest):
self.assertEqual(p_desc, resp1_desc)
self.assertEqual(resp2_desc, resp3_desc)
- @test.attr(type='gate')
@test.idempotent_id('b6b25683-c97f-474d-a595-55d410b68100')
def test_project_update_enable(self):
# Update the enabled attribute of a project
@@ -156,7 +149,6 @@ class ProjectsTestJSON(base.BaseIdentityV3AdminTest):
self.assertEqual('false', str(resp1_en).lower())
self.assertEqual(resp2_en, resp3_en)
- @test.attr(type='gate')
@test.idempotent_id('59398d4a-5dc5-4f86-9a4c-c26cc804d6c6')
def test_associate_user_to_project(self):
# Associate a user to a project
diff --git a/tempest/api/identity/admin/v3/test_projects_negative.py b/tempest/api/identity/admin/v3/test_projects_negative.py
index 2dda5852c..37ec07149 100644
--- a/tempest/api/identity/admin/v3/test_projects_negative.py
+++ b/tempest/api/identity/admin/v3/test_projects_negative.py
@@ -22,14 +22,14 @@ from tempest import test
class ProjectsNegativeTestJSON(base.BaseIdentityV3AdminTest):
- @test.attr(type=['negative', 'gate'])
+ @test.attr(type=['negative'])
@test.idempotent_id('24c49279-45dd-4155-887a-cb738c2385aa')
def test_list_projects_by_unauthorized_user(self):
# Non-admin user should not be able to list projects
self.assertRaises(lib_exc.Forbidden,
self.non_admin_client.list_projects)
- @test.attr(type=['negative', 'gate'])
+ @test.attr(type=['negative'])
@test.idempotent_id('874c3e84-d174-4348-a16b-8c01f599561b')
def test_project_create_duplicate(self):
# Project names should be unique
@@ -40,7 +40,7 @@ class ProjectsNegativeTestJSON(base.BaseIdentityV3AdminTest):
self.assertRaises(
lib_exc.Conflict, self.client.create_project, project_name)
- @test.attr(type=['negative', 'gate'])
+ @test.attr(type=['negative'])
@test.idempotent_id('8fba9de2-3e1f-4e77-812a-60cb68f8df13')
def test_create_project_by_unauthorized_user(self):
# Non-admin user should not be authorized to create a project
@@ -49,14 +49,14 @@ class ProjectsNegativeTestJSON(base.BaseIdentityV3AdminTest):
lib_exc.Forbidden, self.non_admin_client.create_project,
project_name)
- @test.attr(type=['negative', 'gate'])
+ @test.attr(type=['negative'])
@test.idempotent_id('7828db17-95e5-475b-9432-9a51b4aa79a9')
def test_create_project_with_empty_name(self):
# Project name should not be empty
self.assertRaises(lib_exc.BadRequest, self.client.create_project,
name='')
- @test.attr(type=['negative', 'gate'])
+ @test.attr(type=['negative'])
@test.idempotent_id('502b6ceb-b0c8-4422-bf53-f08fdb21e2f0')
def test_create_projects_name_length_over_64(self):
# Project name length should not be greater than 64 characters
@@ -64,7 +64,7 @@ class ProjectsNegativeTestJSON(base.BaseIdentityV3AdminTest):
self.assertRaises(lib_exc.BadRequest, self.client.create_project,
project_name)
- @test.attr(type=['negative', 'gate'])
+ @test.attr(type=['negative'])
@test.idempotent_id('8d68c012-89e0-4394-8d6b-ccd7196def97')
def test_project_delete_by_unauthorized_user(self):
# Non-admin user should not be able to delete a project
@@ -75,7 +75,7 @@ class ProjectsNegativeTestJSON(base.BaseIdentityV3AdminTest):
lib_exc.Forbidden, self.non_admin_client.delete_project,
project['id'])
- @test.attr(type=['negative', 'gate'])
+ @test.attr(type=['negative'])
@test.idempotent_id('7965b581-60c1-43b7-8169-95d4ab7fc6fb')
def test_delete_non_existent_project(self):
# Attempt to delete a non existent project should fail
diff --git a/tempest/api/identity/admin/v3/test_regions.py b/tempest/api/identity/admin/v3/test_regions.py
index 146cc65bf..986007afe 100644
--- a/tempest/api/identity/admin/v3/test_regions.py
+++ b/tempest/api/identity/admin/v3/test_regions.py
@@ -47,7 +47,6 @@ class RegionsTestJSON(base.BaseIdentityV3AdminTest):
self.assertRaises(lib_exc.NotFound,
self.client.get_region, region_id)
- @test.attr(type='gate')
@test.idempotent_id('56186092-82e4-43f2-b954-91013218ba42')
def test_create_update_get_delete_region(self):
r_description = data_utils.rand_name('description')
@@ -85,7 +84,6 @@ class RegionsTestJSON(base.BaseIdentityV3AdminTest):
self.assertEqual(r_region_id, region['id'])
self.assertEqual(r_description, region['description'])
- @test.attr(type='gate')
@test.idempotent_id('d180bf99-544a-445c-ad0d-0c0d27663796')
def test_list_regions(self):
# Get a list of regions
diff --git a/tempest/api/identity/admin/v3/test_roles.py b/tempest/api/identity/admin/v3/test_roles.py
index 8334c184f..53aa15dfe 100644
--- a/tempest/api/identity/admin/v3/test_roles.py
+++ b/tempest/api/identity/admin/v3/test_roles.py
@@ -174,7 +174,6 @@ class RolesV3TestJSON(base.BaseIdentityV3AdminTest):
self.client.revoke_role_from_group_on_domain(
self.domain['id'], self.group_body['id'], self.role['id'])
- @test.attr(type='gate')
@test.idempotent_id('f5654bcc-08c4-4f71-88fe-05d64e06de94')
def test_list_roles(self):
# Return a list of all roles
diff --git a/tempest/api/identity/admin/v3/test_tokens.py b/tempest/api/identity/admin/v3/test_tokens.py
index 702e9366e..6ac601af7 100644
--- a/tempest/api/identity/admin/v3/test_tokens.py
+++ b/tempest/api/identity/admin/v3/test_tokens.py
@@ -49,7 +49,6 @@ class TokensV3TestJSON(base.BaseIdentityV3AdminTest):
self.assertRaises(lib_exc.NotFound, self.client.get_token,
subject_token)
- @test.attr(type='gate')
@test.idempotent_id('565fa210-1da1-4563-999b-f7b5b67cf112')
def test_rescope_token(self):
"""Rescope a token.
diff --git a/tempest/api/identity/admin/v3/test_users.py b/tempest/api/identity/admin/v3/test_users.py
index e4bfd6afa..7fe369e94 100644
--- a/tempest/api/identity/admin/v3/test_users.py
+++ b/tempest/api/identity/admin/v3/test_users.py
@@ -21,7 +21,6 @@ from tempest import test
class UsersV3TestJSON(base.BaseIdentityV3AdminTest):
- @test.attr(type='gate')
@test.idempotent_id('b537d090-afb9-4519-b95d-270b0708e87e')
def test_user_update(self):
# Test case to check if updating of user attributes is successful.
@@ -65,7 +64,6 @@ class UsersV3TestJSON(base.BaseIdentityV3AdminTest):
self.assertEqual(u_email2, new_user_get['email'])
self.assertEqual('false', str(new_user_get['enabled']).lower())
- @test.attr(type='gate')
@test.idempotent_id('2d223a0e-e457-4a70-9fb1-febe027a0ff9')
def test_update_user_password(self):
# Creating User to check password updation
@@ -88,7 +86,6 @@ class UsersV3TestJSON(base.BaseIdentityV3AdminTest):
self.assertEqual(token_details['user']['id'], user['id'])
self.assertEqual(token_details['user']['name'], u_name)
- @test.attr(type='gate')
@test.idempotent_id('a831e70c-e35b-430b-92ed-81ebbc5437b8')
def test_list_user_projects(self):
# List the projects that a user has access upon
@@ -142,7 +139,6 @@ class UsersV3TestJSON(base.BaseIdentityV3AdminTest):
', '.join(m_project for m_project
in missing_projects))
- @test.attr(type='gate')
@test.idempotent_id('c10dcd90-461d-4b16-8e23-4eb836c00644')
def test_get_user(self):
# Get a user detail
diff --git a/tempest/api/identity/base.py b/tempest/api/identity/base.py
index b83da3ead..5d66b9c73 100644
--- a/tempest/api/identity/base.py
+++ b/tempest/api/identity/base.py
@@ -17,9 +17,7 @@ from oslo_log import log as logging
from tempest_lib.common.utils import data_utils
from tempest_lib import exceptions as lib_exc
-from tempest import clients
from tempest.common import cred_provider
-from tempest.common import credentials
from tempest import config
import tempest.test
@@ -66,6 +64,8 @@ class BaseIdentityTest(tempest.test.BaseTestCase):
class BaseIdentityV2Test(BaseIdentityTest):
+ credentials = ['primary']
+
@classmethod
def setup_credentials(cls):
super(BaseIdentityV2Test, cls).setup_credentials()
@@ -94,24 +94,13 @@ class BaseIdentityV2Test(BaseIdentityTest):
class BaseIdentityV2AdminTest(BaseIdentityV2Test):
- @classmethod
- def setup_credentials(cls):
- super(BaseIdentityV2AdminTest, cls).setup_credentials()
- cls.os_adm = clients.Manager(cls.isolated_creds.get_admin_creds())
-
- @classmethod
- def skip_checks(cls):
- if not credentials.is_admin_available():
- raise cls.skipException('v2 Admin auth disabled')
- super(BaseIdentityV2AdminTest, cls).skip_checks()
+ credentials = ['admin']
@classmethod
def setup_clients(cls):
super(BaseIdentityV2AdminTest, cls).setup_clients()
cls.client = cls.os_adm.identity_client
cls.token_client = cls.os_adm.token_client
- if not cls.client.has_admin_extensions():
- raise cls.skipException("Admin extensions disabled")
@classmethod
def resource_setup(cls):
@@ -126,6 +115,8 @@ class BaseIdentityV2AdminTest(BaseIdentityV2Test):
class BaseIdentityV3Test(BaseIdentityTest):
+ credentials = ['primary']
+
@classmethod
def setup_credentials(cls):
super(BaseIdentityV3Test, cls).setup_credentials()
@@ -155,16 +146,7 @@ class BaseIdentityV3Test(BaseIdentityTest):
class BaseIdentityV3AdminTest(BaseIdentityV3Test):
- @classmethod
- def setup_credentials(cls):
- super(BaseIdentityV3AdminTest, cls).setup_credentials()
- cls.os_adm = clients.Manager(cls.isolated_creds.get_admin_creds())
-
- @classmethod
- def skip_checks(cls):
- if not credentials.is_admin_available():
- raise cls.skipException('v3 Admin auth disabled')
- super(BaseIdentityV3AdminTest, cls).skip_checks()
+ credentials = ['admin']
@classmethod
def setup_clients(cls):
diff --git a/tempest/api/identity/test_extension.py b/tempest/api/identity/test_extension.py
index f4a5c8666..b1d65b479 100644
--- a/tempest/api/identity/test_extension.py
+++ b/tempest/api/identity/test_extension.py
@@ -19,7 +19,6 @@ from tempest import test
class ExtensionTestJSON(base.BaseIdentityV2AdminTest):
- @test.attr(type='gate')
@test.idempotent_id('85f3f661-f54c-4d48-b563-72ae952b9383')
def test_list_extensions(self):
# List all the extensions
diff --git a/tempest/api/image/base.py b/tempest/api/image/base.py
index 74044dc50..acf8272dc 100644
--- a/tempest/api/image/base.py
+++ b/tempest/api/image/base.py
@@ -17,8 +17,6 @@ from six import moves
from tempest_lib.common.utils import data_utils
from tempest_lib import exceptions as lib_exc
-from tempest import clients
-from tempest.common import credentials
from tempest import config
import tempest.test
@@ -30,6 +28,8 @@ LOG = logging.getLogger(__name__)
class BaseImageTest(tempest.test.BaseTestCase):
"""Base test class for Image API tests."""
+ credentials = ['primary']
+
@classmethod
def skip_checks(cls):
super(BaseImageTest, cls).skip_checks()
@@ -39,14 +39,11 @@ class BaseImageTest(tempest.test.BaseTestCase):
@classmethod
def setup_credentials(cls):
+ cls.set_network_resources()
super(BaseImageTest, cls).setup_credentials()
- cls.isolated_creds = credentials.get_isolated_credentials(
- cls.__name__, network_resources=cls.network_resources)
- cls.os = clients.Manager(cls.isolated_creds.get_primary_creds())
@classmethod
def resource_setup(cls):
- cls.set_network_resources()
super(BaseImageTest, cls).resource_setup()
cls.created_images = []
@@ -96,10 +93,7 @@ class BaseV1ImageTest(BaseImageTest):
class BaseV1ImageMembersTest(BaseV1ImageTest):
- @classmethod
- def setup_credentials(cls):
- super(BaseV1ImageMembersTest, cls).setup_credentials()
- cls.os_alt = clients.Manager(cls.isolated_creds.get_alt_creds())
+ credentials = ['primary', 'alt']
@classmethod
def setup_clients(cls):
@@ -138,11 +132,7 @@ class BaseV2ImageTest(BaseImageTest):
class BaseV2MemberImageTest(BaseV2ImageTest):
- @classmethod
- def setup_credentials(cls):
- super(BaseV2MemberImageTest, cls).setup_credentials()
- creds = cls.isolated_creds.get_alt_creds()
- cls.os_alt = clients.Manager(creds)
+ credentials = ['primary', 'alt']
@classmethod
def setup_clients(cls):
diff --git a/tempest/api/image/v1/test_image_members.py b/tempest/api/image/v1/test_image_members.py
index 07a0df8c3..d57cb9302 100644
--- a/tempest/api/image/v1/test_image_members.py
+++ b/tempest/api/image/v1/test_image_members.py
@@ -19,7 +19,6 @@ from tempest import test
class ImageMembersTest(base.BaseV1ImageMembersTest):
- @test.attr(type='gate')
@test.idempotent_id('1d6ef640-3a20-4c84-8710-d95828fdb6ad')
def test_add_image_member(self):
image = self._create_image()
@@ -31,7 +30,6 @@ class ImageMembersTest(base.BaseV1ImageMembersTest):
# get image as alt user
self.alt_img_cli.get_image(image)
- @test.attr(type='gate')
@test.idempotent_id('6a5328a5-80e8-4b82-bd32-6c061f128da9')
def test_get_shared_images(self):
image = self._create_image()
@@ -44,7 +42,6 @@ class ImageMembersTest(base.BaseV1ImageMembersTest):
self.assertIn(share_image, images)
self.assertIn(image, images)
- @test.attr(type='gate')
@test.idempotent_id('a76a3191-8948-4b44-a9d6-4053e5f2b138')
def test_remove_member(self):
image_id = self._create_image()
diff --git a/tempest/api/image/v1/test_image_members_negative.py b/tempest/api/image/v1/test_image_members_negative.py
index ad3e13196..b96cf71ef 100644
--- a/tempest/api/image/v1/test_image_members_negative.py
+++ b/tempest/api/image/v1/test_image_members_negative.py
@@ -21,7 +21,7 @@ from tempest import test
class ImageMembersNegativeTest(base.BaseV1ImageMembersTest):
- @test.attr(type=['negative', 'gate'])
+ @test.attr(type=['negative'])
@test.idempotent_id('147a9536-18e3-45da-91ea-b037a028f364')
def test_add_member_with_non_existing_image(self):
# Add member with non existing image.
@@ -29,7 +29,7 @@ class ImageMembersNegativeTest(base.BaseV1ImageMembersTest):
self.assertRaises(lib_exc.NotFound, self.client.add_member,
self.alt_tenant_id, non_exist_image)
- @test.attr(type=['negative', 'gate'])
+ @test.attr(type=['negative'])
@test.idempotent_id('e1559f05-b667-4f1b-a7af-518b52dc0c0f')
def test_delete_member_with_non_existing_image(self):
# Delete member with non existing image.
@@ -37,7 +37,7 @@ class ImageMembersNegativeTest(base.BaseV1ImageMembersTest):
self.assertRaises(lib_exc.NotFound, self.client.delete_member,
self.alt_tenant_id, non_exist_image)
- @test.attr(type=['negative', 'gate'])
+ @test.attr(type=['negative'])
@test.idempotent_id('f5720333-dd69-4194-bb76-d2f048addd56')
def test_delete_member_with_non_existing_tenant(self):
# Delete member with non existing tenant.
@@ -46,7 +46,7 @@ class ImageMembersNegativeTest(base.BaseV1ImageMembersTest):
self.assertRaises(lib_exc.NotFound, self.client.delete_member,
non_exist_tenant, image_id)
- @test.attr(type=['negative', 'gate'])
+ @test.attr(type=['negative'])
@test.idempotent_id('f25f89e4-0b6c-453b-a853-1f80b9d7ef26')
def test_get_image_without_membership(self):
# Image is hidden from another tenants.
diff --git a/tempest/api/image/v1/test_images.py b/tempest/api/image/v1/test_images.py
index 49e167b07..ea9505932 100644
--- a/tempest/api/image/v1/test_images.py
+++ b/tempest/api/image/v1/test_images.py
@@ -26,7 +26,6 @@ CONF = config.CONF
class CreateRegisterImagesTest(base.BaseV1ImageTest):
"""Here we test the registration and creation of images."""
- @test.attr(type='gate')
@test.idempotent_id('3027f8e6-3492-4a11-8575-c3293017af4d')
def test_register_then_upload(self):
# Register, then upload an image
@@ -50,7 +49,6 @@ class CreateRegisterImagesTest(base.BaseV1ImageTest):
self.assertIn('size', body)
self.assertEqual(1024, body.get('size'))
- @test.attr(type='gate')
@test.idempotent_id('69da74d9-68a9-404b-9664-ff7164ccb0f5')
def test_register_remote_image(self):
# Register a new remote image
@@ -68,7 +66,6 @@ class CreateRegisterImagesTest(base.BaseV1ImageTest):
self.assertEqual(properties['key1'], 'value1')
self.assertEqual(properties['key2'], 'value2')
- @test.attr(type='gate')
@test.idempotent_id('6d0e13a7-515b-460c-b91f-9f4793f09816')
def test_register_http_image(self):
body = self.create_image(name='New Http Image',
@@ -82,7 +79,6 @@ class CreateRegisterImagesTest(base.BaseV1ImageTest):
self.client.wait_for_image_status(image_id, 'active')
self.client.get_image(image_id)
- @test.attr(type='gate')
@test.idempotent_id('05b19d55-140c-40d0-b36b-fafd774d421b')
def test_register_image_with_min_ram(self):
# Register an image with min ram
@@ -169,7 +165,6 @@ class ListImagesTest(base.BaseV1ImageTest):
image_id = image['id']
return image_id
- @test.attr(type='gate')
@test.idempotent_id('246178ab-3b33-4212-9a4b-a7fe8261794d')
def test_index_no_params(self):
# Simple test to see all fixture images returned
@@ -178,7 +173,6 @@ class ListImagesTest(base.BaseV1ImageTest):
for image_id in self.created_images:
self.assertIn(image_id, image_list)
- @test.attr(type='gate')
@test.idempotent_id('f1755589-63d6-4468-b098-589820eb4031')
def test_index_disk_format(self):
images_list = self.client.image_list(disk_format='ami')
@@ -188,7 +182,6 @@ class ListImagesTest(base.BaseV1ImageTest):
self.assertTrue(self.ami_set <= result_set)
self.assertFalse(self.created_set - self.ami_set <= result_set)
- @test.attr(type='gate')
@test.idempotent_id('2143655d-96d9-4bec-9188-8674206b4b3b')
def test_index_container_format(self):
images_list = self.client.image_list(container_format='bare')
@@ -198,7 +191,6 @@ class ListImagesTest(base.BaseV1ImageTest):
self.assertTrue(self.bare_set <= result_set)
self.assertFalse(self.created_set - self.bare_set <= result_set)
- @test.attr(type='gate')
@test.idempotent_id('feb32ac6-22bb-4a16-afd8-9454bb714b14')
def test_index_max_size(self):
images_list = self.client.image_list(size_max=42)
@@ -208,7 +200,6 @@ class ListImagesTest(base.BaseV1ImageTest):
self.assertTrue(self.size42_set <= result_set)
self.assertFalse(self.created_set - self.size42_set <= result_set)
- @test.attr(type='gate')
@test.idempotent_id('6ffc16d0-4cbf-4401-95c8-4ac63eac34d8')
def test_index_min_size(self):
images_list = self.client.image_list(size_min=142)
@@ -218,7 +209,6 @@ class ListImagesTest(base.BaseV1ImageTest):
self.assertTrue(self.size142_set <= result_set)
self.assertFalse(self.size42_set <= result_set)
- @test.attr(type='gate')
@test.idempotent_id('e5dc26d9-9aa2-48dd-bda5-748e1445da98')
def test_index_status_active_detail(self):
images_list = self.client.image_list_detail(status='active',
@@ -231,7 +221,6 @@ class ListImagesTest(base.BaseV1ImageTest):
top_size = size
self.assertEqual(image['status'], 'active')
- @test.attr(type='gate')
@test.idempotent_id('097af10a-bae8-4342-bff4-edf89969ed2a')
def test_index_name(self):
images_list = self.client.image_list_detail(
@@ -266,7 +255,6 @@ class UpdateImageMetaTest(base.BaseV1ImageTest):
image_id = image['id']
return image_id
- @test.attr(type='gate')
@test.idempotent_id('01752c1c-0275-4de3-9e5b-876e44541928')
def test_list_image_metadata(self):
# All metadata key/value pairs for an image should be returned
@@ -274,7 +262,6 @@ class UpdateImageMetaTest(base.BaseV1ImageTest):
expected = {'key1': 'value1'}
self.assertEqual(expected, resp_metadata['properties'])
- @test.attr(type='gate')
@test.idempotent_id('d6d7649c-08ce-440d-9ea7-e3dda552f33c')
def test_update_image_metadata(self):
# The metadata for the image should match the updated values
diff --git a/tempest/api/image/v1/test_images_negative.py b/tempest/api/image/v1/test_images_negative.py
index 85b943536..3d9440881 100644
--- a/tempest/api/image/v1/test_images_negative.py
+++ b/tempest/api/image/v1/test_images_negative.py
@@ -22,27 +22,27 @@ from tempest import test
class CreateDeleteImagesNegativeTest(base.BaseV1ImageTest):
"""Here are negative tests for the deletion and creation of images."""
- @test.attr(type=['negative', 'gate'])
+ @test.attr(type=['negative'])
@test.idempotent_id('036ede36-6160-4463-8c01-c781eee6369d')
def test_register_with_invalid_container_format(self):
# Negative tests for invalid data supplied to POST /images
self.assertRaises(lib_exc.BadRequest, self.client.create_image,
'test', 'wrong', 'vhd')
- @test.attr(type=['negative', 'gate'])
+ @test.attr(type=['negative'])
@test.idempotent_id('993face5-921d-4e84-aabf-c1bba4234a67')
def test_register_with_invalid_disk_format(self):
self.assertRaises(lib_exc.BadRequest, self.client.create_image,
'test', 'bare', 'wrong')
- @test.attr(type=['negative', 'gate'])
+ @test.attr(type=['negative'])
@test.idempotent_id('bb016f15-0820-4f27-a92d-09b2f67d2488')
def test_delete_image_with_invalid_image_id(self):
# An image should not be deleted with invalid image id
self.assertRaises(lib_exc.NotFound, self.client.delete_image,
'!@$%^&*()')
- @test.attr(type=['negative', 'gate'])
+ @test.attr(type=['negative'])
@test.idempotent_id('ec652588-7e3c-4b67-a2f2-0fa96f57c8fc')
def test_delete_non_existent_image(self):
# Return an error while trying to delete a non-existent image
@@ -51,13 +51,13 @@ class CreateDeleteImagesNegativeTest(base.BaseV1ImageTest):
self.assertRaises(lib_exc.NotFound, self.client.delete_image,
non_existent_image_id)
- @test.attr(type=['negative', 'gate'])
+ @test.attr(type=['negative'])
@test.idempotent_id('04f72aa3-fcec-45a3-81a3-308ef7cc82bc')
def test_delete_image_blank_id(self):
# Return an error while trying to delete an image with blank Id
self.assertRaises(lib_exc.NotFound, self.client.delete_image, '')
- @test.attr(type=['negative', 'gate'])
+ @test.attr(type=['negative'])
@test.idempotent_id('950e5054-a3c7-4dee-ada5-e576f1087abd')
def test_delete_image_non_hex_string_id(self):
# Return an error while trying to delete an image with non hex id
@@ -65,13 +65,13 @@ class CreateDeleteImagesNegativeTest(base.BaseV1ImageTest):
self.assertRaises(lib_exc.NotFound, self.client.delete_image,
image_id)
- @test.attr(type=['negative', 'gate'])
+ @test.attr(type=['negative'])
@test.idempotent_id('4ed757cd-450c-44b1-9fd1-c819748c650d')
def test_delete_image_negative_image_id(self):
# Return an error while trying to delete an image with negative id
self.assertRaises(lib_exc.NotFound, self.client.delete_image, -1)
- @test.attr(type=['negative', 'gate'])
+ @test.attr(type=['negative'])
@test.idempotent_id('a4a448ab-3db2-4d2d-b9b2-6a1271241dfe')
def test_delete_image_id_is_over_35_character_limit(self):
# Return an error while trying to delete image with id over limit
diff --git a/tempest/api/image/v2/test_images.py b/tempest/api/image/v2/test_images.py
index ef0b5f157..832ddf0ca 100644
--- a/tempest/api/image/v2/test_images.py
+++ b/tempest/api/image/v2/test_images.py
@@ -28,7 +28,6 @@ class BasicOperationsImagesTest(base.BaseV2ImageTest):
Here we test the basic operations of images
"""
- @test.attr(type='gate')
@test.idempotent_id('139b765e-7f3d-4b3d-8b37-3ca3876ee318')
def test_register_upload_get_image_file(self):
@@ -70,7 +69,6 @@ class BasicOperationsImagesTest(base.BaseV2ImageTest):
body = self.client.get_image_file(image_id)
self.assertEqual(file_content, body.data)
- @test.attr(type='gate')
@test.idempotent_id('f848bb94-1c6e-45a4-8726-39e3a5b23535')
def test_delete_image(self):
# Deletes an image by image_id
@@ -92,7 +90,6 @@ class BasicOperationsImagesTest(base.BaseV2ImageTest):
images_id = [item['id'] for item in images]
self.assertNotIn(image_id, images_id)
- @test.attr(type='gate')
@test.idempotent_id('f66891a7-a35c-41a8-b590-a065c2a1caa6')
def test_update_image(self):
# Updates an image by image_id
@@ -171,7 +168,6 @@ class ListImagesTest(base.BaseV2ImageTest):
msg = "Failed to list images by %s" % key
self.assertEqual(params[key], image[key], msg)
- @test.attr(type='gate')
@test.idempotent_id('1e341d7a-90a9-494c-b143-2cdf2aeb6aee')
def test_index_no_params(self):
# Simple test to see all fixture images returned
@@ -181,28 +177,24 @@ class ListImagesTest(base.BaseV2ImageTest):
for image in self.created_images:
self.assertIn(image, image_list)
- @test.attr(type='gate')
@test.idempotent_id('9959ca1d-1aa7-4b7a-a1ea-0fff0499b37e')
def test_list_images_param_container_format(self):
# Test to get all images with container_format='bare'
params = {"container_format": "bare"}
self._list_by_param_value_and_assert(params)
- @test.attr(type='gate')
@test.idempotent_id('4a4735a7-f22f-49b6-b0d9-66e1ef7453eb')
def test_list_images_param_disk_format(self):
# Test to get all images with disk_format = raw
params = {"disk_format": "raw"}
self._list_by_param_value_and_assert(params)
- @test.attr(type='gate')
@test.idempotent_id('7a95bb92-d99e-4b12-9718-7bc6ab73e6d2')
def test_list_images_param_visibility(self):
# Test to get all images with visibility = private
params = {"visibility": "private"}
self._list_by_param_value_and_assert(params)
- @test.attr(type='gate')
@test.idempotent_id('cf1b9a48-8340-480e-af7b-fe7e17690876')
def test_list_images_param_size(self):
# Test to get all images by size
@@ -213,7 +205,6 @@ class ListImagesTest(base.BaseV2ImageTest):
params = {"size": image['size']}
self._list_by_param_value_and_assert(params)
- @test.attr(type='gate')
@test.idempotent_id('4ad8c157-971a-4ba8-aa84-ed61154b1e7f')
def test_list_images_param_min_max_size(self):
# Test to get all images with size between 2000 to 3000
@@ -231,14 +222,12 @@ class ListImagesTest(base.BaseV2ImageTest):
image_size <= params['size_max'],
"Failed to get images by size_min and size_max")
- @test.attr(type='gate')
@test.idempotent_id('7fc9e369-0f58-4d05-9aa5-0969e2d59d15')
def test_list_images_param_status(self):
# Test to get all active images
params = {"status": "active"}
self._list_by_param_value_and_assert(params)
- @test.attr(type='gate')
@test.idempotent_id('e914a891-3cc8-4b40-ad32-e0a39ffbddbb')
def test_list_images_param_limit(self):
# Test to get images by limit
@@ -248,7 +237,6 @@ class ListImagesTest(base.BaseV2ImageTest):
self.assertEqual(len(images_list), params['limit'],
"Failed to get images by limit")
- @test.attr(type='gate')
@test.idempotent_id('622b925c-479f-4736-860d-adeaf13bc371')
def test_get_image_schema(self):
# Test to get image schema
@@ -256,7 +244,6 @@ class ListImagesTest(base.BaseV2ImageTest):
body = self.client.get_schema(schema)
self.assertEqual("image", body['name'])
- @test.attr(type='gate')
@test.idempotent_id('25c8d7b2-df21-460f-87ac-93130bcdc684')
def test_get_images_schema(self):
# Test to get images schema
diff --git a/tempest/api/image/v2/test_images_member.py b/tempest/api/image/v2/test_images_member.py
index bbe4ce8ea..26d41979f 100644
--- a/tempest/api/image/v2/test_images_member.py
+++ b/tempest/api/image/v2/test_images_member.py
@@ -16,7 +16,6 @@ from tempest import test
class ImagesMemberTest(base.BaseV2MemberImageTest):
- @test.attr(type='gate')
@test.idempotent_id('5934c6ea-27dc-4d6e-9421-eeb5e045494a')
def test_image_share_accept(self):
image_id = self._create_image()
@@ -38,7 +37,6 @@ class ImagesMemberTest(base.BaseV2MemberImageTest):
self.assertEqual(member['image_id'], image_id)
self.assertEqual(member['status'], 'accepted')
- @test.attr(type='gate')
@test.idempotent_id('d9e83e5f-3524-4b38-a900-22abcb26e90e')
def test_image_share_reject(self):
image_id = self._create_image()
@@ -53,7 +51,6 @@ class ImagesMemberTest(base.BaseV2MemberImageTest):
'rejected')
self.assertNotIn(image_id, self._list_image_ids_as_alt())
- @test.attr(type='gate')
@test.idempotent_id('a6ee18b9-4378-465e-9ad9-9a6de58a3287')
def test_get_image_member(self):
image_id = self._create_image()
@@ -70,7 +67,6 @@ class ImagesMemberTest(base.BaseV2MemberImageTest):
self.assertEqual(image_id, member['image_id'])
self.assertEqual('accepted', member['status'])
- @test.attr(type='gate')
@test.idempotent_id('72989bc7-2268-48ed-af22-8821e835c914')
def test_remove_image_member(self):
image_id = self._create_image()
@@ -84,13 +80,11 @@ class ImagesMemberTest(base.BaseV2MemberImageTest):
self.os_img_client.remove_member(image_id, self.alt_tenant_id)
self.assertNotIn(image_id, self._list_image_ids_as_alt())
- @test.attr(type='gate')
@test.idempotent_id('634dcc3f-f6e2-4409-b8fd-354a0bb25d83')
def test_get_image_member_schema(self):
body = self.os_img_client.get_schema("member")
self.assertEqual("member", body['name'])
- @test.attr(type='gate')
@test.idempotent_id('6ae916ef-1052-4e11-8d36-b3ae14853cbb')
def test_get_image_members_schema(self):
body = self.os_img_client.get_schema("members")
diff --git a/tempest/api/image/v2/test_images_member_negative.py b/tempest/api/image/v2/test_images_member_negative.py
index c07db0ef1..d95e5c1e8 100644
--- a/tempest/api/image/v2/test_images_member_negative.py
+++ b/tempest/api/image/v2/test_images_member_negative.py
@@ -18,7 +18,7 @@ from tempest import test
class ImagesMemberNegativeTest(base.BaseV2MemberImageTest):
- @test.attr(type=['negative', 'gate'])
+ @test.attr(type=['negative'])
@test.idempotent_id('b79efb37-820d-4cf0-b54c-308b00cf842c')
def test_image_share_invalid_status(self):
image_id = self._create_image()
@@ -29,7 +29,7 @@ class ImagesMemberNegativeTest(base.BaseV2MemberImageTest):
self.alt_img_client.update_member_status,
image_id, self.alt_tenant_id, 'notavalidstatus')
- @test.attr(type=['negative', 'gate'])
+ @test.attr(type=['negative'])
@test.idempotent_id('27002f74-109e-4a37-acd0-f91cd4597967')
def test_image_share_owner_cannot_accept(self):
image_id = self._create_image()
diff --git a/tempest/api/image/v2/test_images_negative.py b/tempest/api/image/v2/test_images_negative.py
index 23d32f46f..60a10a28b 100644
--- a/tempest/api/image/v2/test_images_negative.py
+++ b/tempest/api/image/v2/test_images_negative.py
@@ -36,7 +36,7 @@ class ImagesNegativeTest(base.BaseV2ImageTest):
** delete the deleted image
"""
- @test.attr(type=['negative', 'gate'])
+ @test.attr(type=['negative'])
@test.idempotent_id('668743d5-08ad-4480-b2b8-15da34f81d9f')
def test_get_non_existent_image(self):
# get the non-existent image
@@ -44,14 +44,14 @@ class ImagesNegativeTest(base.BaseV2ImageTest):
self.assertRaises(lib_exc.NotFound, self.client.get_image,
non_existent_id)
- @test.attr(type=['negative', 'gate'])
+ @test.attr(type=['negative'])
@test.idempotent_id('ef45000d-0a72-4781-866d-4cb7bf2562ad')
def test_get_image_null_id(self):
# get image with image_id = NULL
image_id = ""
self.assertRaises(lib_exc.NotFound, self.client.get_image, image_id)
- @test.attr(type=['negative', 'gate'])
+ @test.attr(type=['negative'])
@test.idempotent_id('e57fc127-7ba0-4693-92d7-1d8a05ebcba9')
def test_get_delete_deleted_image(self):
# get and delete the deleted image
@@ -70,7 +70,7 @@ class ImagesNegativeTest(base.BaseV2ImageTest):
self.assertRaises(lib_exc.NotFound, self.client.delete_image,
image_id)
- @test.attr(type=['negative', 'gate'])
+ @test.attr(type=['negative'])
@test.idempotent_id('6fe40f1c-57bd-4918-89cc-8500f850f3de')
def test_delete_non_existing_image(self):
# delete non-existent image
@@ -78,7 +78,7 @@ class ImagesNegativeTest(base.BaseV2ImageTest):
self.assertRaises(lib_exc.NotFound, self.client.delete_image,
non_existent_image_id)
- @test.attr(type=['negative', 'gate'])
+ @test.attr(type=['negative'])
@test.idempotent_id('32248db1-ab88-4821-9604-c7c369f1f88c')
def test_delete_image_null_id(self):
# delete image with image_id=NULL
@@ -86,14 +86,14 @@ class ImagesNegativeTest(base.BaseV2ImageTest):
self.assertRaises(lib_exc.NotFound, self.client.delete_image,
image_id)
- @test.attr(type=['negative', 'gate'])
+ @test.attr(type=['negative'])
@test.idempotent_id('292bd310-369b-41c7-a7a3-10276ef76753')
def test_register_with_invalid_container_format(self):
# Negative tests for invalid data supplied to POST /images
self.assertRaises(lib_exc.BadRequest, self.client.create_image,
'test', 'wrong', 'vhd')
- @test.attr(type=['negative', 'gate'])
+ @test.attr(type=['negative'])
@test.idempotent_id('70c6040c-5a97-4111-9e13-e73665264ce1')
def test_register_with_invalid_disk_format(self):
self.assertRaises(lib_exc.BadRequest, self.client.create_image,
diff --git a/tempest/api/image/v2/test_images_tags.py b/tempest/api/image/v2/test_images_tags.py
index 8c71db784..24688dc41 100644
--- a/tempest/api/image/v2/test_images_tags.py
+++ b/tempest/api/image/v2/test_images_tags.py
@@ -20,7 +20,6 @@ from tempest import test
class ImagesTagsTest(base.BaseV2ImageTest):
- @test.attr(type='gate')
@test.idempotent_id('10407036-6059-4f95-a2cd-cbbbee7ed329')
def test_update_delete_tags_for_image(self):
body = self.create_image(container_format='bare',
diff --git a/tempest/api/image/v2/test_images_tags_negative.py b/tempest/api/image/v2/test_images_tags_negative.py
index 227d35f3d..571b1f7ff 100644
--- a/tempest/api/image/v2/test_images_tags_negative.py
+++ b/tempest/api/image/v2/test_images_tags_negative.py
@@ -23,7 +23,7 @@ from tempest import test
class ImagesTagsNegativeTest(base.BaseV2ImageTest):
- @test.attr(type=['negative', 'gate'])
+ @test.attr(type=['negative'])
@test.idempotent_id('8cd30f82-6f9a-4c6e-8034-c1b51fba43d9')
def test_update_tags_for_non_existing_image(self):
# Update tag with non existing image.
@@ -32,7 +32,7 @@ class ImagesTagsNegativeTest(base.BaseV2ImageTest):
self.assertRaises(lib_exc.NotFound, self.client.add_image_tag,
non_exist_image, tag)
- @test.attr(type=['negative', 'gate'])
+ @test.attr(type=['negative'])
@test.idempotent_id('39c023a2-325a-433a-9eea-649bf1414b19')
def test_delete_non_existing_tag(self):
# Delete non existing tag.
diff --git a/tempest/api/messaging/base.py b/tempest/api/messaging/base.py
index c4214f27c..2ddc3fc4e 100644
--- a/tempest/api/messaging/base.py
+++ b/tempest/api/messaging/base.py
@@ -35,6 +35,8 @@ class BaseMessagingTest(test.BaseTestCase):
messaging as True
"""
+ credentials = ['primary']
+
@classmethod
def skip_checks(cls):
super(BaseMessagingTest, cls).skip_checks()
@@ -42,11 +44,6 @@ class BaseMessagingTest(test.BaseTestCase):
raise cls.skipException("Zaqar support is required")
@classmethod
- def setup_credentials(cls):
- super(BaseMessagingTest, cls).setup_credentials()
- cls.os = cls.get_client_manager()
-
- @classmethod
def setup_clients(cls):
super(BaseMessagingTest, cls).setup_clients()
cls.client = cls.os.messaging_client
diff --git a/tempest/api/network/admin/test_floating_ips_admin_actions.py b/tempest/api/network/admin/test_floating_ips_admin_actions.py
index ce3e31982..afc32da00 100644
--- a/tempest/api/network/admin/test_floating_ips_admin_actions.py
+++ b/tempest/api/network/admin/test_floating_ips_admin_actions.py
@@ -16,7 +16,6 @@
from tempest_lib.common.utils import data_utils
from tempest.api.network import base
-from tempest import clients
from tempest import config
from tempest import test
@@ -25,11 +24,7 @@ CONF = config.CONF
class FloatingIPAdminTestJSON(base.BaseAdminNetworkTest):
force_tenant_isolation = True
-
- @classmethod
- def setup_credentials(cls):
- super(FloatingIPAdminTestJSON, cls).setup_credentials()
- cls.alt_manager = clients.Manager(cls.isolated_creds.get_alt_creds())
+ credentials = ['primary', 'alt', 'admin']
@classmethod
def setup_clients(cls):
diff --git a/tempest/api/network/admin/test_load_balancer_admin_actions.py b/tempest/api/network/admin/test_load_balancer_admin_actions.py
index 5a32119cf..41f5caa99 100644
--- a/tempest/api/network/admin/test_load_balancer_admin_actions.py
+++ b/tempest/api/network/admin/test_load_balancer_admin_actions.py
@@ -27,6 +27,8 @@ class LoadBalancerAdminTestJSON(base.BaseAdminNetworkTest):
Create health monitor for another tenant
"""
+ force_tenant_isolation = True
+
@classmethod
def skip_checks(cls):
super(LoadBalancerAdminTestJSON, cls).skip_checks()
@@ -35,12 +37,6 @@ class LoadBalancerAdminTestJSON(base.BaseAdminNetworkTest):
raise cls.skipException(msg)
@classmethod
- def setup_credentials(cls):
- super(LoadBalancerAdminTestJSON, cls).setup_credentials()
- cls.manager = cls.get_client_manager()
- cls.primary_creds = cls.isolated_creds.get_primary_creds()
-
- @classmethod
def setup_clients(cls):
super(LoadBalancerAdminTestJSON, cls).setup_clients()
cls.client = cls.manager.network_client
@@ -48,8 +44,7 @@ class LoadBalancerAdminTestJSON(base.BaseAdminNetworkTest):
@classmethod
def resource_setup(cls):
super(LoadBalancerAdminTestJSON, cls).resource_setup()
- cls.force_tenant_isolation = True
- cls.tenant_id = cls.primary_creds.tenant_id
+ cls.tenant_id = cls.os.credentials.tenant_id
cls.network = cls.create_network()
cls.subnet = cls.create_subnet(cls.network)
cls.pool = cls.create_pool(data_utils.rand_name('pool-'),
diff --git a/tempest/api/network/admin/test_quotas.py b/tempest/api/network/admin/test_quotas.py
index 275c0d1cb..86fbc541d 100644
--- a/tempest/api/network/admin/test_quotas.py
+++ b/tempest/api/network/admin/test_quotas.py
@@ -85,7 +85,6 @@ class QuotasTest(base.BaseAdminNetworkTest):
for q in non_default_quotas['quotas']:
self.assertNotEqual(tenant_id, q['tenant_id'])
- @test.attr(type='gate')
@test.idempotent_id('2390f766-836d-40ef-9aeb-e810d78207fb')
def test_quotas(self):
new_quotas = {'network': 0, 'security_group': 0}
@@ -93,7 +92,6 @@ class QuotasTest(base.BaseAdminNetworkTest):
@test.idempotent_id('a7add2b1-691e-44d6-875f-697d9685f091')
@test.requires_ext(extension='lbaas', service='network')
- @test.attr(type='gate')
def test_lbaas_quotas(self):
new_quotas = {'vip': 1, 'pool': 2,
'member': 3, 'health_monitor': 4}
diff --git a/tempest/api/network/base.py b/tempest/api/network/base.py
index 26a31cb84..1cd138699 100644
--- a/tempest/api/network/base.py
+++ b/tempest/api/network/base.py
@@ -18,8 +18,6 @@ from oslo_log import log as logging
from tempest_lib.common.utils import data_utils
from tempest_lib import exceptions as lib_exc
-from tempest import clients
-from tempest.common import credentials
from tempest import config
from tempest import exceptions
import tempest.test
@@ -52,6 +50,7 @@ class BaseNetworkTest(tempest.test.BaseTestCase):
"""
force_tenant_isolation = False
+ credentials = ['primary']
# Default to ipv4.
_ip_version = 4
@@ -69,7 +68,6 @@ class BaseNetworkTest(tempest.test.BaseTestCase):
# Create no network resources for these test.
cls.set_network_resources()
super(BaseNetworkTest, cls).setup_credentials()
- cls.os = cls.get_client_manager()
@classmethod
def setup_clients(cls):
@@ -79,7 +77,6 @@ class BaseNetworkTest(tempest.test.BaseTestCase):
@classmethod
def resource_setup(cls):
super(BaseNetworkTest, cls).resource_setup()
-
cls.network_cfg = CONF.network
cls.networks = []
cls.subnets = []
@@ -426,19 +423,7 @@ class BaseNetworkTest(tempest.test.BaseTestCase):
class BaseAdminNetworkTest(BaseNetworkTest):
- @classmethod
- def skip_checks(cls):
- super(BaseAdminNetworkTest, cls).skip_checks()
- if not credentials.is_admin_available():
- msg = ("Missing Administrative Network API credentials "
- "in configuration.")
- raise cls.skipException(msg)
-
- @classmethod
- def setup_credentials(cls):
- super(BaseAdminNetworkTest, cls).setup_credentials()
- creds = cls.isolated_creds.get_admin_creds()
- cls.os_adm = clients.Manager(credentials=creds)
+ credentials = ['primary', 'admin']
@classmethod
def setup_clients(cls):
diff --git a/tempest/api/network/test_security_groups_negative.py b/tempest/api/network/test_security_groups_negative.py
index 0c5f0173e..ce6253b62 100644
--- a/tempest/api/network/test_security_groups_negative.py
+++ b/tempest/api/network/test_security_groups_negative.py
@@ -34,14 +34,14 @@ class NegativeSecGroupTest(base.BaseSecGroupTest):
msg = "security-group extension not enabled."
raise cls.skipException(msg)
- @test.attr(type=['negative', 'gate'])
+ @test.attr(type=['negative'])
@test.idempotent_id('424fd5c3-9ddc-486a-b45f-39bf0c820fc6')
def test_show_non_existent_security_group(self):
non_exist_id = str(uuid.uuid4())
self.assertRaises(lib_exc.NotFound, self.client.show_security_group,
non_exist_id)
- @test.attr(type=['negative', 'gate'])
+ @test.attr(type=['negative'])
@test.idempotent_id('4c094c09-000b-4e41-8100-9617600c02a6')
def test_show_non_existent_security_group_rule(self):
non_exist_id = str(uuid.uuid4())
@@ -49,7 +49,7 @@ class NegativeSecGroupTest(base.BaseSecGroupTest):
self.client.show_security_group_rule,
non_exist_id)
- @test.attr(type=['negative', 'gate'])
+ @test.attr(type=['negative'])
@test.idempotent_id('1f1bb89d-5664-4956-9fcd-83ee0fa603df')
def test_delete_non_existent_security_group(self):
non_exist_id = str(uuid.uuid4())
@@ -58,7 +58,7 @@ class NegativeSecGroupTest(base.BaseSecGroupTest):
non_exist_id
)
- @test.attr(type=['negative', 'gate'])
+ @test.attr(type=['negative'])
@test.idempotent_id('981bdc22-ce48-41ed-900a-73148b583958')
def test_create_security_group_rule_with_bad_protocol(self):
group_create_body, _ = self._create_security_group()
@@ -70,7 +70,7 @@ class NegativeSecGroupTest(base.BaseSecGroupTest):
security_group_id=group_create_body['security_group']['id'],
protocol=pname, direction='ingress', ethertype=self.ethertype)
- @test.attr(type=['negative', 'gate'])
+ @test.attr(type=['negative'])
@test.idempotent_id('5f8daf69-3c5f-4aaa-88c9-db1d66f68679')
def test_create_security_group_rule_with_bad_remote_ip_prefix(self):
group_create_body, _ = self._create_security_group()
@@ -84,7 +84,7 @@ class NegativeSecGroupTest(base.BaseSecGroupTest):
protocol='tcp', direction='ingress', ethertype=self.ethertype,
remote_ip_prefix=remote_ip_prefix)
- @test.attr(type=['negative', 'gate'])
+ @test.attr(type=['negative'])
@test.idempotent_id('4bf786fd-2f02-443c-9716-5b98e159a49a')
def test_create_security_group_rule_with_non_existent_remote_groupid(self):
group_create_body, _ = self._create_security_group()
@@ -99,7 +99,7 @@ class NegativeSecGroupTest(base.BaseSecGroupTest):
protocol='tcp', direction='ingress', ethertype=self.ethertype,
remote_group_id=remote_group_id)
- @test.attr(type=['negative', 'gate'])
+ @test.attr(type=['negative'])
@test.idempotent_id('b5c4b247-6b02-435b-b088-d10d45650881')
def test_create_security_group_rule_with_remote_ip_and_group(self):
sg1_body, _ = self._create_security_group()
@@ -114,7 +114,7 @@ class NegativeSecGroupTest(base.BaseSecGroupTest):
ethertype=self.ethertype, remote_ip_prefix=prefix,
remote_group_id=sg2_body['security_group']['id'])
- @test.attr(type=['negative', 'gate'])
+ @test.attr(type=['negative'])
@test.idempotent_id('5666968c-fff3-40d6-9efc-df1c8bd01abb')
def test_create_security_group_rule_with_bad_ethertype(self):
group_create_body, _ = self._create_security_group()
@@ -126,7 +126,7 @@ class NegativeSecGroupTest(base.BaseSecGroupTest):
security_group_id=group_create_body['security_group']['id'],
protocol='udp', direction='ingress', ethertype=ethertype)
- @test.attr(type=['negative', 'gate'])
+ @test.attr(type=['negative'])
@test.idempotent_id('0d9c7791-f2ad-4e2f-ac73-abf2373b0d2d')
def test_create_security_group_rule_with_invalid_ports(self):
group_create_body, _ = self._create_security_group()
@@ -206,7 +206,7 @@ class NegativeSecGroupIPv6Test(NegativeSecGroupTest):
_ip_version = 6
_tenant_network_cidr = CONF.network.tenant_network_v6_cidr
- @test.attr(type=['negative', 'gate'])
+ @test.attr(type=['negative'])
@test.idempotent_id('7607439c-af73-499e-bf64-f687fd12a842')
def test_create_security_group_rule_wrong_ip_prefix_version(self):
group_create_body, _ = self._create_security_group()
diff --git a/tempest/api/object_storage/base.py b/tempest/api/object_storage/base.py
index c8697e1ad..8bc9b12b8 100644
--- a/tempest/api/object_storage/base.py
+++ b/tempest/api/object_storage/base.py
@@ -37,9 +37,11 @@ class BaseObjectTest(tempest.test.BaseTestCase):
def setup_credentials(cls):
cls.set_network_resources()
super(BaseObjectTest, cls).setup_credentials()
+ operator_role = CONF.object_storage.operator_role
+ # There are no credentials by type used by object storage tests so
+ # isolated_creds must still be initialized
cls.isolated_creds = credentials.get_isolated_credentials(
cls.__name__, network_resources=cls.network_resources)
- operator_role = CONF.object_storage.operator_role
if not cls.isolated_creds.is_role_available(operator_role):
skip_msg = ("%s skipped because the configured credential provider"
" is not able to provide credentials with the %s role "
diff --git a/tempest/api/object_storage/test_account_bulk.py b/tempest/api/object_storage/test_account_bulk.py
index 54c87d7b4..da4c80c32 100644
--- a/tempest/api/object_storage/test_account_bulk.py
+++ b/tempest/api/object_storage/test_account_bulk.py
@@ -65,7 +65,6 @@ class BulkTest(base.BaseObjectTest):
self.assertHeaders(resp, 'Account', 'GET')
self.assertNotIn(container_name, body)
- @test.attr(type='gate')
@test.idempotent_id('a407de51-1983-47cc-9f14-47c2b059413c')
@test.requires_ext(extension='bulk', service='object')
def test_extract_archive(self):
@@ -102,7 +101,6 @@ class BulkTest(base.BaseObjectTest):
self.assertIn(object_name, [c['name'] for c in contents_list])
- @test.attr(type='gate')
@test.idempotent_id('c075e682-0d2a-43b2-808d-4116200d736d')
@test.requires_ext(extension='bulk', service='object')
def test_bulk_delete(self):
@@ -130,7 +128,6 @@ class BulkTest(base.BaseObjectTest):
# Check if uploaded contents are completely deleted
self._check_contents_deleted(container_name)
- @test.attr(type='gate')
@test.idempotent_id('dbea2bcb-efbb-4674-ac8a-a5a0e33d1d79')
@test.requires_ext(extension='bulk', service='object')
def test_bulk_delete_by_POST(self):
diff --git a/tempest/api/object_storage/test_account_services_negative.py b/tempest/api/object_storage/test_account_services_negative.py
index 4a482da7d..feccf18b6 100644
--- a/tempest/api/object_storage/test_account_services_negative.py
+++ b/tempest/api/object_storage/test_account_services_negative.py
@@ -31,7 +31,7 @@ class AccountNegativeTest(base.BaseObjectTest):
cls.isolated_creds.get_creds_by_roles(
roles=[CONF.object_storage.operator_role], force_new=True))
- @test.attr(type=['negative', 'gate'])
+ @test.attr(type=['negative'])
@test.idempotent_id('070e6aca-6152-4867-868d-1118d68fb38c')
def test_list_containers_with_non_authorized_user(self):
# list containers using non-authorized user
diff --git a/tempest/api/object_storage/test_container_acl_negative.py b/tempest/api/object_storage/test_container_acl_negative.py
index bbb44f4c6..f80cda488 100644
--- a/tempest/api/object_storage/test_container_acl_negative.py
+++ b/tempest/api/object_storage/test_container_acl_negative.py
@@ -46,7 +46,7 @@ class ObjectACLsNegativeTest(base.BaseObjectTest):
self.delete_containers([self.container_name])
super(ObjectACLsNegativeTest, self).tearDown()
- @test.attr(type=['negative', 'gate'])
+ @test.attr(type=['negative'])
@test.idempotent_id('af587587-0c24-4e15-9822-8352ce711013')
def test_write_object_without_using_creds(self):
# trying to create object with empty headers
@@ -60,7 +60,7 @@ class ObjectACLsNegativeTest(base.BaseObjectTest):
self.object_client.create_object,
self.container_name, object_name, 'data', headers={})
- @test.attr(type=['negative', 'gate'])
+ @test.attr(type=['negative'])
@test.idempotent_id('af85af0b-a025-4e72-a90e-121babf55720')
def test_delete_object_without_using_creds(self):
# create object
@@ -77,7 +77,7 @@ class ObjectACLsNegativeTest(base.BaseObjectTest):
self.object_client.delete_object,
self.container_name, object_name)
- @test.attr(type=['negative', 'gate'])
+ @test.attr(type=['negative'])
@test.idempotent_id('63d84e37-55a6-42e2-9e5f-276e60e26a00')
def test_write_object_with_non_authorized_user(self):
# attempt to upload another file using non-authorized user
@@ -92,7 +92,7 @@ class ObjectACLsNegativeTest(base.BaseObjectTest):
self.object_client.create_object,
self.container_name, object_name, 'data', headers={})
- @test.attr(type=['negative', 'gate'])
+ @test.attr(type=['negative'])
@test.idempotent_id('abf63359-be52-4feb-87dd-447689fc77fd')
def test_read_object_with_non_authorized_user(self):
# attempt to read object using non-authorized user
@@ -110,7 +110,7 @@ class ObjectACLsNegativeTest(base.BaseObjectTest):
self.object_client.get_object,
self.container_name, object_name)
- @test.attr(type=['negative', 'gate'])
+ @test.attr(type=['negative'])
@test.idempotent_id('7343ac3d-cfed-4198-9bb0-00149741a492')
def test_delete_object_with_non_authorized_user(self):
# attempt to delete object using non-authorized user
diff --git a/tempest/api/object_storage/test_container_staticweb.py b/tempest/api/object_storage/test_container_staticweb.py
index b579a45bc..20452aba3 100644
--- a/tempest/api/object_storage/test_container_staticweb.py
+++ b/tempest/api/object_storage/test_container_staticweb.py
@@ -51,7 +51,6 @@ class StaticWebTest(base.BaseObjectTest):
@test.idempotent_id('c1f055ab-621d-4a6a-831f-846fcb578b8b')
@test.requires_ext(extension='staticweb', service='object')
- @test.attr('gate')
def test_web_index(self):
headers = {'web-index': self.object_name}
@@ -83,7 +82,6 @@ class StaticWebTest(base.BaseObjectTest):
@test.idempotent_id('941814cf-db9e-4b21-8112-2b6d0af10ee5')
@test.requires_ext(extension='staticweb', service='object')
- @test.attr('gate')
def test_web_listing(self):
headers = {'web-listings': 'true'}
@@ -116,7 +114,6 @@ class StaticWebTest(base.BaseObjectTest):
@test.idempotent_id('bc37ec94-43c8-4990-842e-0e5e02fc8926')
@test.requires_ext(extension='staticweb', service='object')
- @test.attr('gate')
def test_web_listing_css(self):
headers = {'web-listings': 'true',
'web-listings-css': 'listings.css'}
@@ -141,7 +138,6 @@ class StaticWebTest(base.BaseObjectTest):
@test.idempotent_id('f18b4bef-212e-45e7-b3ca-59af3a465f82')
@test.requires_ext(extension='staticweb', service='object')
- @test.attr('gate')
def test_web_error(self):
headers = {'web-listings': 'true',
'web-error': self.object_name}
diff --git a/tempest/api/object_storage/test_crossdomain.py b/tempest/api/object_storage/test_crossdomain.py
index 9d49a7336..8dbfd06da 100644
--- a/tempest/api/object_storage/test_crossdomain.py
+++ b/tempest/api/object_storage/test_crossdomain.py
@@ -36,7 +36,6 @@ class CrossdomainTest(base.BaseObjectTest):
# Turning http://.../v1/foobar into http://.../
self.account_client.skip_path()
- @test.attr('gate')
@test.idempotent_id('d1b8b031-b622-4010-82f9-ff78a9e915c7')
@test.requires_ext(extension='crossdomain', service='object')
def test_get_crossdomain_policy(self):
diff --git a/tempest/api/object_storage/test_healthcheck.py b/tempest/api/object_storage/test_healthcheck.py
index 2ca0a9fde..104253ab6 100644
--- a/tempest/api/object_storage/test_healthcheck.py
+++ b/tempest/api/object_storage/test_healthcheck.py
@@ -25,7 +25,6 @@ class HealthcheckTest(base.BaseObjectTest):
# Turning http://.../v1/foobar into http://.../
self.account_client.skip_path()
- @test.attr('gate')
@test.idempotent_id('db5723b1-f25c-49a9-bfeb-7b5640caf337')
def test_get_healthcheck(self):
diff --git a/tempest/api/object_storage/test_object_expiry.py b/tempest/api/object_storage/test_object_expiry.py
index 89856b730..fec68733e 100644
--- a/tempest/api/object_storage/test_object_expiry.py
+++ b/tempest/api/object_storage/test_object_expiry.py
@@ -69,7 +69,6 @@ class ObjectExpiryTest(base.BaseObjectTest):
self.assertRaises(lib_exc.NotFound, self.object_client.get_object,
self.container_name, self.object_name)
- @test.attr(type='gate')
@test.idempotent_id('fb024a42-37f3-4ba5-9684-4f40a7910b41')
def test_get_object_after_expiry_time(self):
# the 10s is important, because the get calls can take 3s each
@@ -77,7 +76,6 @@ class ObjectExpiryTest(base.BaseObjectTest):
metadata = {'X-Delete-After': '10'}
self._test_object_expiry(metadata)
- @test.attr(type='gate')
@test.idempotent_id('e592f18d-679c-48fe-9e36-4be5f47102c5')
def test_get_object_at_expiry_time(self):
metadata = {'X-Delete-At': str(int(time.time()) + 10)}
diff --git a/tempest/api/object_storage/test_object_formpost.py b/tempest/api/object_storage/test_object_formpost.py
index e39879227..ce587d74e 100644
--- a/tempest/api/object_storage/test_object_formpost.py
+++ b/tempest/api/object_storage/test_object_formpost.py
@@ -107,7 +107,6 @@ class ObjectFormPostTest(base.BaseObjectTest):
@test.idempotent_id('80fac02b-6e54-4f7b-be0d-a965b5cbef76')
@test.requires_ext(extension='formpost', service='object')
- @test.attr(type='gate')
def test_post_object_using_form(self):
body, content_type = self.get_multipart_form()
diff --git a/tempest/api/object_storage/test_object_formpost_negative.py b/tempest/api/object_storage/test_object_formpost_negative.py
index 429afbf3b..89deca2af 100644
--- a/tempest/api/object_storage/test_object_formpost_negative.py
+++ b/tempest/api/object_storage/test_object_formpost_negative.py
@@ -108,7 +108,7 @@ class ObjectFormPostNegativeTest(base.BaseObjectTest):
@test.idempotent_id('d3fb3c4d-e627-48ce-9379-a1631f21336d')
@test.requires_ext(extension='formpost', service='object')
- @test.attr(type=['gate', 'negative'])
+ @test.attr(type=['negative'])
def test_post_object_using_form_expired(self):
body, content_type = self.get_multipart_form(expires=1)
time.sleep(2)
@@ -125,7 +125,6 @@ class ObjectFormPostNegativeTest(base.BaseObjectTest):
@test.idempotent_id('b277257f-113c-4499-b8d1-5fead79f7360')
@test.requires_ext(extension='formpost', service='object')
- @test.attr(type='gate')
def test_post_object_using_form_invalid_signature(self):
self.key = "Wrong"
body, content_type = self.get_multipart_form()
diff --git a/tempest/api/object_storage/test_object_services.py b/tempest/api/object_storage/test_object_services.py
index 5797e7fe2..6acd0f2b7 100644
--- a/tempest/api/object_storage/test_object_services.py
+++ b/tempest/api/object_storage/test_object_services.py
@@ -89,7 +89,6 @@ class ObjectTest(base.BaseObjectTest):
for meta_key in not_in_meta:
self.assertNotIn('x-object-meta-' + meta_key, resp)
- @test.attr(type='gate')
@test.idempotent_id('5b4ce26f-3545-46c9-a2ba-5754358a4c62')
def test_create_object(self):
# create object
@@ -109,7 +108,6 @@ class ObjectTest(base.BaseObjectTest):
object_name)
self.assertEqual(data, body)
- @test.attr(type='gate')
@test.idempotent_id('5daebb1d-f0d5-4dc9-b541-69672eff00b0')
def test_create_object_with_content_disposition(self):
# create object with content_disposition
@@ -132,7 +130,6 @@ class ObjectTest(base.BaseObjectTest):
self.assertEqual(resp['content-disposition'], 'inline')
self.assertEqual(body, data)
- @test.attr(type='gate')
@test.idempotent_id('605f8317-f945-4bee-ae91-013f1da8f0a0')
def test_create_object_with_content_encoding(self):
# create object with content_encoding
@@ -160,7 +157,6 @@ class ObjectTest(base.BaseObjectTest):
metadata=metadata)
self.assertEqual(body, data_before)
- @test.attr(type='gate')
@test.idempotent_id('73820093-0503-40b1-a478-edf0e69c7d1f')
def test_create_object_with_etag(self):
# create object with etag
@@ -180,7 +176,6 @@ class ObjectTest(base.BaseObjectTest):
object_name)
self.assertEqual(data, body)
- @test.attr(type='gate')
@test.idempotent_id('84dafe57-9666-4f6d-84c8-0814d37923b8')
def test_create_object_with_expect_continue(self):
# create object with expect_continue
@@ -207,7 +202,6 @@ class ObjectTest(base.BaseObjectTest):
object_name)
self.assertEqual(data, body)
- @test.attr(type='gate')
@test.idempotent_id('4f84422a-e2f2-4403-b601-726a4220b54e')
def test_create_object_with_transfer_encoding(self):
# create object with transfer_encoding
@@ -225,7 +219,6 @@ class ObjectTest(base.BaseObjectTest):
object_name)
self.assertEqual(data, body)
- @test.attr(type='gate')
@test.idempotent_id('0f3d62a6-47e3-4554-b0e5-1a5dc372d501')
def test_create_object_with_x_fresh_metadata(self):
# create object with x_fresh_metadata
@@ -252,7 +245,6 @@ class ObjectTest(base.BaseObjectTest):
self.assertNotIn('x-object-meta-test-meta', resp)
self.assertEqual(data, body)
- @test.attr(type='gate')
@test.idempotent_id('1c7ed3e4-2099-406b-b843-5301d4811baf')
def test_create_object_with_x_object_meta(self):
# create object with object_meta
@@ -272,7 +264,6 @@ class ObjectTest(base.BaseObjectTest):
self.assertEqual(resp['x-object-meta-test-meta'], 'Meta')
self.assertEqual(data, body)
- @test.attr(type='gate')
@test.idempotent_id('e4183917-33db-4153-85cc-4dacbb938865')
def test_create_object_with_x_object_metakey(self):
# create object with the blank value of metadata
@@ -292,7 +283,6 @@ class ObjectTest(base.BaseObjectTest):
self.assertEqual(resp['x-object-meta-test-meta'], '')
self.assertEqual(data, body)
- @test.attr(type='gate')
@test.idempotent_id('ce798afc-b278-45de-a5ce-2ea124b98b99')
def test_create_object_with_x_remove_object_meta(self):
# create object with x_remove_object_meta
@@ -316,7 +306,6 @@ class ObjectTest(base.BaseObjectTest):
self.assertNotIn('x-object-meta-test-meta', resp)
self.assertEqual(data, body)
- @test.attr(type='gate')
@test.idempotent_id('ad21e342-7916-4f9e-ab62-a1f885f2aaf9')
def test_create_object_with_x_remove_object_metakey(self):
# create object with the blank value of remove metadata
@@ -340,7 +329,6 @@ class ObjectTest(base.BaseObjectTest):
self.assertNotIn('x-object-meta-test-meta', resp)
self.assertEqual(data, body)
- @test.attr(type='gate')
@test.idempotent_id('17738d45-03bd-4d45-9e0b-7b2f58f98687')
def test_delete_object(self):
# create object
@@ -944,7 +932,6 @@ class ObjectTest(base.BaseObjectTest):
# check destination object
self._check_copied_obj(dst_obj_name, data, in_meta=["test", "src"])
- @test.attr(type='gate')
@test.idempotent_id('e3e6a64a-9f50-4955-b987-6ce6767c97fb')
def test_object_upload_in_segments(self):
# create object
@@ -987,7 +974,6 @@ class ObjectTest(base.BaseObjectTest):
self.container_name, object_name)
self.assertEqual(''.join(data_segments), body)
- @test.attr(type='gate')
@test.idempotent_id('50d01f12-526f-4360-9ac2-75dd508d7b68')
def test_get_object_if_different(self):
# http://en.wikipedia.org/wiki/HTTP_ETag
diff --git a/tempest/api/object_storage/test_object_slo.py b/tempest/api/object_storage/test_object_slo.py
index 96a78b9dd..7df0dde83 100644
--- a/tempest/api/object_storage/test_object_slo.py
+++ b/tempest/api/object_storage/test_object_slo.py
@@ -109,7 +109,6 @@ class ObjectSloTest(base.BaseObjectTest):
resp['etag'] = resp['etag'].strip('"')
self.assertHeaders(resp, 'Object', method)
- @test.attr(type='gate')
@test.idempotent_id('2c3f24a6-36e8-4711-9aa2-800ee1fc7b5b')
def test_upload_manifest(self):
# create static large object from multipart manifest
@@ -124,7 +123,6 @@ class ObjectSloTest(base.BaseObjectTest):
self._assertHeadersSLO(resp, 'PUT')
- @test.attr(type='gate')
@test.idempotent_id('e69ad766-e1aa-44a2-bdd2-bf62c09c1456')
def test_list_large_object_metadata(self):
# list static large object metadata using multipart manifest
@@ -136,7 +134,6 @@ class ObjectSloTest(base.BaseObjectTest):
self._assertHeadersSLO(resp, 'HEAD')
- @test.attr(type='gate')
@test.idempotent_id('49bc49bc-dd1b-4c0f-904e-d9f10b830ee8')
def test_retrieve_large_object(self):
# list static large object using multipart manifest
@@ -151,7 +148,6 @@ class ObjectSloTest(base.BaseObjectTest):
sum_data = self.content + self.content
self.assertEqual(body, sum_data)
- @test.attr(type='gate')
@test.idempotent_id('87b6dfa1-abe9-404d-8bf0-6c3751e6aa77')
def test_delete_large_object(self):
# delete static large object using multipart manifest
diff --git a/tempest/api/object_storage/test_object_temp_url.py b/tempest/api/object_storage/test_object_temp_url.py
index ce67e85a8..874826948 100644
--- a/tempest/api/object_storage/test_object_temp_url.py
+++ b/tempest/api/object_storage/test_object_temp_url.py
@@ -92,7 +92,6 @@ class ObjectTempUrlTest(base.BaseObjectTest):
return url
- @test.attr(type='gate')
@test.idempotent_id('f91c96d4-1230-4bba-8eb9-84476d18d991')
@test.requires_ext(extension='tempurl', service='object')
def test_get_object_using_temp_url(self):
@@ -112,7 +111,6 @@ class ObjectTempUrlTest(base.BaseObjectTest):
resp, body = self.object_client.head(url)
self.assertHeaders(resp, 'Object', 'HEAD')
- @test.attr(type='gate')
@test.idempotent_id('671f9583-86bd-4128-a034-be282a68c5d8')
@test.requires_ext(extension='tempurl', service='object')
def test_get_object_using_temp_url_key_2(self):
@@ -137,7 +135,6 @@ class ObjectTempUrlTest(base.BaseObjectTest):
resp, body = self.object_client.get(url)
self.assertEqual(body, self.content)
- @test.attr(type='gate')
@test.idempotent_id('9b08dade-3571-4152-8a4f-a4f2a873a735')
@test.requires_ext(extension='tempurl', service='object')
def test_put_object_using_temp_url(self):
@@ -166,7 +163,6 @@ class ObjectTempUrlTest(base.BaseObjectTest):
_, body = self.object_client.get(url)
self.assertEqual(body, new_data)
- @test.attr(type='gate')
@test.idempotent_id('249a0111-5ad3-4534-86a7-1993d55f9185')
@test.requires_ext(extension='tempurl', service='object')
def test_head_object_using_temp_url(self):
@@ -181,7 +177,6 @@ class ObjectTempUrlTest(base.BaseObjectTest):
resp, body = self.object_client.head(url)
self.assertHeaders(resp, 'Object', 'HEAD')
- @test.attr(type='gate')
@test.idempotent_id('9d9cfd90-708b-465d-802c-e4a8090b823d')
@test.requires_ext(extension='tempurl', service='object')
def test_get_object_using_temp_url_with_inline_query_parameter(self):
diff --git a/tempest/api/object_storage/test_object_temp_url_negative.py b/tempest/api/object_storage/test_object_temp_url_negative.py
index c054b2346..233cced1d 100644
--- a/tempest/api/object_storage/test_object_temp_url_negative.py
+++ b/tempest/api/object_storage/test_object_temp_url_negative.py
@@ -90,7 +90,7 @@ class ObjectTempUrlNegativeTest(base.BaseObjectTest):
return url
- @test.attr(type=['gate', 'negative'])
+ @test.attr(type=['negative'])
@test.idempotent_id('5a583aca-c804-41ba-9d9a-e7be132bdf0b')
@test.requires_ext(extension='tempurl', service='object')
def test_get_object_after_expiration_time(self):
diff --git a/tempest/api/orchestration/base.py b/tempest/api/orchestration/base.py
index d4b107e7a..beb4ac8eb 100644
--- a/tempest/api/orchestration/base.py
+++ b/tempest/api/orchestration/base.py
@@ -18,7 +18,6 @@ from tempest_lib import exceptions as lib_exc
import yaml
from tempest import clients
-from tempest.common import credentials
from tempest import config
import tempest.test
@@ -30,6 +29,8 @@ LOG = logging.getLogger(__name__)
class BaseOrchestrationTest(tempest.test.BaseTestCase):
"""Base test case class for all Orchestration API tests."""
+ credentials = ['primary']
+
@classmethod
def skip_checks(cls):
super(BaseOrchestrationTest, cls).skip_checks()
@@ -39,10 +40,6 @@ class BaseOrchestrationTest(tempest.test.BaseTestCase):
@classmethod
def setup_credentials(cls):
super(BaseOrchestrationTest, cls).setup_credentials()
- if (not hasattr(cls, 'isolated_creds') or
- not cls.isolated_creds.name == cls.__name__):
- cls.isolated_creds = credentials.get_isolated_credentials(
- name=cls.__name__, network_resources=cls.network_resources)
stack_owner_role = CONF.orchestration.stack_owner_role
if not cls.isolated_creds.is_role_available(stack_owner_role):
skip_msg = ("%s skipped because the configured credential provider"
diff --git a/tempest/api/orchestration/stacks/test_environment.py b/tempest/api/orchestration/stacks/test_environment.py
index df67ef2eb..ecb824b15 100644
--- a/tempest/api/orchestration/stacks/test_environment.py
+++ b/tempest/api/orchestration/stacks/test_environment.py
@@ -25,7 +25,6 @@ LOG = logging.getLogger(__name__)
class StackEnvironmentTest(base.BaseOrchestrationTest):
- @test.attr(type='gate')
@test.idempotent_id('37d4346b-1abd-4442-b7b1-2a4e5749a1e3')
def test_environment_parameter(self):
"""Test passing a stack parameter via the environment."""
@@ -43,7 +42,6 @@ class StackEnvironmentTest(base.BaseOrchestrationTest):
random_value = self.get_stack_output(stack_identifier, 'random_value')
self.assertEqual(20, len(random_value))
- @test.attr(type='gate')
@test.idempotent_id('73bce717-ad22-4853-bbef-6ed89b632701')
def test_environment_provider_resource(self):
"""Test passing resource_registry defining a provider resource."""
@@ -73,7 +71,6 @@ outputs:
'random_length']['default']
self.assertEqual(expected_length, len(random_value))
- @test.attr(type='gate')
@test.idempotent_id('9d682e5a-f4bb-47d5-8472-9d3cacb855df')
def test_files_provider_resource(self):
"""Test untyped defining of a provider resource via "files"."""
diff --git a/tempest/api/orchestration/stacks/test_limits.py b/tempest/api/orchestration/stacks/test_limits.py
index c49b040d4..4291d76da 100644
--- a/tempest/api/orchestration/stacks/test_limits.py
+++ b/tempest/api/orchestration/stacks/test_limits.py
@@ -26,7 +26,6 @@ LOG = logging.getLogger(__name__)
class TestServerStackLimits(base.BaseOrchestrationTest):
- @test.attr(type='gate')
@test.idempotent_id('ec9bed71-c460-45c9-ab98-295caa9fd76b')
def test_exceed_max_template_size_fails(self):
stack_name = data_utils.rand_name('heat')
@@ -40,7 +39,6 @@ Outputs:
stack_name, template)
self.assertIn('Template exceeds maximum allowed size', str(ex))
- @test.attr(type='gate')
@test.idempotent_id('d1b83e73-7cad-4a22-9839-036548c5387c')
def test_exceed_max_resources_per_stack(self):
stack_name = data_utils.rand_name('heat')
diff --git a/tempest/api/orchestration/stacks/test_neutron_resources.py b/tempest/api/orchestration/stacks/test_neutron_resources.py
index 81e6e8274..a0706ff9f 100644
--- a/tempest/api/orchestration/stacks/test_neutron_resources.py
+++ b/tempest/api/orchestration/stacks/test_neutron_resources.py
@@ -94,7 +94,6 @@ class NeutronResourcesTestJSON(base.BaseOrchestrationTest):
for resource in resources:
cls.test_resources[resource['logical_resource_id']] = resource
- @test.attr(type='gate')
@test.idempotent_id('f9e2664c-bc44-4eef-98b6-495e4f9d74b3')
def test_created_resources(self):
"""Verifies created neutron resources."""
@@ -113,7 +112,6 @@ class NeutronResourcesTestJSON(base.BaseOrchestrationTest):
self.assertEqual(resource_type, resource['resource_type'])
self.assertEqual('CREATE_COMPLETE', resource['resource_status'])
- @test.attr(type='gate')
@test.idempotent_id('c572b915-edb1-4e90-b196-c7199a6848c0')
@test.services('network')
def test_created_network(self):
@@ -126,7 +124,6 @@ class NeutronResourcesTestJSON(base.BaseOrchestrationTest):
self.assertEqual(self.neutron_basic_template['resources'][
'Network']['properties']['name'], network['name'])
- @test.attr(type='gate')
@test.idempotent_id('e8f84b96-f9d7-4684-ad5f-340203e9f2c2')
@test.services('network')
def test_created_subnet(self):
@@ -145,7 +142,6 @@ class NeutronResourcesTestJSON(base.BaseOrchestrationTest):
'Subnet']['properties']['ip_version'], subnet['ip_version'])
self.assertEqual(str(self.subnet_cidr), subnet['cidr'])
- @test.attr(type='gate')
@test.idempotent_id('96af4c7f-5069-44bc-bdcf-c0390f8a67d1')
@test.services('network')
def test_created_router(self):
@@ -159,7 +155,6 @@ class NeutronResourcesTestJSON(base.BaseOrchestrationTest):
router['external_gateway_info']['network_id'])
self.assertEqual(True, router['admin_state_up'])
- @test.attr(type='gate')
@test.idempotent_id('89f605bd-153e-43ee-a0ed-9919b63423c5')
@test.services('network')
def test_created_router_interface(self):
@@ -183,7 +178,6 @@ class NeutronResourcesTestJSON(base.BaseOrchestrationTest):
self.assertEqual(str(self.subnet_cidr.iter_hosts().next()),
router_interface_ip)
- @test.attr(type='gate')
@test.idempotent_id('75d85316-4ac2-4c0e-a1a9-edd2148fc10e')
@test.services('compute', 'network')
def test_created_server(self):
diff --git a/tempest/api/orchestration/stacks/test_non_empty_stack.py b/tempest/api/orchestration/stacks/test_non_empty_stack.py
index 5f96de327..bffc3066a 100644
--- a/tempest/api/orchestration/stacks/test_non_empty_stack.py
+++ b/tempest/api/orchestration/stacks/test_non_empty_stack.py
@@ -54,7 +54,6 @@ class StacksTestJSON(base.BaseOrchestrationTest):
self.assertEqual(expected_num, len(stacks))
return stacks
- @test.attr(type='gate')
@test.idempotent_id('065c652a-720d-4760-9132-06aedeb8e3ab')
def test_stack_list(self):
"""Created stack should be in the list of existing stacks."""
@@ -62,7 +61,6 @@ class StacksTestJSON(base.BaseOrchestrationTest):
stacks_names = map(lambda stack: stack['stack_name'], stacks)
self.assertIn(self.stack_name, stacks_names)
- @test.attr(type='gate')
@test.idempotent_id('992f96e3-41ee-4ff6-91c7-bcfb670c0919')
def test_stack_show(self):
"""Getting details about created stack should be possible."""
@@ -82,7 +80,6 @@ class StacksTestJSON(base.BaseOrchestrationTest):
self.assertEqual(self.stack_id, stack['id'])
self.assertEqual('fluffy', stack['outputs'][0]['output_key'])
- @test.attr(type='gate')
@test.idempotent_id('fe719f7a-305a-44d8-bbb5-c91e93d9da17')
def test_suspend_resume_stack(self):
"""Suspend and resume a stack."""
@@ -93,7 +90,6 @@ class StacksTestJSON(base.BaseOrchestrationTest):
self.client.wait_for_stack_status(self.stack_identifier,
'RESUME_COMPLETE')
- @test.attr(type='gate')
@test.idempotent_id('c951d55e-7cce-4c1f-83a0-bad735437fa6')
def test_list_resources(self):
"""Getting list of created resources for the stack should be possible.
@@ -101,7 +97,6 @@ class StacksTestJSON(base.BaseOrchestrationTest):
resources = self.list_resources(self.stack_identifier)
self.assertEqual({self.resource_name: self.resource_type}, resources)
- @test.attr(type='gate')
@test.idempotent_id('2aba03b3-392f-4237-900b-1f5a5e9bd962')
def test_show_resource(self):
"""Getting details about created resource should be possible."""
@@ -116,7 +111,6 @@ class StacksTestJSON(base.BaseOrchestrationTest):
self.assertEqual(self.resource_name, resource['logical_resource_id'])
self.assertEqual(self.resource_type, resource['resource_type'])
- @test.attr(type='gate')
@test.idempotent_id('898070a9-eba5-4fae-b7d6-cf3ffa03090f')
def test_resource_metadata(self):
"""Getting metadata for created resources should be possible."""
@@ -126,7 +120,6 @@ class StacksTestJSON(base.BaseOrchestrationTest):
self.assertIsInstance(metadata, dict)
self.assertEqual(['Tom', 'Stinky'], metadata.get('kittens', None))
- @test.attr(type='gate')
@test.idempotent_id('46567533-0a7f-483b-8942-fa19e0f17839')
def test_list_events(self):
"""Getting list of created events for the stack should be possible."""
@@ -142,7 +135,6 @@ class StacksTestJSON(base.BaseOrchestrationTest):
self.assertIn('CREATE_IN_PROGRESS', resource_statuses)
self.assertIn('CREATE_COMPLETE', resource_statuses)
- @test.attr(type='gate')
@test.idempotent_id('92465723-1673-400a-909d-4773757a3f21')
def test_show_event(self):
"""Getting details about an event should be possible."""
diff --git a/tempest/api/orchestration/stacks/test_nova_keypair_resources.py b/tempest/api/orchestration/stacks/test_nova_keypair_resources.py
index acdd4c716..c79c3c3cf 100644
--- a/tempest/api/orchestration/stacks/test_nova_keypair_resources.py
+++ b/tempest/api/orchestration/stacks/test_nova_keypair_resources.py
@@ -49,7 +49,6 @@ class NovaKeyPairResourcesYAMLTest(base.BaseOrchestrationTest):
for resource in resources:
cls.test_resources[resource['logical_resource_id']] = resource
- @test.attr(type='gate')
@test.idempotent_id('b476eac2-a302-4815-961f-18c410a2a537')
def test_created_resources(self):
"""Verifies created keypair resource."""
@@ -70,7 +69,6 @@ class NovaKeyPairResourcesYAMLTest(base.BaseOrchestrationTest):
self.assertEqual(resource_type, resource['resource_type'])
self.assertEqual('CREATE_COMPLETE', resource['resource_status'])
- @test.attr(type='gate')
@test.idempotent_id('8d77dec7-91fd-45a6-943d-5abd45e338a4')
def test_stack_keypairs_output(self):
stack = self.client.show_stack(self.stack_name)
diff --git a/tempest/api/orchestration/stacks/test_swift_resources.py b/tempest/api/orchestration/stacks/test_swift_resources.py
index 6884c6b18..d4fd3f9d5 100644
--- a/tempest/api/orchestration/stacks/test_swift_resources.py
+++ b/tempest/api/orchestration/stacks/test_swift_resources.py
@@ -16,7 +16,6 @@
from tempest_lib.common.utils import data_utils
from tempest.api.orchestration import base
-from tempest import clients
from tempest import config
from tempest import test
@@ -32,11 +31,6 @@ class SwiftResourcesTestJSON(base.BaseOrchestrationTest):
raise cls.skipException("Swift support is required")
@classmethod
- def setup_credentials(cls):
- super(SwiftResourcesTestJSON, cls).setup_credentials()
- cls.os = clients.Manager()
-
- @classmethod
def setup_clients(cls):
super(SwiftResourcesTestJSON, cls).setup_clients()
cls.account_client = cls.os.account_client
diff --git a/tempest/api/orchestration/stacks/test_templates.py b/tempest/api/orchestration/stacks/test_templates.py
index 8c07adeb0..5ccfdfb76 100644
--- a/tempest/api/orchestration/stacks/test_templates.py
+++ b/tempest/api/orchestration/stacks/test_templates.py
@@ -36,13 +36,11 @@ Resources:
cls.stack_id = cls.stack_identifier.split('/')[1]
cls.parameters = {}
- @test.attr(type='gate')
@test.idempotent_id('47430699-c368-495e-a1db-64c26fd967d7')
def test_show_template(self):
"""Getting template used to create the stack."""
self.client.show_template(self.stack_identifier)
- @test.attr(type='gate')
@test.idempotent_id('ed53debe-8727-46c5-ab58-eba6090ec4de')
def test_validate_template(self):
"""Validating template passing it content."""
diff --git a/tempest/api/orchestration/stacks/test_templates_negative.py b/tempest/api/orchestration/stacks/test_templates_negative.py
index ebba69464..4bd0f333b 100644
--- a/tempest/api/orchestration/stacks/test_templates_negative.py
+++ b/tempest/api/orchestration/stacks/test_templates_negative.py
@@ -35,7 +35,7 @@ Resources:
super(TemplateYAMLNegativeTestJSON, cls).resource_setup()
cls.parameters = {}
- @test.attr(type=['gate', 'negative'])
+ @test.attr(type=['negative'])
@test.idempotent_id('5586cbca-ddc4-4152-9db8-fa1ce5fc1876')
def test_validate_template_url(self):
"""Validating template passing url to it."""
diff --git a/tempest/api/orchestration/stacks/test_volumes.py b/tempest/api/orchestration/stacks/test_volumes.py
index 2b1ec12b5..f40ca0244 100644
--- a/tempest/api/orchestration/stacks/test_volumes.py
+++ b/tempest/api/orchestration/stacks/test_volumes.py
@@ -54,7 +54,6 @@ class CinderResourcesTest(base.BaseOrchestrationTest):
self.assertEqual(template['resources']['volume']['properties'][
'name'], self.get_stack_output(stack_identifier, 'display_name'))
- @test.attr(type='gate')
@test.idempotent_id('c3243329-7bdd-4730-b402-4d19d50c41d8')
@test.services('volume')
def test_cinder_volume_create_delete(self):
@@ -84,7 +83,6 @@ class CinderResourcesTest(base.BaseOrchestrationTest):
self.volumes_client.delete_volume(volume_id)
self.volumes_client.wait_for_resource_deletion(volume_id)
- @test.attr(type='gate')
@test.idempotent_id('ea8b3a46-b932-4c18-907a-fe23f00b33f8')
@test.services('volume')
def test_cinder_volume_create_delete_retain(self):
diff --git a/tempest/api/telemetry/base.py b/tempest/api/telemetry/base.py
index ed719c2b9..43180e5dd 100644
--- a/tempest/api/telemetry/base.py
+++ b/tempest/api/telemetry/base.py
@@ -27,6 +27,8 @@ class BaseTelemetryTest(tempest.test.BaseTestCase):
"""Base test case class for all Telemetry API tests."""
+ credentials = ['primary']
+
@classmethod
def skip_checks(cls):
super(BaseTelemetryTest, cls).skip_checks()
@@ -37,7 +39,6 @@ class BaseTelemetryTest(tempest.test.BaseTestCase):
def setup_credentials(cls):
cls.set_network_resources()
super(BaseTelemetryTest, cls).setup_credentials()
- cls.os = cls.get_client_manager()
@classmethod
def setup_clients(cls):
diff --git a/tempest/api/telemetry/test_telemetry_alarming_api.py b/tempest/api/telemetry/test_telemetry_alarming_api.py
index 8bc97e8da..99b5c37cb 100644
--- a/tempest/api/telemetry/test_telemetry_alarming_api.py
+++ b/tempest/api/telemetry/test_telemetry_alarming_api.py
@@ -29,7 +29,6 @@ class TelemetryAlarmingAPITestJSON(base.BaseTelemetryTest):
for i in range(2):
cls.create_alarm(threshold_rule=cls.rule)
- @test.attr(type="gate")
@test.idempotent_id('1c918e06-210b-41eb-bd45-14676dd77cd6')
def test_alarm_list(self):
# List alarms
@@ -43,7 +42,6 @@ class TelemetryAlarmingAPITestJSON(base.BaseTelemetryTest):
" in a fetched list: %s" %
', '.join(str(a) for a in missing_alarms))
- @test.attr(type="gate")
@test.idempotent_id('1297b095-39c1-4e74-8a1f-4ae998cedd67')
def test_create_update_get_delete_alarm(self):
# Create an alarm
@@ -67,15 +65,14 @@ class TelemetryAlarmingAPITestJSON(base.BaseTelemetryTest):
self.assertEqual(alarm_name, body['name'])
self.assertDictContainsSubset(new_rule, body['threshold_rule'])
# Get and verify details of an alarm after update
- body = self.telemetry_client.get_alarm(alarm_id)
+ body = self.telemetry_client.show_alarm(alarm_id)
self.assertEqual(alarm_name, body['name'])
self.assertDictContainsSubset(new_rule, body['threshold_rule'])
# Delete alarm and verify if deleted
self.telemetry_client.delete_alarm(alarm_id)
self.assertRaises(lib_exc.NotFound,
- self.telemetry_client.get_alarm, alarm_id)
+ self.telemetry_client.show_alarm, alarm_id)
- @test.attr(type="gate")
@test.idempotent_id('aca49486-70bb-4016-87e0-f6131374f741')
def test_set_get_alarm_state(self):
alarm_states = ['ok', 'alarm', 'insufficient data']
@@ -87,10 +84,9 @@ class TelemetryAlarmingAPITestJSON(base.BaseTelemetryTest):
new_state)
self.assertEqual(new_state, state.data)
# Get alarm state and verify
- state = self.telemetry_client.alarm_get_state(alarm['alarm_id'])
+ state = self.telemetry_client.show_alarm_state(alarm['alarm_id'])
self.assertEqual(new_state, state.data)
- @test.attr(type="gate")
@test.idempotent_id('08d7e45a-1344-4e5c-ba6f-f6cbb77f55b9')
def test_create_delete_alarm_with_combination_rule(self):
rule = {"alarm_ids": self.alarm_ids,
@@ -106,4 +102,4 @@ class TelemetryAlarmingAPITestJSON(base.BaseTelemetryTest):
# Verify alarm delete
self.telemetry_client.delete_alarm(alarm_id)
self.assertRaises(lib_exc.NotFound,
- self.telemetry_client.get_alarm, alarm_id)
+ self.telemetry_client.show_alarm, alarm_id)
diff --git a/tempest/api/telemetry/test_telemetry_notification_api.py b/tempest/api/telemetry/test_telemetry_notification_api.py
index 6862401d6..73a5fd4d8 100644
--- a/tempest/api/telemetry/test_telemetry_notification_api.py
+++ b/tempest/api/telemetry/test_telemetry_notification_api.py
@@ -29,7 +29,6 @@ class TelemetryNotificationAPITestJSON(base.BaseTelemetryTest):
raise cls.skipException("Ceilometer feature for fast work mysql "
"is disabled")
- @test.attr(type="gate")
@test.idempotent_id('d7f8c1c8-d470-4731-8604-315d3956caad')
@testtools.skipIf(not CONF.service_available.nova,
"Nova is not available.")
diff --git a/tempest/api/volume/admin/test_multi_backend.py b/tempest/api/volume/admin/test_multi_backend.py
index db2d14342..787d58e4b 100644
--- a/tempest/api/volume/admin/test_multi_backend.py
+++ b/tempest/api/volume/admin/test_multi_backend.py
@@ -114,7 +114,6 @@ class VolumeMultiBackendV2Test(base.BaseVolumeAdminTest):
volume_id = self.volume_id_list_with_prefix[0]
self._test_backend_name_reporting_by_volume_id(volume_id)
- @test.attr(type='gate')
@test.idempotent_id('46435ab1-a0af-4401-8373-f14e66b0dd58')
def test_backend_name_distinction(self):
if self.backend1_name == self.backend2_name:
@@ -124,7 +123,6 @@ class VolumeMultiBackendV2Test(base.BaseVolumeAdminTest):
volume2_id = self.volume_id_list_without_prefix[1]
self._test_backend_name_distinction(volume1_id, volume2_id)
- @test.attr(type='gate')
@test.idempotent_id('4236305b-b65a-4bfc-a9d2-69cb5b2bf2ed')
def test_backend_name_distinction_with_prefix(self):
if self.backend1_name == self.backend2_name:
diff --git a/tempest/api/volume/admin/test_snapshots_actions.py b/tempest/api/volume/admin/test_snapshots_actions.py
index d6e3f3e71..b885f7dc1 100644
--- a/tempest/api/volume/admin/test_snapshots_actions.py
+++ b/tempest/api/volume/admin/test_snapshots_actions.py
@@ -81,7 +81,6 @@ class SnapshotsActionsV2Test(base.BaseVolumeAdminTest):
def _get_progress_alias(self):
return 'os-extended-snapshot-attributes:progress'
- @test.attr(type='gate')
@test.idempotent_id('3e13ca2f-48ea-49f3-ae1a-488e9180d535')
def test_reset_snapshot_status(self):
# Reset snapshot status to creating
@@ -92,7 +91,6 @@ class SnapshotsActionsV2Test(base.BaseVolumeAdminTest):
= self.admin_snapshots_client.show_snapshot(self.snapshot['id'])
self.assertEqual(status, snapshot_get['status'])
- @test.attr(type='gate')
@test.idempotent_id('41288afd-d463-485e-8f6e-4eea159413eb')
def test_update_snapshot_status(self):
# Reset snapshot status to creating
@@ -111,25 +109,21 @@ class SnapshotsActionsV2Test(base.BaseVolumeAdminTest):
self.assertEqual(status, snapshot_get['status'])
self.assertEqual(progress, snapshot_get[progress_alias])
- @test.attr(type='gate')
@test.idempotent_id('05f711b6-e629-4895-8103-7ca069f2073a')
def test_snapshot_force_delete_when_snapshot_is_creating(self):
# test force delete when status of snapshot is creating
self._create_reset_and_force_delete_temp_snapshot('creating')
- @test.attr(type='gate')
@test.idempotent_id('92ce8597-b992-43a1-8868-6316b22a969e')
def test_snapshot_force_delete_when_snapshot_is_deleting(self):
# test force delete when status of snapshot is deleting
self._create_reset_and_force_delete_temp_snapshot('deleting')
- @test.attr(type='gate')
@test.idempotent_id('645a4a67-a1eb-4e8e-a547-600abac1525d')
def test_snapshot_force_delete_when_snapshot_is_error(self):
# test force delete when status of snapshot is error
self._create_reset_and_force_delete_temp_snapshot('error')
- @test.attr(type='gate')
@test.idempotent_id('bf89080f-8129-465e-9327-b2f922666ba5')
def test_snapshot_force_delete_when_snapshot_is_error_deleting(self):
# test force delete when status of snapshot is error_deleting
diff --git a/tempest/api/volume/admin/test_volume_hosts.py b/tempest/api/volume/admin/test_volume_hosts.py
index 551dc6fb9..dd14d8cb6 100644
--- a/tempest/api/volume/admin/test_volume_hosts.py
+++ b/tempest/api/volume/admin/test_volume_hosts.py
@@ -19,7 +19,6 @@ from tempest import test
class VolumeHostsAdminV2TestsJSON(base.BaseVolumeAdminTest):
- @test.attr(type='gate')
@test.idempotent_id('d5f3efa2-6684-4190-9ced-1c2f526352ad')
def test_list_hosts(self):
hosts = self.hosts_client.list_hosts()
diff --git a/tempest/api/volume/admin/test_volume_quotas.py b/tempest/api/volume/admin/test_volume_quotas.py
index 3ec321942..814b46d19 100644
--- a/tempest/api/volume/admin/test_volume_quotas.py
+++ b/tempest/api/volume/admin/test_volume_quotas.py
@@ -27,16 +27,14 @@ class BaseVolumeQuotasAdminV2TestJSON(base.BaseVolumeAdminTest):
@classmethod
def setup_credentials(cls):
super(BaseVolumeQuotasAdminV2TestJSON, cls).setup_credentials()
- cls.demo_tenant_id = cls.isolated_creds.get_primary_creds().tenant_id
+ cls.demo_tenant_id = cls.os.credentials.tenant_id
- @test.attr(type='gate')
@test.idempotent_id('59eada70-403c-4cef-a2a3-a8ce2f1b07a0')
def test_list_quotas(self):
quotas = self.quotas_client.show_quota_set(self.demo_tenant_id)
for key in QUOTA_KEYS:
self.assertIn(key, quotas)
- @test.attr(type='gate')
@test.idempotent_id('2be020a2-5fdd-423d-8d35-a7ffbc36e9f7')
def test_list_default_quotas(self):
quotas = self.quotas_client.show_default_quota_set(
@@ -44,7 +42,6 @@ class BaseVolumeQuotasAdminV2TestJSON(base.BaseVolumeAdminTest):
for key in QUOTA_KEYS:
self.assertIn(key, quotas)
- @test.attr(type='gate')
@test.idempotent_id('3d45c99e-cc42-4424-a56e-5cbd212b63a6')
def test_update_all_quota_resources_for_tenant(self):
# Admin can update all the resource quota limits for a tenant
@@ -69,7 +66,6 @@ class BaseVolumeQuotasAdminV2TestJSON(base.BaseVolumeAdminTest):
# would be no other values in there.
self.assertDictContainsSubset(new_quota_set, quota_set)
- @test.attr(type='gate')
@test.idempotent_id('18c51ae9-cb03-48fc-b234-14a19374dbed')
def test_show_quota_usage(self):
quota_usage = self.quotas_client.show_quota_usage(
@@ -79,7 +75,6 @@ class BaseVolumeQuotasAdminV2TestJSON(base.BaseVolumeAdminTest):
for usage_key in QUOTA_USAGE_KEYS:
self.assertIn(usage_key, quota_usage[key])
- @test.attr(type='gate')
@test.idempotent_id('ae8b6091-48ad-4bfa-a188-bbf5cc02115f')
def test_quota_usage(self):
quota_usage = self.quotas_client.show_quota_usage(
@@ -99,7 +94,6 @@ class BaseVolumeQuotasAdminV2TestJSON(base.BaseVolumeAdminTest):
volume["size"],
new_quota_usage['gigabytes']['in_use'])
- @test.attr(type='gate')
@test.idempotent_id('874b35a9-51f1-4258-bec5-cd561b6690d3')
def test_delete_quota(self):
# Admin can delete the resource quota set for a tenant
diff --git a/tempest/api/volume/admin/test_volume_quotas_negative.py b/tempest/api/volume/admin/test_volume_quotas_negative.py
index d7287f036..d1a6db0f4 100644
--- a/tempest/api/volume/admin/test_volume_quotas_negative.py
+++ b/tempest/api/volume/admin/test_volume_quotas_negative.py
@@ -25,8 +25,7 @@ class BaseVolumeQuotasNegativeV2TestJSON(base.BaseVolumeAdminTest):
@classmethod
def setup_credentials(cls):
super(BaseVolumeQuotasNegativeV2TestJSON, cls).setup_credentials()
- cls.demo_user = cls.isolated_creds.get_primary_creds()
- cls.demo_tenant_id = cls.demo_user.tenant_id
+ cls.demo_tenant_id = cls.os.credentials.tenant_id
@classmethod
def resource_setup(cls):
diff --git a/tempest/api/volume/admin/test_volume_services.py b/tempest/api/volume/admin/test_volume_services.py
index cc4f1a0c4..4f80a3147 100644
--- a/tempest/api/volume/admin/test_volume_services.py
+++ b/tempest/api/volume/admin/test_volume_services.py
@@ -30,13 +30,11 @@ class VolumesServicesV2TestJSON(base.BaseVolumeAdminTest):
cls.host_name = cls.services[0]['host']
cls.binary_name = cls.services[0]['binary']
- @test.attr(type='gate')
@test.idempotent_id('e0218299-0a59-4f43-8b2b-f1c035b3d26d')
def test_list_services(self):
services = self.admin_volume_services_client.list_services()
self.assertNotEqual(0, len(services))
- @test.attr(type='gate')
@test.idempotent_id('63a3e1ca-37ee-4983-826d-83276a370d25')
def test_get_service_by_service_binary_name(self):
params = {'binary': self.binary_name}
@@ -45,7 +43,6 @@ class VolumesServicesV2TestJSON(base.BaseVolumeAdminTest):
for service in services:
self.assertEqual(self.binary_name, service['binary'])
- @test.attr(type='gate')
@test.idempotent_id('178710e4-7596-4e08-9333-745cb8bc4f8d')
def test_get_service_by_host_name(self):
services_on_host = [service for service in self.services if
@@ -62,7 +59,6 @@ class VolumesServicesV2TestJSON(base.BaseVolumeAdminTest):
# on order.
self.assertEqual(sorted(s1), sorted(s2))
- @test.attr(type='gate')
@test.idempotent_id('ffa6167c-4497-4944-a464-226bbdb53908')
def test_get_service_by_service_and_host_name(self):
params = {'host': self.host_name, 'binary': self.binary_name}
diff --git a/tempest/api/volume/admin/test_volume_types_extra_specs.py b/tempest/api/volume/admin/test_volume_types_extra_specs.py
index 0f4dbe586..1cbba58bf 100644
--- a/tempest/api/volume/admin/test_volume_types_extra_specs.py
+++ b/tempest/api/volume/admin/test_volume_types_extra_specs.py
@@ -47,7 +47,6 @@ class VolumeTypesExtraSpecsV2Test(base.BaseVolumeAdminTest):
self.assertIsInstance(body, dict)
self.assertIn('spec1', body)
- @test.attr(type='gate')
@test.idempotent_id('0806db36-b4a0-47a1-b6f3-c2e7f194d017')
def test_volume_type_extra_specs_update(self):
# Update volume type extra specs
diff --git a/tempest/api/volume/admin/test_volume_types_extra_specs_negative.py b/tempest/api/volume/admin/test_volume_types_extra_specs_negative.py
index e861c5fe8..a70a94096 100644
--- a/tempest/api/volume/admin/test_volume_types_extra_specs_negative.py
+++ b/tempest/api/volume/admin/test_volume_types_extra_specs_negative.py
@@ -38,7 +38,6 @@ class ExtraSpecsNegativeV2Test(base.BaseVolumeAdminTest):
cls.volume_types_client.delete_volume_type(cls.volume_type['id'])
super(ExtraSpecsNegativeV2Test, cls).resource_cleanup()
- @test.attr(type='gate')
@test.idempotent_id('08961d20-5cbb-4910-ac0f-89ad6dbb2da1')
def test_update_no_body(self):
# Should not update volume type extra specs with no body
@@ -48,7 +47,6 @@ class ExtraSpecsNegativeV2Test(base.BaseVolumeAdminTest):
self.volume_types_client.update_volume_type_extra_specs,
self.volume_type['id'], extra_spec.keys()[0], None)
- @test.attr(type='gate')
@test.idempotent_id('25e5a0ee-89b3-4c53-8310-236f76c75365')
def test_update_nonexistent_extra_spec_id(self):
# Should not update volume type extra specs with nonexistent id.
@@ -59,7 +57,6 @@ class ExtraSpecsNegativeV2Test(base.BaseVolumeAdminTest):
self.volume_type['id'], str(uuid.uuid4()),
extra_spec)
- @test.attr(type='gate')
@test.idempotent_id('9bf7a657-b011-4aec-866d-81c496fbe5c8')
def test_update_none_extra_spec_id(self):
# Should not update volume type extra specs with none id.
@@ -69,7 +66,6 @@ class ExtraSpecsNegativeV2Test(base.BaseVolumeAdminTest):
self.volume_types_client.update_volume_type_extra_specs,
self.volume_type['id'], None, extra_spec)
- @test.attr(type='gate')
@test.idempotent_id('a77dfda2-9100-448e-9076-ed1711f4bdfc')
def test_update_multiple_extra_spec(self):
# Should not update volume type extra specs with multiple specs as
@@ -81,7 +77,6 @@ class ExtraSpecsNegativeV2Test(base.BaseVolumeAdminTest):
self.volume_type['id'], extra_spec.keys()[0],
extra_spec)
- @test.attr(type='gate')
@test.idempotent_id('49d5472c-a53d-4eab-a4d3-450c4db1c545')
def test_create_nonexistent_type_id(self):
# Should not create volume type extra spec for nonexistent volume
@@ -92,7 +87,6 @@ class ExtraSpecsNegativeV2Test(base.BaseVolumeAdminTest):
self.volume_types_client.create_volume_type_extra_specs,
str(uuid.uuid4()), extra_specs)
- @test.attr(type='gate')
@test.idempotent_id('c821bdc8-43a4-4bf4-86c8-82f3858d5f7d')
def test_create_none_body(self):
# Should not create volume type extra spec for none POST body.
@@ -101,7 +95,6 @@ class ExtraSpecsNegativeV2Test(base.BaseVolumeAdminTest):
self.volume_types_client.create_volume_type_extra_specs,
self.volume_type['id'], None)
- @test.attr(type='gate')
@test.idempotent_id('bc772c71-1ed4-4716-b945-8b5ed0f15e87')
def test_create_invalid_body(self):
# Should not create volume type extra spec for invalid POST body.
@@ -110,7 +103,6 @@ class ExtraSpecsNegativeV2Test(base.BaseVolumeAdminTest):
self.volume_types_client.create_volume_type_extra_specs,
self.volume_type['id'], ['invalid'])
- @test.attr(type='gate')
@test.idempotent_id('031cda8b-7d23-4246-8bf6-bbe73fd67074')
def test_delete_nonexistent_volume_type_id(self):
# Should not delete volume type extra spec for nonexistent
@@ -121,7 +113,6 @@ class ExtraSpecsNegativeV2Test(base.BaseVolumeAdminTest):
self.volume_types_client.delete_volume_type_extra_specs,
str(uuid.uuid4()), extra_specs.keys()[0])
- @test.attr(type='gate')
@test.idempotent_id('dee5cf0c-cdd6-4353-b70c-e847050d71fb')
def test_list_nonexistent_volume_type_id(self):
# Should not list volume type extra spec for nonexistent type id.
@@ -130,7 +121,6 @@ class ExtraSpecsNegativeV2Test(base.BaseVolumeAdminTest):
self.volume_types_client.list_volume_types_extra_specs,
str(uuid.uuid4()))
- @test.attr(type='gate')
@test.idempotent_id('9f402cbd-1838-4eb4-9554-126a6b1908c9')
def test_get_nonexistent_volume_type_id(self):
# Should not get volume type extra spec for nonexistent type id.
@@ -140,7 +130,6 @@ class ExtraSpecsNegativeV2Test(base.BaseVolumeAdminTest):
self.volume_types_client.show_volume_type_extra_specs,
str(uuid.uuid4()), extra_specs.keys()[0])
- @test.attr(type='gate')
@test.idempotent_id('c881797d-12ff-4f1a-b09d-9f6212159753')
def test_get_nonexistent_extra_spec_id(self):
# Should not get volume type extra spec for nonexistent extra spec
diff --git a/tempest/api/volume/admin/test_volume_types_negative.py b/tempest/api/volume/admin/test_volume_types_negative.py
index d9be337f7..2694b6304 100644
--- a/tempest/api/volume/admin/test_volume_types_negative.py
+++ b/tempest/api/volume/admin/test_volume_types_negative.py
@@ -23,7 +23,6 @@ from tempest import test
class VolumeTypesNegativeV2Test(base.BaseVolumeAdminTest):
- @test.attr(type='gate')
@test.idempotent_id('b48c98f2-e662-4885-9b71-032256906314')
def test_create_with_nonexistent_volume_type(self):
# Should not be able to create volume with nonexistent volume_type.
@@ -33,14 +32,12 @@ class VolumeTypesNegativeV2Test(base.BaseVolumeAdminTest):
self.assertRaises(lib_exc.NotFound,
self.volumes_client.create_volume, **params)
- @test.attr(type='gate')
@test.idempotent_id('878b4e57-faa2-4659-b0d1-ce740a06ae81')
def test_create_with_empty_name(self):
# Should not be able to create volume type with an empty name.
self.assertRaises(lib_exc.BadRequest,
self.volume_types_client.create_volume_type, '')
- @test.attr(type='gate')
@test.idempotent_id('994610d6-0476-4018-a644-a2602ef5d4aa')
def test_get_nonexistent_type_id(self):
# Should not be able to get volume type with nonexistent type id.
@@ -48,7 +45,6 @@ class VolumeTypesNegativeV2Test(base.BaseVolumeAdminTest):
self.volume_types_client.show_volume_type,
str(uuid.uuid4()))
- @test.attr(type='gate')
@test.idempotent_id('6b3926d2-7d73-4896-bc3d-e42dfd11a9f6')
def test_delete_nonexistent_type_id(self):
# Should not be able to delete volume type with nonexistent type id.
diff --git a/tempest/api/volume/admin/test_volumes_actions.py b/tempest/api/volume/admin/test_volumes_actions.py
index feb46a39e..8a30a1080 100644
--- a/tempest/api/volume/admin/test_volumes_actions.py
+++ b/tempest/api/volume/admin/test_volumes_actions.py
@@ -74,7 +74,6 @@ class VolumesActionsV2Test(base.BaseVolumeAdminTest):
self.admin_volume_client.force_delete_volume(temp_volume['id'])
self.client.wait_for_resource_deletion(temp_volume['id'])
- @test.attr(type='gate')
@test.idempotent_id('d063f96e-a2e0-4f34-8b8a-395c42de1845')
def test_volume_reset_status(self):
# test volume reset status : available->error->available
@@ -93,7 +92,6 @@ class VolumesActionsV2Test(base.BaseVolumeAdminTest):
# test force delete when status of volume is attaching
self._create_reset_and_force_delete_temp_volume('attaching')
- @test.attr(type='gate')
@test.idempotent_id('3e33a8a8-afd4-4d64-a86b-c27a185c5a4a')
def test_volume_force_delete_when_volume_is_error(self):
# test force delete when status of volume is error
diff --git a/tempest/api/volume/base.py b/tempest/api/volume/base.py
index 28676b007..7f56b1870 100644
--- a/tempest/api/volume/base.py
+++ b/tempest/api/volume/base.py
@@ -17,8 +17,6 @@ from oslo_log import log as logging
from tempest_lib.common.utils import data_utils
from tempest_lib import exceptions as lib_exc
-from tempest import clients
-from tempest.common import credentials
from tempest.common import fixed_network
from tempest import config
from tempest import exceptions
@@ -33,6 +31,7 @@ class BaseVolumeTest(tempest.test.BaseTestCase):
"""Base test case class for all Cinder API tests."""
_api_version = 2
+ credentials = ['primary']
@classmethod
def skip_checks(cls):
@@ -57,12 +56,10 @@ class BaseVolumeTest(tempest.test.BaseTestCase):
def setup_credentials(cls):
cls.set_network_resources()
super(BaseVolumeTest, cls).setup_credentials()
- cls.os = cls.get_client_manager()
@classmethod
def setup_clients(cls):
super(BaseVolumeTest, cls).setup_clients()
-
cls.servers_client = cls.os.servers_client
cls.networks_client = cls.os.networks_client
@@ -175,18 +172,7 @@ class BaseVolumeTest(tempest.test.BaseTestCase):
class BaseVolumeAdminTest(BaseVolumeTest):
"""Base test case class for all Volume Admin API tests."""
- @classmethod
- def skip_checks(cls):
- super(BaseVolumeAdminTest, cls).skip_checks()
- if not credentials.is_admin_available():
- msg = ("Missing Identity Admin API credentials in configuration.")
- raise cls.skipException(msg)
-
- @classmethod
- def setup_credentials(cls):
- super(BaseVolumeAdminTest, cls).setup_credentials()
- cls.adm_creds = cls.isolated_creds.get_admin_creds()
- cls.os_adm = clients.Manager(credentials=cls.adm_creds)
+ credentials = ['primary', 'admin']
@classmethod
def setup_clients(cls):
diff --git a/tempest/api/volume/test_availability_zone.py b/tempest/api/volume/test_availability_zone.py
index d54482152..f188fa97c 100644
--- a/tempest/api/volume/test_availability_zone.py
+++ b/tempest/api/volume/test_availability_zone.py
@@ -28,7 +28,6 @@ class AvailabilityZoneV2TestJSON(base.BaseVolumeTest):
super(AvailabilityZoneV2TestJSON, cls).setup_clients()
cls.client = cls.availability_zone_client
- @test.attr(type='gate')
@test.idempotent_id('01f1ae88-eba9-4c6b-a011-6f7ace06b725')
def test_get_availability_zone_list(self):
# List of availability zone
diff --git a/tempest/api/volume/test_extensions.py b/tempest/api/volume/test_extensions.py
index e8ff5e012..17db45f0d 100644
--- a/tempest/api/volume/test_extensions.py
+++ b/tempest/api/volume/test_extensions.py
@@ -27,7 +27,6 @@ LOG = logging.getLogger(__name__)
class ExtensionsV2TestJSON(base.BaseVolumeTest):
- @test.attr(type='gate')
@test.idempotent_id('94607eb0-43a5-47ca-82aa-736b41bd2e2c')
def test_list_extensions(self):
# List of all extensions
diff --git a/tempest/api/volume/test_snapshot_metadata.py b/tempest/api/volume/test_snapshot_metadata.py
index 536648d24..b8e87f037 100644
--- a/tempest/api/volume/test_snapshot_metadata.py
+++ b/tempest/api/volume/test_snapshot_metadata.py
@@ -38,7 +38,6 @@ class SnapshotV2MetadataTestJSON(base.BaseVolumeTest):
self.client.update_snapshot_metadata(self.snapshot_id, {})
super(SnapshotV2MetadataTestJSON, self).tearDown()
- @test.attr(type='gate')
@test.idempotent_id('a2f20f99-e363-4584-be97-bc33afb1a56c')
def test_create_get_delete_snapshot_metadata(self):
# Create metadata for the snapshot
@@ -58,7 +57,6 @@ class SnapshotV2MetadataTestJSON(base.BaseVolumeTest):
body = self.client.show_snapshot_metadata(self.snapshot_id)
self.assertEqual(expected, body)
- @test.attr(type='gate')
@test.idempotent_id('bd2363bc-de92-48a4-bc98-28943c6e4be1')
def test_update_snapshot_metadata(self):
# Update metadata for the snapshot
@@ -80,7 +78,6 @@ class SnapshotV2MetadataTestJSON(base.BaseVolumeTest):
body = self.client.show_snapshot_metadata(self.snapshot_id)
self.assertEqual(update, body)
- @test.attr(type='gate')
@test.idempotent_id('e8ff85c5-8f97-477f-806a-3ac364a949ed')
def test_update_snapshot_metadata_item(self):
# Update metadata item for the snapshot
diff --git a/tempest/api/volume/test_volume_metadata.py b/tempest/api/volume/test_volume_metadata.py
index a0e116176..e89ff9a04 100644
--- a/tempest/api/volume/test_volume_metadata.py
+++ b/tempest/api/volume/test_volume_metadata.py
@@ -33,7 +33,6 @@ class VolumesV2MetadataTest(base.BaseVolumeTest):
self.volumes_client.update_volume_metadata(self.volume_id, {})
super(VolumesV2MetadataTest, self).tearDown()
- @test.attr(type='gate')
@test.idempotent_id('6f5b125b-f664-44bf-910f-751591fe5769')
def test_create_get_delete_volume_metadata(self):
# Create metadata for the volume
@@ -55,7 +54,6 @@ class VolumesV2MetadataTest(base.BaseVolumeTest):
del metadata["key1"]
self.assertThat(body.items(), matchers.ContainsAll(metadata.items()))
- @test.attr(type='gate')
@test.idempotent_id('774d2918-9beb-4f30-b3d1-2a4e8179ec0a')
def test_update_volume_metadata(self):
# Update metadata for the volume
@@ -79,7 +77,6 @@ class VolumesV2MetadataTest(base.BaseVolumeTest):
body = self.volumes_client.show_volume_metadata(self.volume_id)
self.assertThat(body.items(), matchers.ContainsAll(update.items()))
- @test.attr(type='gate')
@test.idempotent_id('862261c5-8df4-475a-8c21-946e50e36a20')
def test_update_volume_metadata_item(self):
# Update metadata item for the volume
diff --git a/tempest/api/volume/test_volume_transfers.py b/tempest/api/volume/test_volume_transfers.py
index 4acab39e6..27f811209 100644
--- a/tempest/api/volume/test_volume_transfers.py
+++ b/tempest/api/volume/test_volume_transfers.py
@@ -16,8 +16,6 @@
from testtools import matchers
from tempest.api.volume import base
-from tempest import clients
-from tempest.common import credentials
from tempest import config
from tempest import test
@@ -26,21 +24,7 @@ CONF = config.CONF
class VolumesV2TransfersTest(base.BaseVolumeTest):
- @classmethod
- def skip_checks(cls):
- super(VolumesV2TransfersTest, cls).skip_checks()
- if not credentials.is_admin_available():
- msg = "Missing Volume Admin API credentials in configuration."
- raise cls.skipException(msg)
-
- @classmethod
- def setup_credentials(cls):
- super(VolumesV2TransfersTest, cls).setup_credentials()
- # Add another tenant to test volume-transfer
- cls.os_alt = clients.Manager(cls.isolated_creds.get_alt_creds())
- # Add admin tenant to cleanup resources
- creds = cls.isolated_creds.get_admin_creds()
- cls.os_adm = clients.Manager(credentials=creds)
+ credentials = ['primary', 'alt', 'admin']
@classmethod
def setup_clients(cls):
@@ -56,7 +40,6 @@ class VolumesV2TransfersTest(base.BaseVolumeTest):
self.adm_client.delete_volume(volume_id)
self.adm_client.wait_for_resource_deletion(volume_id)
- @test.attr(type='gate')
@test.idempotent_id('4d75b645-a478-48b1-97c8-503f64242f1a')
def test_create_get_list_accept_volume_transfer(self):
# Create a volume first
diff --git a/tempest/api/volume/test_volumes_actions.py b/tempest/api/volume/test_volumes_actions.py
index fecb98b85..f571f2d16 100644
--- a/tempest/api/volume/test_volumes_actions.py
+++ b/tempest/api/volume/test_volumes_actions.py
@@ -71,7 +71,6 @@ class VolumesV2ActionsTest(base.BaseVolumeTest):
@test.idempotent_id('9516a2c8-9135-488c-8dd6-5677a7e5f371')
@test.stresstest(class_setup_per='process')
- @test.attr(type='gate')
@test.services('compute')
def test_get_volume_attachment(self):
# Verify that a volume's attachment information is retrieved
@@ -94,7 +93,6 @@ class VolumesV2ActionsTest(base.BaseVolumeTest):
self.assertEqual(self.volume['id'], attachment['id'])
self.assertEqual(self.volume['id'], attachment['volume_id'])
- @test.attr(type='gate')
@test.idempotent_id('d8f1ca95-3d5b-44a3-b8ca-909691c9532d')
@test.services('image')
def test_volume_upload(self):
@@ -111,7 +109,6 @@ class VolumesV2ActionsTest(base.BaseVolumeTest):
self.image_client.wait_for_image_status(image_id, 'active')
self.client.wait_for_volume_status(self.volume['id'], 'available')
- @test.attr(type='gate')
@test.idempotent_id('92c4ef64-51b2-40c0-9f7e-4749fbaaba33')
def test_reserve_unreserve_volume(self):
# Mark volume as reserved.
@@ -128,7 +125,6 @@ class VolumesV2ActionsTest(base.BaseVolumeTest):
def _is_true(self, val):
return val in ['true', 'True', True]
- @test.attr(type='gate')
@test.idempotent_id('fff74e1e-5bd3-4b33-9ea9-24c103bc3f59')
def test_volume_readonly_update(self):
# Update volume readonly true
diff --git a/tempest/api/volume/test_volumes_extend.py b/tempest/api/volume/test_volumes_extend.py
index 38bb748e1..179f8d350 100644
--- a/tempest/api/volume/test_volumes_extend.py
+++ b/tempest/api/volume/test_volumes_extend.py
@@ -27,7 +27,6 @@ class VolumesV2ExtendTest(base.BaseVolumeTest):
super(VolumesV2ExtendTest, cls).setup_clients()
cls.client = cls.volumes_client
- @test.attr(type='gate')
@test.idempotent_id('9a36df71-a257-43a5-9555-dc7c88e66e0e')
def test_volume_extend(self):
# Extend Volume Test.
diff --git a/tempest/api/volume/test_volumes_get.py b/tempest/api/volume/test_volumes_get.py
index 1027f483f..8337f8df9 100644
--- a/tempest/api/volume/test_volumes_get.py
+++ b/tempest/api/volume/test_volumes_get.py
@@ -133,7 +133,6 @@ class VolumesV2GetTest(base.BaseVolumeTest):
def test_volume_create_get_update_delete_from_image(self):
self._volume_create_get_update_delete(imageRef=CONF.compute.image_ref)
- @test.attr(type='gate')
@test.idempotent_id('3f591b4a-7dc6-444c-bd51-77469506b3a1')
def test_volume_create_get_update_delete_as_clone(self):
origin = self.create_volume()
diff --git a/tempest/api/volume/test_volumes_list.py b/tempest/api/volume/test_volumes_list.py
index 1c7b1c86e..da0d5aaaa 100644
--- a/tempest/api/volume/test_volumes_list.py
+++ b/tempest/api/volume/test_volumes_list.py
@@ -120,7 +120,6 @@ class VolumesV2ListTestJSON(base.BaseVolumeTest):
self.assertVolumesIn(fetched_list, self.volume_list,
fields=self.VOLUME_FIELDS)
- @test.attr(type='gate')
@test.idempotent_id('adcbb5a7-5ad8-4b61-bd10-5380e111a877')
def test_volume_list_with_details(self):
# Get a list of Volumes with details
@@ -128,7 +127,6 @@ class VolumesV2ListTestJSON(base.BaseVolumeTest):
fetched_list = self.client.list_volumes(detail=True)
self.assertVolumesIn(fetched_list, self.volume_list)
- @test.attr(type='gate')
@test.idempotent_id('a28e8da4-0b56-472f-87a8-0f4d3f819c02')
def test_volume_list_by_name(self):
volume = self.volume_list[data_utils.rand_int_id(0, 2)]
@@ -138,7 +136,6 @@ class VolumesV2ListTestJSON(base.BaseVolumeTest):
self.assertEqual(fetched_vol[0][self.name],
volume[self.name])
- @test.attr(type='gate')
@test.idempotent_id('2de3a6d4-12aa-403b-a8f2-fdeb42a89623')
def test_volume_list_details_by_name(self):
volume = self.volume_list[data_utils.rand_int_id(0, 2)]
@@ -148,7 +145,6 @@ class VolumesV2ListTestJSON(base.BaseVolumeTest):
self.assertEqual(fetched_vol[0][self.name],
volume[self.name])
- @test.attr(type='gate')
@test.idempotent_id('39654e13-734c-4dab-95ce-7613bf8407ce')
def test_volumes_list_by_status(self):
params = {'status': 'available'}
@@ -157,7 +153,6 @@ class VolumesV2ListTestJSON(base.BaseVolumeTest):
self.assertVolumesIn(fetched_list, self.volume_list,
fields=self.VOLUME_FIELDS)
- @test.attr(type='gate')
@test.idempotent_id('2943f712-71ec-482a-bf49-d5ca06216b9f')
def test_volumes_list_details_by_status(self):
params = {'status': 'available'}
@@ -166,7 +161,6 @@ class VolumesV2ListTestJSON(base.BaseVolumeTest):
self.assertEqual('available', volume['status'])
self.assertVolumesIn(fetched_list, self.volume_list)
- @test.attr(type='gate')
@test.idempotent_id('c0cfa863-3020-40d7-b587-e35f597d5d87')
def test_volumes_list_by_availability_zone(self):
volume = self.volume_list[data_utils.rand_int_id(0, 2)]
@@ -177,7 +171,6 @@ class VolumesV2ListTestJSON(base.BaseVolumeTest):
self.assertVolumesIn(fetched_list, self.volume_list,
fields=self.VOLUME_FIELDS)
- @test.attr(type='gate')
@test.idempotent_id('e1b80d13-94f0-4ba2-a40e-386af29f8db1')
def test_volumes_list_details_by_availability_zone(self):
volume = self.volume_list[data_utils.rand_int_id(0, 2)]
@@ -188,21 +181,18 @@ class VolumesV2ListTestJSON(base.BaseVolumeTest):
self.assertEqual(zone, volume['availability_zone'])
self.assertVolumesIn(fetched_list, self.volume_list)
- @test.attr(type='gate')
@test.idempotent_id('b5ebea1b-0603-40a0-bb41-15fcd0a53214')
def test_volume_list_with_param_metadata(self):
# Test to list volumes when metadata param is given
params = {'metadata': self.metadata}
self._list_by_param_value_and_assert(params)
- @test.attr(type='gate')
@test.idempotent_id('1ca92d3c-4a8e-4b43-93f5-e4c7fb3b291d')
def test_volume_list_with_detail_param_metadata(self):
# Test to list volumes details when metadata param is given
params = {'metadata': self.metadata}
self._list_by_param_value_and_assert(params, with_detail=True)
- @test.attr(type='gate')
@test.idempotent_id('777c87c1-2fc4-4883-8b8e-5c0b951d1ec8')
def test_volume_list_param_display_name_and_status(self):
# Test to list volume when display name and status param is given
@@ -211,7 +201,6 @@ class VolumesV2ListTestJSON(base.BaseVolumeTest):
'status': 'available'}
self._list_by_param_value_and_assert(params)
- @test.attr(type='gate')
@test.idempotent_id('856ab8ca-6009-4c37-b691-be1065528ad4')
def test_volume_list_with_detail_param_display_name_and_status(self):
# Test to list volume when name and status param is given
diff --git a/tempest/api/volume/test_volumes_negative.py b/tempest/api/volume/test_volumes_negative.py
index aba245aee..b591a1ad5 100644
--- a/tempest/api/volume/test_volumes_negative.py
+++ b/tempest/api/volume/test_volumes_negative.py
@@ -39,21 +39,21 @@ class VolumesV2NegativeTest(base.BaseVolumeTest):
cls.volume = cls.create_volume()
cls.mountpoint = "/dev/vdc"
- @test.attr(type=['negative', 'gate'])
+ @test.attr(type=['negative'])
@test.idempotent_id('f131c586-9448-44a4-a8b0-54ca838aa43e')
def test_volume_get_nonexistent_volume_id(self):
# Should not be able to get a non-existent volume
self.assertRaises(lib_exc.NotFound, self.client.show_volume,
str(uuid.uuid4()))
- @test.attr(type=['negative', 'gate'])
+ @test.attr(type=['negative'])
@test.idempotent_id('555efa6e-efcd-44ef-8a3b-4a7ca4837a29')
def test_volume_delete_nonexistent_volume_id(self):
# Should not be able to delete a non-existent Volume
self.assertRaises(lib_exc.NotFound, self.client.delete_volume,
str(uuid.uuid4()))
- @test.attr(type=['negative', 'gate'])
+ @test.attr(type=['negative'])
@test.idempotent_id('1ed83a8a-682d-4dfb-a30e-ee63ffd6c049')
def test_create_volume_with_invalid_size(self):
# Should not be able to create volume with invalid size
@@ -63,7 +63,7 @@ class VolumesV2NegativeTest(base.BaseVolumeTest):
self.assertRaises(lib_exc.BadRequest, self.client.create_volume,
size='#$%', display_name=v_name, metadata=metadata)
- @test.attr(type=['negative', 'gate'])
+ @test.attr(type=['negative'])
@test.idempotent_id('9387686f-334f-4d31-a439-33494b9e2683')
def test_create_volume_with_out_passing_size(self):
# Should not be able to create volume without passing size
@@ -73,7 +73,7 @@ class VolumesV2NegativeTest(base.BaseVolumeTest):
self.assertRaises(lib_exc.BadRequest, self.client.create_volume,
size='', display_name=v_name, metadata=metadata)
- @test.attr(type=['negative', 'gate'])
+ @test.attr(type=['negative'])
@test.idempotent_id('41331caa-eaf4-4001-869d-bc18c1869360')
def test_create_volume_with_size_zero(self):
# Should not be able to create volume with size zero
@@ -82,7 +82,7 @@ class VolumesV2NegativeTest(base.BaseVolumeTest):
self.assertRaises(lib_exc.BadRequest, self.client.create_volume,
size='0', display_name=v_name, metadata=metadata)
- @test.attr(type=['negative', 'gate'])
+ @test.attr(type=['negative'])
@test.idempotent_id('8b472729-9eba-446e-a83b-916bdb34bef7')
def test_create_volume_with_size_negative(self):
# Should not be able to create volume with size negative
@@ -91,7 +91,7 @@ class VolumesV2NegativeTest(base.BaseVolumeTest):
self.assertRaises(lib_exc.BadRequest, self.client.create_volume,
size='-1', display_name=v_name, metadata=metadata)
- @test.attr(type=['negative', 'gate'])
+ @test.attr(type=['negative'])
@test.idempotent_id('10254ed8-3849-454e-862e-3ab8e6aa01d2')
def test_create_volume_with_nonexistent_volume_type(self):
# Should not be able to create volume with non-existent volume type
@@ -101,7 +101,7 @@ class VolumesV2NegativeTest(base.BaseVolumeTest):
size='1', volume_type=str(uuid.uuid4()),
display_name=v_name, metadata=metadata)
- @test.attr(type=['negative', 'gate'])
+ @test.attr(type=['negative'])
@test.idempotent_id('0c36f6ae-4604-4017-b0a9-34fdc63096f9')
def test_create_volume_with_nonexistent_snapshot_id(self):
# Should not be able to create volume with non-existent snapshot
@@ -111,7 +111,7 @@ class VolumesV2NegativeTest(base.BaseVolumeTest):
size='1', snapshot_id=str(uuid.uuid4()),
display_name=v_name, metadata=metadata)
- @test.attr(type=['negative', 'gate'])
+ @test.attr(type=['negative'])
@test.idempotent_id('47c73e08-4be8-45bb-bfdf-0c4e79b88344')
def test_create_volume_with_nonexistent_source_volid(self):
# Should not be able to create volume with non-existent source volume
@@ -121,7 +121,7 @@ class VolumesV2NegativeTest(base.BaseVolumeTest):
size='1', source_volid=str(uuid.uuid4()),
display_name=v_name, metadata=metadata)
- @test.attr(type=['negative', 'gate'])
+ @test.attr(type=['negative'])
@test.idempotent_id('0186422c-999a-480e-a026-6a665744c30c')
def test_update_volume_with_nonexistent_volume_id(self):
v_name = data_utils.rand_name('Volume')
@@ -130,7 +130,7 @@ class VolumesV2NegativeTest(base.BaseVolumeTest):
volume_id=str(uuid.uuid4()), display_name=v_name,
metadata=metadata)
- @test.attr(type=['negative', 'gate'])
+ @test.attr(type=['negative'])
@test.idempotent_id('e66e40d6-65e6-4e75-bdc7-636792fa152d')
def test_update_volume_with_invalid_volume_id(self):
v_name = data_utils.rand_name('Volume')
@@ -139,7 +139,7 @@ class VolumesV2NegativeTest(base.BaseVolumeTest):
volume_id='#$%%&^&^', display_name=v_name,
metadata=metadata)
- @test.attr(type=['negative', 'gate'])
+ @test.attr(type=['negative'])
@test.idempotent_id('72aeca85-57a5-4c1f-9057-f320f9ea575b')
def test_update_volume_with_empty_volume_id(self):
v_name = data_utils.rand_name('Volume')
@@ -148,33 +148,33 @@ class VolumesV2NegativeTest(base.BaseVolumeTest):
volume_id='', display_name=v_name,
metadata=metadata)
- @test.attr(type=['negative', 'gate'])
+ @test.attr(type=['negative'])
@test.idempotent_id('30799cfd-7ee4-446c-b66c-45b383ed211b')
def test_get_invalid_volume_id(self):
# Should not be able to get volume with invalid id
self.assertRaises(lib_exc.NotFound, self.client.show_volume,
'#$%%&^&^')
- @test.attr(type=['negative', 'gate'])
+ @test.attr(type=['negative'])
@test.idempotent_id('c6c3db06-29ad-4e91-beb0-2ab195fe49e3')
def test_get_volume_without_passing_volume_id(self):
# Should not be able to get volume when empty ID is passed
self.assertRaises(lib_exc.NotFound, self.client.show_volume, '')
- @test.attr(type=['negative', 'gate'])
+ @test.attr(type=['negative'])
@test.idempotent_id('1f035827-7c32-4019-9240-b4ec2dbd9dfd')
def test_delete_invalid_volume_id(self):
# Should not be able to delete volume when invalid ID is passed
self.assertRaises(lib_exc.NotFound, self.client.delete_volume,
'!@#$%^&*()')
- @test.attr(type=['negative', 'gate'])
+ @test.attr(type=['negative'])
@test.idempotent_id('441a1550-5d44-4b30-af0f-a6d402f52026')
def test_delete_volume_without_passing_volume_id(self):
# Should not be able to delete volume when empty ID is passed
self.assertRaises(lib_exc.NotFound, self.client.delete_volume, '')
- @test.attr(type=['negative', 'gate'])
+ @test.attr(type=['negative'])
@test.idempotent_id('f5e56b0a-5d02-43c1-a2a7-c9b792c2e3f6')
@test.services('compute')
def test_attach_volumes_with_nonexistent_volume_id(self):
@@ -188,14 +188,14 @@ class VolumesV2NegativeTest(base.BaseVolumeTest):
server['id'],
self.mountpoint)
- @test.attr(type=['negative', 'gate'])
+ @test.attr(type=['negative'])
@test.idempotent_id('9f9c24e4-011d-46b5-b992-952140ce237a')
def test_detach_volumes_with_invalid_volume_id(self):
self.assertRaises(lib_exc.NotFound,
self.client.detach_volume,
'xxx')
- @test.attr(type=['negative', 'gate'])
+ @test.attr(type=['negative'])
@test.idempotent_id('e0c75c74-ee34-41a9-9288-2a2051452854')
def test_volume_extend_with_size_smaller_than_original_size(self):
# Extend volume with smaller size than original size.
@@ -203,7 +203,7 @@ class VolumesV2NegativeTest(base.BaseVolumeTest):
self.assertRaises(lib_exc.BadRequest, self.client.extend_volume,
self.volume['id'], extend_size)
- @test.attr(type=['negative', 'gate'])
+ @test.attr(type=['negative'])
@test.idempotent_id('5d0b480d-e833-439f-8a5a-96ad2ed6f22f')
def test_volume_extend_with_non_number_size(self):
# Extend volume when size is non number.
@@ -211,7 +211,7 @@ class VolumesV2NegativeTest(base.BaseVolumeTest):
self.assertRaises(lib_exc.BadRequest, self.client.extend_volume,
self.volume['id'], extend_size)
- @test.attr(type=['negative', 'gate'])
+ @test.attr(type=['negative'])
@test.idempotent_id('355218f1-8991-400a-a6bb-971239287d92')
def test_volume_extend_with_None_size(self):
# Extend volume with None size.
@@ -219,7 +219,7 @@ class VolumesV2NegativeTest(base.BaseVolumeTest):
self.assertRaises(lib_exc.BadRequest, self.client.extend_volume,
self.volume['id'], extend_size)
- @test.attr(type=['negative', 'gate'])
+ @test.attr(type=['negative'])
@test.idempotent_id('8f05a943-013c-4063-ac71-7baf561e82eb')
def test_volume_extend_with_nonexistent_volume_id(self):
# Extend volume size when volume is nonexistent.
@@ -227,7 +227,7 @@ class VolumesV2NegativeTest(base.BaseVolumeTest):
self.assertRaises(lib_exc.NotFound, self.client.extend_volume,
str(uuid.uuid4()), extend_size)
- @test.attr(type=['negative', 'gate'])
+ @test.attr(type=['negative'])
@test.idempotent_id('aff8ba64-6d6f-4f2e-bc33-41a08ee9f115')
def test_volume_extend_without_passing_volume_id(self):
# Extend volume size when passing volume id is None.
@@ -235,21 +235,21 @@ class VolumesV2NegativeTest(base.BaseVolumeTest):
self.assertRaises(lib_exc.NotFound, self.client.extend_volume,
None, extend_size)
- @test.attr(type=['negative', 'gate'])
+ @test.attr(type=['negative'])
@test.idempotent_id('ac6084c0-0546-45f9-b284-38a367e0e0e2')
def test_reserve_volume_with_nonexistent_volume_id(self):
self.assertRaises(lib_exc.NotFound,
self.client.reserve_volume,
str(uuid.uuid4()))
- @test.attr(type=['negative', 'gate'])
+ @test.attr(type=['negative'])
@test.idempotent_id('eb467654-3dc1-4a72-9b46-47c29d22654c')
def test_unreserve_volume_with_nonexistent_volume_id(self):
self.assertRaises(lib_exc.NotFound,
self.client.unreserve_volume,
str(uuid.uuid4()))
- @test.attr(type=['negative', 'gate'])
+ @test.attr(type=['negative'])
@test.idempotent_id('449c4ed2-ecdd-47bb-98dc-072aeccf158c')
def test_reserve_volume_with_negative_volume_status(self):
# Mark volume as reserved.
@@ -261,7 +261,7 @@ class VolumesV2NegativeTest(base.BaseVolumeTest):
# Unmark volume as reserved.
self.client.unreserve_volume(self.volume['id'])
- @test.attr(type=['negative', 'gate'])
+ @test.attr(type=['negative'])
@test.idempotent_id('0f4aa809-8c7b-418f-8fb3-84c7a5dfc52f')
def test_list_volumes_with_nonexistent_name(self):
v_name = data_utils.rand_name('Volume')
@@ -269,7 +269,7 @@ class VolumesV2NegativeTest(base.BaseVolumeTest):
fetched_volume = self.client.list_volumes(params=params)
self.assertEqual(0, len(fetched_volume))
- @test.attr(type=['negative', 'gate'])
+ @test.attr(type=['negative'])
@test.idempotent_id('9ca17820-a0e7-4cbd-a7fa-f4468735e359')
def test_list_volumes_detail_with_nonexistent_name(self):
v_name = data_utils.rand_name('Volume')
@@ -278,14 +278,14 @@ class VolumesV2NegativeTest(base.BaseVolumeTest):
self.client.list_volumes(detail=True, params=params)
self.assertEqual(0, len(fetched_volume))
- @test.attr(type=['negative', 'gate'])
+ @test.attr(type=['negative'])
@test.idempotent_id('143b279b-7522-466b-81be-34a87d564a7c')
def test_list_volumes_with_invalid_status(self):
params = {'status': 'null'}
fetched_volume = self.client.list_volumes(params=params)
self.assertEqual(0, len(fetched_volume))
- @test.attr(type=['negative', 'gate'])
+ @test.attr(type=['negative'])
@test.idempotent_id('ba94b27b-be3f-496c-a00e-0283b373fa75')
def test_list_volumes_detail_with_invalid_status(self):
params = {'status': 'null'}
diff --git a/tempest/api/volume/test_volumes_snapshots.py b/tempest/api/volume/test_volumes_snapshots.py
index 2c15f9281..550c3b6c6 100644
--- a/tempest/api/volume/test_volumes_snapshots.py
+++ b/tempest/api/volume/test_volumes_snapshots.py
@@ -62,7 +62,6 @@ class VolumesV2SnapshotTestJSON(base.BaseVolumeTest):
('details' if with_detail else '', key)
self.assertEqual(params[key], snap[key], msg)
- @test.attr(type='gate')
@test.idempotent_id('b467b54c-07a4-446d-a1cf-651dedcc3ff1')
@test.services('compute')
def test_snapshot_create_with_volume_in_use(self):
@@ -89,7 +88,6 @@ class VolumesV2SnapshotTestJSON(base.BaseVolumeTest):
self.snapshots_client.wait_for_resource_deletion(snapshot['id'])
self.snapshots.remove(snapshot)
- @test.attr(type='gate')
@test.idempotent_id('2a8abbe4-d871-46db-b049-c41f5af8216e')
def test_snapshot_create_get_list_update_delete(self):
# Create a snapshot
@@ -130,7 +128,6 @@ class VolumesV2SnapshotTestJSON(base.BaseVolumeTest):
self.snapshots_client.wait_for_resource_deletion(snapshot['id'])
self.snapshots.remove(snapshot)
- @test.attr(type='gate')
@test.idempotent_id('59f41f43-aebf-48a9-ab5d-d76340fab32b')
def test_snapshots_list_with_params(self):
"""list snapshots with params."""
@@ -152,7 +149,6 @@ class VolumesV2SnapshotTestJSON(base.BaseVolumeTest):
self.name_field: snapshot[self.name_field]}
self._list_by_param_values_and_assert(params)
- @test.attr(type='gate')
@test.idempotent_id('220a1022-1fcd-4a74-a7bd-6b859156cda2')
def test_snapshots_list_details_with_params(self):
"""list snapshot details with params."""
@@ -172,7 +168,6 @@ class VolumesV2SnapshotTestJSON(base.BaseVolumeTest):
self.name_field: snapshot[self.name_field]}
self._list_by_param_values_and_assert(params, with_detail=True)
- @test.attr(type='gate')
@test.idempotent_id('677863d1-3142-456d-b6ac-9924f667a7f4')
def test_volume_from_snapshot(self):
# Create a temporary snap using wrapper method from base, then
diff --git a/tempest/api/volume/test_volumes_snapshots_negative.py b/tempest/api/volume/test_volumes_snapshots_negative.py
index 6307b621e..77f8552bb 100644
--- a/tempest/api/volume/test_volumes_snapshots_negative.py
+++ b/tempest/api/volume/test_volumes_snapshots_negative.py
@@ -30,7 +30,7 @@ class VolumesV2SnapshotNegativeTestJSON(base.BaseVolumeTest):
if not CONF.volume_feature_enabled.snapshot:
raise cls.skipException("Cinder volume snapshots are disabled")
- @test.attr(type=['negative', 'gate'])
+ @test.attr(type=['negative'])
@test.idempotent_id('e3e466af-70ab-4f4b-a967-ab04e3532ea7')
def test_create_snapshot_with_nonexistent_volume_id(self):
# Create a snapshot with nonexistent volume id
@@ -39,7 +39,7 @@ class VolumesV2SnapshotNegativeTestJSON(base.BaseVolumeTest):
self.snapshots_client.create_snapshot,
str(uuid.uuid4()), display_name=s_name)
- @test.attr(type=['negative', 'gate'])
+ @test.attr(type=['negative'])
@test.idempotent_id('bb9da53e-d335-4309-9c15-7e76fd5e4d6d')
def test_create_snapshot_without_passing_volume_id(self):
# Create a snapshot without passing volume id
diff --git a/tempest/api/volume/v2/test_volumes_list.py b/tempest/api/volume/v2/test_volumes_list.py
index 04ea361f3..4c774da2e 100644
--- a/tempest/api/volume/v2/test_volumes_list.py
+++ b/tempest/api/volume/v2/test_volumes_list.py
@@ -57,7 +57,6 @@ class VolumesV2ListTestJSON(base.BaseVolumeTest):
cls.client.wait_for_resource_deletion(volid)
super(VolumesV2ListTestJSON, cls).resource_cleanup()
- @test.attr(type='gate')
@test.idempotent_id('2a7064eb-b9c3-429b-b888-33928fc5edd3')
def test_volume_list_details_with_multiple_params(self):
# List volumes detail using combined condition
diff --git a/tempest/api_schema/response/compute/servers.py b/tempest/api_schema/response/compute/servers.py
deleted file mode 100644
index 395017325..000000000
--- a/tempest/api_schema/response/compute/servers.py
+++ /dev/null
@@ -1,238 +0,0 @@
-# Copyright 2014 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.
-
-import copy
-
-from tempest.api_schema.response.compute import parameter_types
-
-get_password = {
- 'status_code': [200],
- 'response_body': {
- 'type': 'object',
- 'properties': {
- 'password': {'type': 'string'}
- },
- 'required': ['password']
- }
-}
-
-get_vnc_console = {
- 'status_code': [200],
- 'response_body': {
- 'type': 'object',
- 'properties': {
- 'console': {
- 'type': 'object',
- 'properties': {
- 'type': {'type': 'string'},
- 'url': {
- 'type': 'string',
- 'format': 'uri'
- }
- },
- 'required': ['type', 'url']
- }
- },
- 'required': ['console']
- }
-}
-
-common_show_server = {
- 'type': 'object',
- 'properties': {
- 'id': {'type': 'string'},
- 'name': {'type': 'string'},
- 'status': {'type': 'string'},
- 'image': {'oneOf': [
- {'type': 'object',
- 'properties': {
- 'id': {'type': 'string'},
- 'links': parameter_types.links
- },
- 'required': ['id', 'links']},
- {'type': ['string', 'null']}
- ]},
- 'flavor': {
- 'type': 'object',
- 'properties': {
- 'id': {'type': 'string'},
- 'links': parameter_types.links
- },
- 'required': ['id', 'links']
- },
- 'fault': {
- 'type': 'object',
- 'properties': {
- 'code': {'type': 'integer'},
- 'created': {'type': 'string'},
- 'message': {'type': 'string'},
- 'details': {'type': 'string'},
- },
- # NOTE(gmann): 'details' is not necessary to be present
- # in the 'fault'. So it is not defined as 'required'.
- 'required': ['code', 'created', 'message']
- },
- 'user_id': {'type': 'string'},
- 'tenant_id': {'type': 'string'},
- 'created': {'type': 'string'},
- 'updated': {'type': 'string'},
- 'progress': {'type': 'integer'},
- 'metadata': {'type': 'object'},
- 'links': parameter_types.links,
- 'addresses': parameter_types.addresses,
- },
- # NOTE(GMann): 'progress' attribute is present in the response
- # only when server's status is one of the progress statuses
- # ("ACTIVE","BUILD", "REBUILD", "RESIZE","VERIFY_RESIZE")
- # 'fault' attribute is present in the response
- # only when server's status is one of the "ERROR", "DELETED".
- # So they are not defined as 'required'.
- 'required': ['id', 'name', 'status', 'image', 'flavor',
- 'user_id', 'tenant_id', 'created', 'updated',
- 'metadata', 'links', 'addresses']
-}
-
-base_update_get_server = {
- 'status_code': [200],
- 'response_body': {
- 'type': 'object',
- 'properties': {
- 'server': common_show_server
- },
- 'required': ['server']
- }
-}
-
-delete_server = {
- 'status_code': [204],
-}
-
-set_server_metadata = {
- 'status_code': [200],
- 'response_body': {
- 'type': 'object',
- 'properties': {
- 'metadata': {
- 'type': 'object',
- 'patternProperties': {
- '^.+$': {'type': 'string'}
- }
- }
- },
- 'required': ['metadata']
- }
-}
-
-list_server_metadata = copy.deepcopy(set_server_metadata)
-
-update_server_metadata = copy.deepcopy(set_server_metadata)
-
-delete_server_metadata_item = {
- 'status_code': [204]
-}
-
-list_servers = {
- 'status_code': [200],
- 'response_body': {
- 'type': 'object',
- 'properties': {
- 'servers': {
- 'type': 'array',
- 'items': {
- 'type': 'object',
- 'properties': {
- 'id': {'type': 'string'},
- 'links': parameter_types.links,
- 'name': {'type': 'string'}
- },
- 'required': ['id', 'links', 'name']
- }
- },
- 'servers_links': parameter_types.links
- },
- # NOTE(gmann): servers_links attribute is not necessary to be
- # present always So it is not 'required'.
- 'required': ['servers']
- }
-}
-
-server_actions_common_schema = {
- 'status_code': [202]
-}
-
-server_actions_delete_password = {
- 'status_code': [204]
-}
-
-get_console_output = {
- 'status_code': [200],
- 'response_body': {
- 'type': 'object',
- 'properties': {
- 'output': {'type': 'string'}
- },
- 'required': ['output']
- }
-}
-
-common_instance_actions = {
- 'type': 'object',
- 'properties': {
- 'action': {'type': 'string'},
- 'request_id': {'type': 'string'},
- 'user_id': {'type': 'string'},
- 'project_id': {'type': 'string'},
- 'start_time': {'type': 'string'},
- 'message': {'type': ['string', 'null']}
- },
- 'required': ['action', 'request_id', 'user_id', 'project_id',
- 'start_time', 'message']
-}
-
-instance_action_events = {
- 'type': 'array',
- 'items': {
- 'type': 'object',
- 'properties': {
- 'event': {'type': 'string'},
- 'start_time': {'type': 'string'},
- 'finish_time': {'type': 'string'},
- 'result': {'type': 'string'},
- 'traceback': {'type': ['string', 'null']}
- },
- 'required': ['event', 'start_time', 'finish_time', 'result',
- 'traceback']
- }
-}
-
-common_get_instance_action = copy.deepcopy(common_instance_actions)
-
-common_get_instance_action['properties'].update({
- 'events': instance_action_events})
-# 'events' does not come in response body always so it is not
-# defined as 'required'
-
-base_list_servers_detail = {
- 'status_code': [200],
- 'response_body': {
- 'type': 'object',
- 'properties': {
- 'servers': {
- 'type': 'array',
- 'items': common_show_server
- }
- },
- 'required': ['servers']
- }
-}
diff --git a/tempest/api_schema/response/compute/v2_1/servers.py b/tempest/api_schema/response/compute/v2_1/servers.py
index ebee69769..726f9b12f 100644
--- a/tempest/api_schema/response/compute/v2_1/servers.py
+++ b/tempest/api_schema/response/compute/v2_1/servers.py
@@ -15,7 +15,6 @@
import copy
from tempest.api_schema.response.compute import parameter_types
-from tempest.api_schema.response.compute import servers
create_server = {
'status_code': [202],
@@ -46,24 +45,110 @@ create_server_with_admin_pass['response_body']['properties']['server'][
create_server_with_admin_pass['response_body']['properties']['server'][
'required'].append('adminPass')
-update_server = copy.deepcopy(servers.base_update_get_server)
-update_server['response_body']['properties']['server']['properties'].update({
- 'hostId': {'type': 'string'},
- 'OS-DCF:diskConfig': {'type': 'string'},
- 'accessIPv4': parameter_types.access_ip_v4,
- 'accessIPv6': parameter_types.access_ip_v6
-})
-update_server['response_body']['properties']['server']['required'].append(
- # NOTE: OS-DCF:diskConfig and accessIPv4/v6 are API
+list_servers = {
+ 'status_code': [200],
+ 'response_body': {
+ 'type': 'object',
+ 'properties': {
+ 'servers': {
+ 'type': 'array',
+ 'items': {
+ 'type': 'object',
+ 'properties': {
+ 'id': {'type': 'string'},
+ 'links': parameter_types.links,
+ 'name': {'type': 'string'}
+ },
+ 'required': ['id', 'links', 'name']
+ }
+ },
+ 'servers_links': parameter_types.links
+ },
+ # NOTE(gmann): servers_links attribute is not necessary to be
+ # present always So it is not 'required'.
+ 'required': ['servers']
+ }
+}
+
+delete_server = {
+ 'status_code': [204],
+}
+
+common_show_server = {
+ 'type': 'object',
+ 'properties': {
+ 'id': {'type': 'string'},
+ 'name': {'type': 'string'},
+ 'status': {'type': 'string'},
+ 'image': {'oneOf': [
+ {'type': 'object',
+ 'properties': {
+ 'id': {'type': 'string'},
+ 'links': parameter_types.links
+ },
+ 'required': ['id', 'links']},
+ {'type': ['string', 'null']}
+ ]},
+ 'flavor': {
+ 'type': 'object',
+ 'properties': {
+ 'id': {'type': 'string'},
+ 'links': parameter_types.links
+ },
+ 'required': ['id', 'links']
+ },
+ 'fault': {
+ 'type': 'object',
+ 'properties': {
+ 'code': {'type': 'integer'},
+ 'created': {'type': 'string'},
+ 'message': {'type': 'string'},
+ 'details': {'type': 'string'},
+ },
+ # NOTE(gmann): 'details' is not necessary to be present
+ # in the 'fault'. So it is not defined as 'required'.
+ 'required': ['code', 'created', 'message']
+ },
+ 'user_id': {'type': 'string'},
+ 'tenant_id': {'type': 'string'},
+ 'created': {'type': 'string'},
+ 'updated': {'type': 'string'},
+ 'progress': {'type': 'integer'},
+ 'metadata': {'type': 'object'},
+ 'links': parameter_types.links,
+ 'addresses': parameter_types.addresses,
+ 'hostId': {'type': 'string'},
+ 'OS-DCF:diskConfig': {'type': 'string'},
+ 'accessIPv4': parameter_types.access_ip_v4,
+ 'accessIPv6': parameter_types.access_ip_v6
+ },
+ # NOTE(GMann): 'progress' attribute is present in the response
+ # only when server's status is one of the progress statuses
+ # ("ACTIVE","BUILD", "REBUILD", "RESIZE","VERIFY_RESIZE")
+ # 'fault' attribute is present in the response
+ # only when server's status is one of the "ERROR", "DELETED".
+ # OS-DCF:diskConfig and accessIPv4/v6 are API
# extensions, and some environments return a response
- # without these attributes. So they are not 'required'.
- 'hostId'
-)
+ # without these attributes.So these are not defined as 'required'.
+ 'required': ['id', 'name', 'status', 'image', 'flavor',
+ 'user_id', 'tenant_id', 'created', 'updated',
+ 'metadata', 'links', 'addresses', 'hostId']
+}
+
+update_server = {
+ 'status_code': [200],
+ 'response_body': {
+ 'type': 'object',
+ 'properties': {
+ 'server': common_show_server
+ },
+ 'required': ['server']
+ }
+}
-get_server = copy.deepcopy(servers.base_update_get_server)
-get_server['response_body']['properties']['server']['properties'].update({
+server_detail = copy.deepcopy(common_show_server)
+server_detail['properties'].update({
'key_name': {'type': ['string', 'null']},
- 'hostId': {'type': 'string'},
'security_groups': {'type': 'array'},
# NOTE: Non-admin users also can see "OS-SRV-USG" and "OS-EXT-AZ"
@@ -81,27 +166,64 @@ get_server['response_body']['properties']['server']['properties'].update({
'OS-EXT-SRV-ATTR:instance_name': {'type': 'string'},
'OS-EXT-SRV-ATTR:hypervisor_hostname': {'type': ['string', 'null']},
'os-extended-volumes:volumes_attached': {'type': 'array'},
- 'OS-DCF:diskConfig': {'type': 'string'},
- 'accessIPv4': parameter_types.access_ip_v4,
- 'accessIPv6': parameter_types.access_ip_v6,
'config_drive': {'type': 'string'}
})
-get_server['response_body']['properties']['server']['required'].append(
- # NOTE: OS-SRV-USG, OS-EXT-AZ, OS-EXT-STS, OS-EXT-SRV-ATTR,
- # os-extended-volumes, OS-DCF and accessIPv4/v6 are API
- # extension, and some environments return a response without
- # these attributes. So they are not 'required'.
- 'hostId'
-)
+server_detail['properties']['addresses']['patternProperties'][
+ '^[a-zA-Z0-9-_.]+$']['items']['properties'].update({
+ 'OS-EXT-IPS:type': {'type': 'string'},
+ 'OS-EXT-IPS-MAC:mac_addr': parameter_types.mac_address})
# NOTE(gmann): Update OS-EXT-IPS:type and OS-EXT-IPS-MAC:mac_addr
# attributes in server address. Those are API extension,
# and some environments return a response without
# these attributes. So they are not 'required'.
-get_server['response_body']['properties']['server']['properties'][
- 'addresses']['patternProperties']['^[a-zA-Z0-9-_.]+$']['items'][
- 'properties'].update({
- 'OS-EXT-IPS:type': {'type': 'string'},
- 'OS-EXT-IPS-MAC:mac_addr': parameter_types.mac_address})
+
+get_server = {
+ 'status_code': [200],
+ 'response_body': {
+ 'type': 'object',
+ 'properties': {
+ 'server': server_detail
+ },
+ 'required': ['server']
+ }
+}
+
+list_servers_detail = {
+ 'status_code': [200],
+ 'response_body': {
+ 'type': 'object',
+ 'properties': {
+ 'servers': {
+ 'type': 'array',
+ 'items': server_detail
+ },
+ 'servers_links': parameter_types.links
+ },
+ # NOTE(gmann): servers_links attribute is not necessary to be
+ # present always So it is not 'required'.
+ 'required': ['servers']
+ }
+}
+
+rebuild_server = copy.deepcopy(update_server)
+rebuild_server['status_code'] = [202]
+
+rebuild_server_with_admin_pass = copy.deepcopy(rebuild_server)
+rebuild_server_with_admin_pass['response_body']['properties']['server'][
+ 'properties'].update({'adminPass': {'type': 'string'}})
+rebuild_server_with_admin_pass['response_body']['properties']['server'][
+ 'required'].append('adminPass')
+
+rescue_server = {
+ 'status_code': [200],
+ 'response_body': {
+ 'type': 'object',
+ 'properties': {
+ 'adminPass': {'type': 'string'}
+ },
+ 'required': ['adminPass']
+ }
+}
list_virtual_interfaces = {
'status_code': [200],
@@ -174,30 +296,11 @@ list_volume_attachments['response_body']['properties'][
'volumeAttachments']['items']['properties'].update(
{'serverId': {'type': 'string'}})
-set_get_server_metadata_item = {
- 'status_code': [200],
- 'response_body': {
- 'type': 'object',
- 'properties': {
- 'meta': {
- 'type': 'object',
- 'patternProperties': {
- '^.+$': {'type': 'string'}
- }
- }
- },
- 'required': ['meta']
- }
-}
-
list_addresses_by_network = {
'status_code': [200],
'response_body': parameter_types.addresses
}
-server_actions_confirm_resize = copy.deepcopy(
- servers.server_actions_delete_password)
-
list_addresses = {
'status_code': [200],
'response_body': {
@@ -258,10 +361,36 @@ list_server_groups = {
}
}
-instance_actions_object = copy.deepcopy(servers.common_instance_actions)
-instance_actions_object[
- 'properties'].update({'instance_uuid': {'type': 'string'}})
-instance_actions_object['required'].extend(['instance_uuid'])
+instance_actions = {
+ 'type': 'object',
+ 'properties': {
+ 'action': {'type': 'string'},
+ 'request_id': {'type': 'string'},
+ 'user_id': {'type': 'string'},
+ 'project_id': {'type': 'string'},
+ 'start_time': {'type': 'string'},
+ 'message': {'type': ['string', 'null']},
+ 'instance_uuid': {'type': 'string'}
+ },
+ 'required': ['action', 'request_id', 'user_id', 'project_id',
+ 'start_time', 'message', 'instance_uuid']
+}
+
+instance_action_events = {
+ 'type': 'array',
+ 'items': {
+ 'type': 'object',
+ 'properties': {
+ 'event': {'type': 'string'},
+ 'start_time': {'type': 'string'},
+ 'finish_time': {'type': 'string'},
+ 'result': {'type': 'string'},
+ 'traceback': {'type': ['string', 'null']}
+ },
+ 'required': ['event', 'start_time', 'finish_time', 'result',
+ 'traceback']
+ }
+}
list_instance_actions = {
'status_code': [200],
@@ -270,93 +399,120 @@ list_instance_actions = {
'properties': {
'instanceActions': {
'type': 'array',
- 'items': instance_actions_object
+ 'items': instance_actions
}
},
'required': ['instanceActions']
}
}
-get_instance_actions_object = copy.deepcopy(servers.common_get_instance_action)
-get_instance_actions_object[
- 'properties'].update({'instance_uuid': {'type': 'string'}})
-get_instance_actions_object['required'].extend(['instance_uuid'])
+instance_actions_with_events = copy.deepcopy(instance_actions)
+instance_actions_with_events['properties'].update({
+ 'events': instance_action_events})
+# 'events' does not come in response body always so it is not
+# defined as 'required'
get_instance_action = {
'status_code': [200],
'response_body': {
'type': 'object',
'properties': {
- 'instanceAction': get_instance_actions_object
+ 'instanceAction': instance_actions_with_events
},
'required': ['instanceAction']
}
}
-list_servers_detail = copy.deepcopy(servers.base_list_servers_detail)
-list_servers_detail['response_body']['properties']['servers']['items'][
- 'properties'].update({
- 'key_name': {'type': ['string', 'null']},
- 'hostId': {'type': 'string'},
- 'OS-DCF:diskConfig': {'type': 'string'},
- 'security_groups': {'type': 'array'},
-
- # NOTE: Non-admin users also can see "OS-SRV-USG" and "OS-EXT-AZ"
- # attributes.
- 'OS-SRV-USG:launched_at': {'type': ['string', 'null']},
- 'OS-SRV-USG:terminated_at': {'type': ['string', 'null']},
- 'OS-EXT-AZ:availability_zone': {'type': 'string'},
-
- # NOTE: Admin users only can see "OS-EXT-STS" and "OS-EXT-SRV-ATTR"
- # attributes.
- 'OS-EXT-STS:task_state': {'type': ['string', 'null']},
- 'OS-EXT-STS:vm_state': {'type': 'string'},
- 'OS-EXT-STS:power_state': {'type': 'integer'},
- 'OS-EXT-SRV-ATTR:host': {'type': ['string', 'null']},
- 'OS-EXT-SRV-ATTR:instance_name': {'type': 'string'},
- 'OS-EXT-SRV-ATTR:hypervisor_hostname': {'type': ['string', 'null']},
- 'os-extended-volumes:volumes_attached': {'type': 'array'},
- 'accessIPv4': parameter_types.access_ip_v4,
- 'accessIPv6': parameter_types.access_ip_v6,
- 'config_drive': {'type': 'string'}
- })
-# NOTE(GMann): OS-SRV-USG, OS-EXT-AZ, OS-EXT-STS, OS-EXT-SRV-ATTR,
-# os-extended-volumes, OS-DCF and accessIPv4/v6 are API
-# extensions, and some environments return a response without
-# these attributes. So they are not 'required'.
-list_servers_detail['response_body']['properties']['servers']['items'][
- 'required'].append('hostId')
-# NOTE(gmann): Update OS-EXT-IPS:type and OS-EXT-IPS-MAC:mac_addr
-# attributes in server address. Those are API extension,
-# and some environments return a response without
-# these attributes. So they are not 'required'.
-list_servers_detail['response_body']['properties']['servers']['items'][
- 'properties']['addresses']['patternProperties']['^[a-zA-Z0-9-_.]+$'][
- 'items']['properties'].update({
- 'OS-EXT-IPS:type': {'type': 'string'},
- 'OS-EXT-IPS-MAC:mac_addr': parameter_types.mac_address})
-# Defining 'servers_links' attributes for V2 server schema
-list_servers_detail['response_body'][
- 'properties'].update({'servers_links': parameter_types.links})
-# NOTE(gmann): servers_links attribute is not necessary to be
-# present always So it is not 'required'.
+get_password = {
+ 'status_code': [200],
+ 'response_body': {
+ 'type': 'object',
+ 'properties': {
+ 'password': {'type': 'string'}
+ },
+ 'required': ['password']
+ }
+}
-rebuild_server = copy.deepcopy(update_server)
-rebuild_server['status_code'] = [202]
+get_vnc_console = {
+ 'status_code': [200],
+ 'response_body': {
+ 'type': 'object',
+ 'properties': {
+ 'console': {
+ 'type': 'object',
+ 'properties': {
+ 'type': {'type': 'string'},
+ 'url': {
+ 'type': 'string',
+ 'format': 'uri'
+ }
+ },
+ 'required': ['type', 'url']
+ }
+ },
+ 'required': ['console']
+ }
+}
-rebuild_server_with_admin_pass = copy.deepcopy(rebuild_server)
-rebuild_server_with_admin_pass['response_body']['properties']['server'][
- 'properties'].update({'adminPass': {'type': 'string'}})
-rebuild_server_with_admin_pass['response_body']['properties']['server'][
- 'required'].append('adminPass')
+get_console_output = {
+ 'status_code': [200],
+ 'response_body': {
+ 'type': 'object',
+ 'properties': {
+ 'output': {'type': 'string'}
+ },
+ 'required': ['output']
+ }
+}
-rescue_server = {
+set_server_metadata = {
'status_code': [200],
'response_body': {
'type': 'object',
'properties': {
- 'adminPass': {'type': 'string'}
+ 'metadata': {
+ 'type': 'object',
+ 'patternProperties': {
+ '^.+$': {'type': 'string'}
+ }
+ }
},
- 'required': ['adminPass']
+ 'required': ['metadata']
}
}
+
+list_server_metadata = copy.deepcopy(set_server_metadata)
+
+update_server_metadata = copy.deepcopy(set_server_metadata)
+
+delete_server_metadata_item = {
+ 'status_code': [204]
+}
+
+set_get_server_metadata_item = {
+ 'status_code': [200],
+ 'response_body': {
+ 'type': 'object',
+ 'properties': {
+ 'meta': {
+ 'type': 'object',
+ 'patternProperties': {
+ '^.+$': {'type': 'string'}
+ }
+ }
+ },
+ 'required': ['meta']
+ }
+}
+
+server_actions_common_schema = {
+ 'status_code': [202]
+}
+
+server_actions_delete_password = {
+ 'status_code': [204]
+}
+
+server_actions_confirm_resize = copy.deepcopy(
+ server_actions_delete_password)
diff --git a/tempest/api_schema/response/compute/version.py b/tempest/api_schema/response/compute/version.py
index 32c6d96a1..6579c63df 100644
--- a/tempest/api_schema/response/compute/version.py
+++ b/tempest/api_schema/response/compute/version.py
@@ -45,8 +45,12 @@ version = {
}
},
'status': {'type': 'string'},
- 'updated': {'type': 'string', 'format': 'date-time'}
+ 'updated': {'type': 'string', 'format': 'date-time'},
+ 'version': {'type': 'string'},
+ 'min_version': {'type': 'string'}
},
+ # NOTE: version and min_version have been added since Kilo,
+ # so they should not be required.
'required': ['id', 'links', 'media-types', 'status', 'updated']
}
},
diff --git a/tempest/common/accounts.py b/tempest/common/accounts.py
index acf6d4fa9..93c8bcf79 100644
--- a/tempest/common/accounts.py
+++ b/tempest/common/accounts.py
@@ -180,12 +180,20 @@ class Accounts(cred_provider.CredentialProvider):
useable_hashes = hashes
return useable_hashes
+ def _sanitize_creds(self, creds):
+ temp_creds = creds.copy()
+ temp_creds.pop('password')
+ return temp_creds
+
def _get_creds(self, roles=None):
if self.use_default_creds:
raise exceptions.InvalidConfiguration(
"Account file %s doesn't exist" % CONF.auth.test_accounts_file)
useable_hashes = self._get_match_hash_list(roles)
free_hash = self._get_free_hash(useable_hashes)
+ clean_creds = self._sanitize_creds(
+ self.hash_dict['creds'][free_hash])
+ LOG.info('%s allocated creds:\n%s' % (self.name, clean_creds))
return self._wrap_creds_with_network(free_hash)
@lockutils.synchronized('test_accounts_io', external=True)
@@ -216,7 +224,9 @@ class Accounts(cred_provider.CredentialProvider):
def remove_credentials(self, creds):
_hash = self.get_hash(creds)
+ clean_creds = self._sanitize_creds(self.hash_dict['creds'][_hash])
self.remove_hash(_hash)
+ LOG.info("%s returned allocated creds:\n%s" % (self.name, clean_creds))
def get_primary_creds(self):
if self.isolated_creds.get('primary'):
diff --git a/tempest/common/credentials.py b/tempest/common/credentials.py
index c34df48ef..71d905f82 100644
--- a/tempest/common/credentials.py
+++ b/tempest/common/credentials.py
@@ -69,3 +69,25 @@ def is_admin_available():
except exceptions.InvalidConfiguration:
is_admin = False
return is_admin
+
+
+# We want a helper function here to check and see if alt credentials
+# are available so we can do a single call from skip_checks if alt
+# creds area vailable.
+def is_alt_available():
+ # If tenant isolation is enabled admin will be available
+ if CONF.auth.allow_tenant_isolation:
+ return True
+ # Check whether test accounts file has the admin specified or not
+ if (CONF.auth.test_accounts_file and
+ os.path.isfile(CONF.auth.test_accounts_file)):
+ check_accounts = accounts.Accounts(name='check_alt')
+ else:
+ check_accounts = accounts.NotLockingAccounts(name='check_alt')
+ try:
+ if not check_accounts.is_multi_user():
+ return False
+ else:
+ return True
+ except exceptions.InvalidConfiguration:
+ return False
diff --git a/tempest/scenario/manager.py b/tempest/scenario/manager.py
index d2c41f08f..c7272fef7 100644
--- a/tempest/scenario/manager.py
+++ b/tempest/scenario/manager.py
@@ -23,7 +23,6 @@ from tempest_lib.common.utils import data_utils
from tempest_lib import exceptions as lib_exc
from tempest import clients
-from tempest.common import credentials
from tempest.common import fixed_network
from tempest.common.utils.linux import remote_client
from tempest import config
@@ -39,16 +38,7 @@ LOG = log.getLogger(__name__)
class ScenarioTest(tempest.test.BaseTestCase):
"""Base class for scenario tests. Uses tempest own clients. """
- @classmethod
- def setup_credentials(cls):
- super(ScenarioTest, cls).setup_credentials()
- # TODO(andreaf) Some of the code from this resource_setup could be
- # moved into `BaseTestCase`
- cls.isolated_creds = credentials.get_isolated_credentials(
- cls.__name__, network_resources=cls.network_resources)
- cls.manager = clients.Manager(
- credentials=cls.credentials()
- )
+ credentials = ['primary']
@classmethod
def setup_clients(cls):
@@ -72,21 +62,6 @@ class ScenarioTest(tempest.test.BaseTestCase):
# Heat client
cls.orchestration_client = cls.manager.orchestration_client
- @classmethod
- def credentials(cls):
- return cls.isolated_creds.get_primary_creds()
-
- @classmethod
- def alt_credentials(cls):
- return cls.isolated_creds.get_alt_creds()
-
- @classmethod
- def admin_credentials(cls):
- try:
- return cls.isolated_creds.get_admin_creds()
- except NotImplementedError:
- raise cls.skipException('Admin Credentials are not available')
-
# ## Methods to handle sync and async deletes
def setUp(self):
@@ -319,10 +294,18 @@ class ScenarioTest(tempest.test.BaseTestCase):
if username is None:
username = CONF.scenario.ssh_user
- if private_key is None:
- private_key = self.keypair['private_key']
+ # Set this with 'keypair' or others to log in with keypair or
+ # username/password.
+ if CONF.compute.ssh_auth_method == 'keypair':
+ password = None
+ if private_key is None:
+ private_key = self.keypair['private_key']
+ else:
+ password = CONF.compute.image_ssh_password
+ private_key = None
linux_client = remote_client.RemoteClient(ip, username,
- pkey=private_key)
+ pkey=private_key,
+ password=password)
try:
linux_client.validate_authentication()
except Exception:
@@ -542,19 +525,13 @@ class NetworkScenarioTest(ScenarioTest):
"""
+ credentials = ['primary', 'admin']
+
@classmethod
def skip_checks(cls):
super(NetworkScenarioTest, cls).skip_checks()
if not CONF.service_available.neutron:
raise cls.skipException('Neutron not available')
- if not credentials.is_admin_available():
- msg = ("Missing Identity Admin API credentials in configuration.")
- raise cls.skipException(msg)
-
- @classmethod
- def setup_credentials(cls):
- super(NetworkScenarioTest, cls).setup_credentials()
- cls.admin_manager = clients.Manager(cls.admin_credentials())
@classmethod
def resource_setup(cls):
@@ -1162,6 +1139,9 @@ class BaremetalProvisionStates(object):
class BaremetalScenarioTest(ScenarioTest):
+
+ credentials = ['primary', 'admin']
+
@classmethod
def skip_checks(cls):
super(BaremetalScenarioTest, cls).skip_checks()
@@ -1171,14 +1151,10 @@ class BaremetalScenarioTest(ScenarioTest):
raise cls.skipException(msg)
@classmethod
- def setup_credentials(cls):
- super(BaremetalScenarioTest, cls).setup_credentials()
+ def setup_clients(cls):
+ super(BaremetalScenarioTest, cls).setup_clients()
- # use an admin client manager for baremetal client
- manager = clients.Manager(
- credentials=cls.admin_credentials()
- )
- cls.baremetal_client = manager.baremetal_client
+ cls.baremetal_client = cls.admin_manager.baremetal_client
@classmethod
def resource_setup(cls):
@@ -1300,18 +1276,12 @@ class EncryptionScenarioTest(ScenarioTest):
Base class for encryption scenario tests
"""
- @classmethod
- def skip_checks(cls):
- super(EncryptionScenarioTest, cls).skip_checks()
- if not credentials.is_admin_available():
- msg = ("Missing Identity Admin API credentials in configuration.")
- raise cls.skipException(msg)
+ credentials = ['primary', 'admin']
@classmethod
def setup_clients(cls):
super(EncryptionScenarioTest, cls).setup_clients()
- admin_manager = clients.Manager(cls.admin_credentials())
- cls.admin_volume_types_client = admin_manager.volume_types_client
+ cls.admin_volume_types_client = cls.os_adm.volume_types_client
def _wait_for_volume_status(self, status):
self.status_timeout(
diff --git a/tempest/scenario/test_aggregates_basic_ops.py b/tempest/scenario/test_aggregates_basic_ops.py
index c5e80124c..0e158ed53 100644
--- a/tempest/scenario/test_aggregates_basic_ops.py
+++ b/tempest/scenario/test_aggregates_basic_ops.py
@@ -16,7 +16,6 @@
from oslo_log import log as logging
from tempest_lib.common.utils import data_utils
-from tempest.common import credentials
from tempest.common import tempest_fixtures as fixtures
from tempest.scenario import manager
from tempest import test
@@ -34,23 +33,18 @@ class TestAggregatesBasicOps(manager.ScenarioTest):
Removes host from aggregate
Deletes aggregate
"""
- @classmethod
- def skip_checks(cls):
- super(TestAggregatesBasicOps, cls).skip_checks()
- if not credentials.is_admin_available():
- msg = ("Missing Identity Admin API credentials in configuration.")
- raise cls.skipException(msg)
+
+ credentials = ['primary', 'admin']
@classmethod
def setup_clients(cls):
super(TestAggregatesBasicOps, cls).setup_clients()
+ # Use admin client by default
+ cls.manager = cls.admin_manager
+ super(TestAggregatesBasicOps, cls).resource_setup()
cls.aggregates_client = cls.manager.aggregates_client
cls.hosts_client = cls.manager.hosts_client
- @classmethod
- def credentials(cls):
- return cls.admin_credentials()
-
def _create_aggregate(self, **kwargs):
aggregate = self.aggregates_client.create_aggregate(**kwargs)
self.addCleanup(self._delete_aggregate, aggregate)
@@ -80,7 +74,7 @@ class TestAggregatesBasicOps(manager.ScenarioTest):
def _check_aggregate_details(self, aggregate, aggregate_name, azone,
hosts, metadata):
- aggregate = self.aggregates_client.get_aggregate(aggregate['id'])
+ aggregate = self.aggregates_client.show_aggregate(aggregate['id'])
self.assertEqual(aggregate_name, aggregate['name'])
self.assertEqual(azone, aggregate['availability_zone'])
self.assertEqual(hosts, aggregate['hosts'])
diff --git a/tempest/scenario/test_dashboard_basic_ops.py b/tempest/scenario/test_dashboard_basic_ops.py
index dd7376a9f..5aec01f25 100644
--- a/tempest/scenario/test_dashboard_basic_ops.py
+++ b/tempest/scenario/test_dashboard_basic_ops.py
@@ -96,7 +96,7 @@ class TestDashboardBasicOps(manager.ScenarioTest):
@test.idempotent_id('4f8851b1-0e69-482b-b63b-84c6e76f6c80')
@test.services('dashboard')
def test_basic_scenario(self):
- creds = self.credentials()
+ creds = self.os.credentials
self.check_login_page()
self.user_login(creds.username, creds.password)
self.check_home_page()
diff --git a/tempest/scenario/test_security_groups_basic_ops.py b/tempest/scenario/test_security_groups_basic_ops.py
index 1ecc212ae..03d338b90 100644
--- a/tempest/scenario/test_security_groups_basic_ops.py
+++ b/tempest/scenario/test_security_groups_basic_ops.py
@@ -92,6 +92,8 @@ class TestSecurityGroupsBasicOps(manager.NetworkScenarioTest):
its own router connected to the public network
"""
+ credentials = ['primary', 'alt', 'admin']
+
class TenantProperties(object):
"""
helper class to save tenant details
@@ -143,9 +145,6 @@ class TestSecurityGroupsBasicOps(manager.NetworkScenarioTest):
# TODO(mnewby) Consider looking up entities as needed instead
# of storing them as collections on the class.
- # get credentials for secondary tenant
- cls.alt_creds = cls.isolated_creds.get_alt_creds()
- cls.alt_manager = clients.Manager(cls.alt_creds)
# Credentials from the manager are filled with both IDs and Names
cls.alt_creds = cls.alt_manager.credentials
@@ -154,7 +153,7 @@ class TestSecurityGroupsBasicOps(manager.NetworkScenarioTest):
super(TestSecurityGroupsBasicOps, cls).resource_setup()
cls.floating_ips = {}
cls.tenants = {}
- creds = cls.credentials()
+ creds = cls.manager.credentials
cls.primary_tenant = cls.TenantProperties(creds)
cls.alt_tenant = cls.TenantProperties(cls.alt_creds)
for tenant in [cls.primary_tenant, cls.alt_tenant]:
diff --git a/tempest/services/compute/json/aggregates_client.py b/tempest/services/compute/json/aggregates_client.py
index 36a347bbb..6c02b6335 100644
--- a/tempest/services/compute/json/aggregates_client.py
+++ b/tempest/services/compute/json/aggregates_client.py
@@ -30,7 +30,7 @@ class AggregatesClientJSON(service_client.ServiceClient):
self.validate_response(schema.list_aggregates, resp, body)
return service_client.ResponseBodyList(resp, body['aggregates'])
- def get_aggregate(self, aggregate_id):
+ def show_aggregate(self, aggregate_id):
"""Get details of the given aggregate."""
resp, body = self.get("os-aggregates/%s" % str(aggregate_id))
body = json.loads(body)
@@ -67,7 +67,7 @@ class AggregatesClientJSON(service_client.ServiceClient):
def is_resource_deleted(self, id):
try:
- self.get_aggregate(id)
+ self.show_aggregate(id)
except lib_exc.NotFound:
return True
return False
diff --git a/tempest/services/compute/json/availability_zone_client.py b/tempest/services/compute/json/availability_zone_client.py
index 6c5039831..925d79f54 100644
--- a/tempest/services/compute/json/availability_zone_client.py
+++ b/tempest/services/compute/json/availability_zone_client.py
@@ -22,17 +22,15 @@ from tempest.common import service_client
class AvailabilityZoneClientJSON(service_client.ServiceClient):
- def get_availability_zone_list(self):
- resp, body = self.get('os-availability-zone')
- body = json.loads(body)
- self.validate_response(schema.list_availability_zone_list, resp, body)
- return service_client.ResponseBodyList(resp,
- body['availabilityZoneInfo'])
+ def list_availability_zones(self, detail=False):
+ url = 'os-availability-zone'
+ schema_list = schema.list_availability_zone_list
+ if detail:
+ url += '/detail'
+ schema_list = schema.list_availability_zone_list_detail
- def get_availability_zone_list_detail(self):
- resp, body = self.get('os-availability-zone/detail')
+ resp, body = self.get(url)
body = json.loads(body)
- self.validate_response(schema.list_availability_zone_list_detail, resp,
- body)
+ self.validate_response(schema_list, resp, body)
return service_client.ResponseBodyList(resp,
body['availabilityZoneInfo'])
diff --git a/tempest/services/compute/json/baremetal_nodes_client.py b/tempest/services/compute/json/baremetal_nodes_client.py
index d8bbadd0c..e4a4e8842 100644
--- a/tempest/services/compute/json/baremetal_nodes_client.py
+++ b/tempest/services/compute/json/baremetal_nodes_client.py
@@ -34,7 +34,7 @@ class BaremetalNodesClientJSON(service_client.ServiceClient):
self.validate_response(schema.list_baremetal_nodes, resp, body)
return service_client.ResponseBodyList(resp, body['nodes'])
- def get_baremetal_node(self, baremetal_node_id):
+ def show_baremetal_node(self, baremetal_node_id):
"""Returns the details of a single baremetal node."""
url = 'os-baremetal-nodes/%s' % baremetal_node_id
resp, body = self.get(url)
diff --git a/tempest/services/compute/json/certificates_client.py b/tempest/services/compute/json/certificates_client.py
index e6b72bbe7..752a48e77 100644
--- a/tempest/services/compute/json/certificates_client.py
+++ b/tempest/services/compute/json/certificates_client.py
@@ -21,7 +21,7 @@ from tempest.common import service_client
class CertificatesClientJSON(service_client.ServiceClient):
- def get_certificate(self, id):
+ def show_certificate(self, id):
url = "os-certificates/%s" % (id)
resp, body = self.get(url)
body = json.loads(body)
diff --git a/tempest/services/compute/json/extensions_client.py b/tempest/services/compute/json/extensions_client.py
index 5c6908530..265b381ea 100644
--- a/tempest/services/compute/json/extensions_client.py
+++ b/tempest/services/compute/json/extensions_client.py
@@ -33,7 +33,7 @@ class ExtensionsClientJSON(service_client.ServiceClient):
exts = extensions['extensions']
return any([e for e in exts if e['name'] == extension])
- def get_extension(self, extension_alias):
+ def show_extension(self, extension_alias):
resp, body = self.get('extensions/%s' % extension_alias)
body = json.loads(body)
return service_client.ResponseBody(resp, body['extension'])
diff --git a/tempest/services/compute/json/interfaces_client.py b/tempest/services/compute/json/interfaces_client.py
index c3bfa99ca..223e90bac 100644
--- a/tempest/services/compute/json/interfaces_client.py
+++ b/tempest/services/compute/json/interfaces_client.py
@@ -16,8 +16,8 @@
import json
import time
-from tempest.api_schema.response.compute import servers as servers_schema
from tempest.api_schema.response.compute.v2_1 import interfaces as schema
+from tempest.api_schema.response.compute.v2_1 import servers as servers_schema
from tempest.common import service_client
from tempest import exceptions
diff --git a/tempest/services/compute/json/servers_client.py b/tempest/services/compute/json/servers_client.py
index bd276682a..c9ba2c38e 100644
--- a/tempest/services/compute/json/servers_client.py
+++ b/tempest/services/compute/json/servers_client.py
@@ -20,7 +20,6 @@ import urllib
from tempest_lib import exceptions as lib_exc
-from tempest.api_schema.response.compute import servers as common_schema
from tempest.api_schema.response.compute.v2_1 import servers as schema
from tempest.common import service_client
from tempest.common import waiters
@@ -147,7 +146,7 @@ class ServersClientJSON(service_client.ServiceClient):
def delete_server(self, server_id):
"""Deletes the given server."""
resp, body = self.delete("servers/%s" % str(server_id))
- self.validate_response(common_schema.delete_server, resp, body)
+ self.validate_response(schema.delete_server, resp, body)
return service_client.ResponseBody(resp, body)
def list_servers(self, params=None):
@@ -159,7 +158,7 @@ class ServersClientJSON(service_client.ServiceClient):
resp, body = self.get(url)
body = json.loads(body)
- self.validate_response(common_schema.list_servers, resp, body)
+ self.validate_response(schema.list_servers, resp, body)
return service_client.ResponseBody(resp, body)
def list_servers_with_detail(self, params=None):
@@ -216,7 +215,7 @@ class ServersClientJSON(service_client.ServiceClient):
return service_client.ResponseBody(resp, body)
def action(self, server_id, action_name, response_key,
- schema=common_schema.server_actions_common_schema,
+ schema=schema.server_actions_common_schema,
response_class=service_client.ResponseBody, **kwargs):
post_body = json.dumps({action_name: kwargs})
resp, body = self.post('servers/%s/action' % str(server_id),
@@ -253,7 +252,7 @@ class ServersClientJSON(service_client.ServiceClient):
resp, body = self.get("servers/%s/os-server-password" %
str(server_id))
body = json.loads(body)
- self.validate_response(common_schema.get_password, resp, body)
+ self.validate_response(schema.get_password, resp, body)
return service_client.ResponseBody(resp, body)
def delete_password(self, server_id):
@@ -264,7 +263,7 @@ class ServersClientJSON(service_client.ServiceClient):
"""
resp, body = self.delete("servers/%s/os-server-password" %
str(server_id))
- self.validate_response(common_schema.server_actions_delete_password,
+ self.validate_response(schema.server_actions_delete_password,
resp, body)
return service_client.ResponseBody(resp, body)
@@ -306,7 +305,7 @@ class ServersClientJSON(service_client.ServiceClient):
def list_server_metadata(self, server_id):
resp, body = self.get("servers/%s/metadata" % str(server_id))
body = json.loads(body)
- self.validate_response(common_schema.list_server_metadata, resp, body)
+ self.validate_response(schema.list_server_metadata, resp, body)
return service_client.ResponseBody(resp, body['metadata'])
def set_server_metadata(self, server_id, meta, no_metadata_field=False):
@@ -317,7 +316,7 @@ class ServersClientJSON(service_client.ServiceClient):
resp, body = self.put('servers/%s/metadata' % str(server_id),
post_body)
body = json.loads(body)
- self.validate_response(common_schema.set_server_metadata, resp, body)
+ self.validate_response(schema.set_server_metadata, resp, body)
return service_client.ResponseBody(resp, body['metadata'])
def update_server_metadata(self, server_id, meta):
@@ -325,7 +324,7 @@ class ServersClientJSON(service_client.ServiceClient):
resp, body = self.post('servers/%s/metadata' % str(server_id),
post_body)
body = json.loads(body)
- self.validate_response(common_schema.update_server_metadata,
+ self.validate_response(schema.update_server_metadata,
resp, body)
return service_client.ResponseBody(resp, body['metadata'])
@@ -348,7 +347,7 @@ class ServersClientJSON(service_client.ServiceClient):
def delete_server_metadata_item(self, server_id, key):
resp, body = self.delete("servers/%s/metadata/%s" %
(str(server_id), key))
- self.validate_response(common_schema.delete_server_metadata_item,
+ self.validate_response(schema.delete_server_metadata_item,
resp, body)
return service_client.ResponseBody(resp, body)
@@ -415,7 +414,7 @@ class ServersClientJSON(service_client.ServiceClient):
req_body = json.dumps({'os-migrateLive': migrate_params})
resp, body = self.post("servers/%s/action" % str(server_id), req_body)
- self.validate_response(common_schema.server_actions_common_schema,
+ self.validate_response(schema.server_actions_common_schema,
resp, body)
return service_client.ResponseBody(resp, body)
@@ -466,7 +465,7 @@ class ServersClientJSON(service_client.ServiceClient):
def get_console_output(self, server_id, length):
kwargs = {'length': length} if length else {}
return self.action(server_id, 'os-getConsoleOutput', 'output',
- common_schema.get_console_output,
+ schema.get_console_output,
response_class=service_client.ResponseBodyData,
**kwargs)
@@ -531,7 +530,7 @@ class ServersClientJSON(service_client.ServiceClient):
def get_vnc_console(self, server_id, console_type):
"""Get URL of VNC console."""
return self.action(server_id, "os-getVNCConsole",
- "console", common_schema.get_vnc_console,
+ "console", schema.get_vnc_console,
type=console_type)
def create_server_group(self, name, policies):
diff --git a/tempest/services/telemetry/json/telemetry_client.py b/tempest/services/telemetry/json/telemetry_client.py
index 36c123b32..0c019084e 100644
--- a/tempest/services/telemetry/json/telemetry_client.py
+++ b/tempest/services/telemetry/json/telemetry_client.py
@@ -50,7 +50,7 @@ class TelemetryClientJSON(service_client.ServiceClient):
body = self.deserialize(body)
return service_client.ResponseBody(resp, body)
- def helper_list(self, uri, query=None, period=None):
+ def _helper_list(self, uri, query=None, period=None):
uri_dict = {}
if query:
uri_dict = {'q.field': query[0],
@@ -67,32 +67,32 @@ class TelemetryClientJSON(service_client.ServiceClient):
def list_resources(self, query=None):
uri = '%s/resources' % self.uri_prefix
- return self.helper_list(uri, query)
+ return self._helper_list(uri, query)
def list_meters(self, query=None):
uri = '%s/meters' % self.uri_prefix
- return self.helper_list(uri, query)
+ return self._helper_list(uri, query)
def list_alarms(self, query=None):
uri = '%s/alarms' % self.uri_prefix
- return self.helper_list(uri, query)
+ return self._helper_list(uri, query)
def list_statistics(self, meter, period=None, query=None):
uri = "%s/meters/%s/statistics" % (self.uri_prefix, meter)
- return self.helper_list(uri, query, period)
+ return self._helper_list(uri, query, period)
def list_samples(self, meter_id, query=None):
uri = '%s/meters/%s' % (self.uri_prefix, meter_id)
- return self.helper_list(uri, query)
+ return self._helper_list(uri, query)
- def get_resource(self, resource_id):
+ def show_resource(self, resource_id):
uri = '%s/resources/%s' % (self.uri_prefix, resource_id)
resp, body = self.get(uri)
self.expected_success(200, resp.status)
body = self.deserialize(body)
return service_client.ResponseBody(resp, body)
- def get_alarm(self, alarm_id):
+ def show_alarm(self, alarm_id):
uri = '%s/alarms/%s' % (self.uri_prefix, alarm_id)
resp, body = self.get(uri)
self.expected_success(200, resp.status)
@@ -123,7 +123,7 @@ class TelemetryClientJSON(service_client.ServiceClient):
body = self.deserialize(body)
return service_client.ResponseBody(resp, body)
- def alarm_get_state(self, alarm_id):
+ def show_alarm_state(self, alarm_id):
uri = "%s/alarms/%s/state" % (self.uri_prefix, alarm_id)
resp, body = self.get(uri)
self.expected_success(200, resp.status)
diff --git a/tempest/test.py b/tempest/test.py
index d57b1d832..118d32646 100644
--- a/tempest/test.py
+++ b/tempest/test.py
@@ -52,13 +52,9 @@ def attr(*args, **kwargs):
def decorator(f):
if 'type' in kwargs and isinstance(kwargs['type'], str):
f = testtools.testcase.attr(kwargs['type'])(f)
- if kwargs['type'] == 'smoke':
- f = testtools.testcase.attr('gate')(f)
elif 'type' in kwargs and isinstance(kwargs['type'], list):
for attr in kwargs['type']:
f = testtools.testcase.attr(attr)(f)
- if attr == 'smoke':
- f = testtools.testcase.attr('gate')(f)
return f
return decorator
@@ -232,6 +228,9 @@ class BaseTestCase(testtools.testcase.WithAttributes,
setUpClassCalled = False
_service = None
+ # NOTE(andreaf) credentials holds a list of the credentials to be allocated
+ # at class setup time. Credential types can be 'primary', 'alt' or 'admin'
+ credentials = []
network_resources = {}
# NOTE(sdague): log_format is defined inline here instead of using the oslo
@@ -317,15 +316,37 @@ class BaseTestCase(testtools.testcase.WithAttributes,
If one is really needed it may be implemented either in the
resource_setup or at test level.
"""
- pass
+ if 'admin' in cls.credentials and not credentials.is_admin_available():
+ msg = "Missing Identity Admin API credentials in configuration."
+ raise cls.skipException(msg)
+ if 'alt' is cls.credentials and not credentials.is_alt_available():
+ msg = "Missing a 2nd set of API credentials in configuration."
+ raise cls.skipException(msg)
@classmethod
def setup_credentials(cls):
- """Allocate credentials and the client managers from them."""
- # TODO(andreaf) There is a fair amount of code that could me moved from
- # base / test classes in here. Ideally tests should be able to only
- # specify a list of (additional) credentials the need to use.
- pass
+ """Allocate credentials and the client managers from them.
+ A test class that requires network resources must override
+ setup_credentials and defined the required resources before super
+ is invoked.
+ """
+ for credentials_type in cls.credentials:
+ # This may raise an exception in case credentials are not available
+ # In that case we want to let the exception through and the test
+ # fail accordingly
+ manager = cls.get_client_manager(
+ credential_type=credentials_type)
+ setattr(cls, 'os_%s' % credentials_type, manager)
+ # Setup some common aliases
+ # TODO(andreaf) The aliases below are a temporary hack
+ # to avoid changing too much code in one patch. They should
+ # be removed eventually
+ if credentials_type == 'primary':
+ cls.os = cls.manager = cls.os_primary
+ if credentials_type == 'admin':
+ cls.os_adm = cls.admin_manager = cls.os_admin
+ if credentials_type == 'alt':
+ cls.alt_manager = cls.os_alt
@classmethod
def setup_clients(cls):
@@ -379,7 +400,8 @@ class BaseTestCase(testtools.testcase.WithAttributes,
level=None))
@classmethod
- def get_client_manager(cls, identity_version=None):
+ def get_client_manager(cls, identity_version=None,
+ credential_type='primary'):
"""
Returns an OpenStack client manager
"""
@@ -394,7 +416,12 @@ class BaseTestCase(testtools.testcase.WithAttributes,
identity_version=identity_version
)
- creds = cls.isolated_creds.get_primary_creds()
+ credentials_method = 'get_%s_creds' % credential_type
+ if hasattr(cls.isolated_creds, credentials_method):
+ creds = getattr(cls.isolated_creds, credentials_method)()
+ else:
+ raise exceptions.InvalidCredentials(
+ "Invalid credentials type %s" % credential_type)
os = clients.Manager(credentials=creds, service=cls._service)
return os
@@ -470,7 +497,7 @@ class NegativeAutoTest(BaseTestCase):
@classmethod
def setUpClass(cls):
super(NegativeAutoTest, cls).setUpClass()
- os = cls.get_client_manager()
+ os = cls.get_client_manager(credential_type='primary')
cls.client = os.negative_client
@staticmethod
@@ -665,7 +692,7 @@ def SimpleNegativeAutoTest(klass):
"""
This decorator registers a test function on basis of the class name.
"""
- @attr(type=['negative', 'gate'])
+ @attr(type=['negative'])
def generic_test(self):
if hasattr(self, '_schema'):
self.execute(self._schema)
diff --git a/tempest/tests/test_decorators.py b/tempest/tests/test_decorators.py
index 0cd54b99b..e5f51f24b 100644
--- a/tempest/tests/test_decorators.py
+++ b/tempest/tests/test_decorators.py
@@ -49,13 +49,9 @@ class TestAttrDecorator(BaseDecoratorsTest):
def test_attr_without_type(self):
self._test_attr_helper(expected_attrs='baz', bar='baz')
- def test_attr_decorator_with_smoke_type(self):
- # smoke passed as type, so smoke and gate must have been set.
- self._test_attr_helper(expected_attrs=['smoke', 'gate'], type='smoke')
-
def test_attr_decorator_with_list_type(self):
- # if type is 'smoke' we'll get the original list of types plus 'gate'
- self._test_attr_helper(expected_attrs=['smoke', 'foo', 'gate'],
+ # if type is 'smoke' we'll get the original list of types
+ self._test_attr_helper(expected_attrs=['smoke', 'foo'],
type=['smoke', 'foo'])
def test_attr_decorator_with_unknown_type(self):
diff --git a/tempest/thirdparty/boto/test.py b/tempest/thirdparty/boto/test.py
index d3846a82f..4485972dd 100644
--- a/tempest/thirdparty/boto/test.py
+++ b/tempest/thirdparty/boto/test.py
@@ -196,6 +196,8 @@ def friendly_function_call_str(call_able, *args, **kwargs):
class BotoTestCase(tempest.test.BaseTestCase):
"""Recommended to use as base class for boto related test."""
+ credentials = ['primary']
+
@classmethod
def skip_checks(cls):
super(BotoTestCase, cls).skip_checks()
@@ -206,11 +208,6 @@ class BotoTestCase(tempest.test.BaseTestCase):
raise cls.skipException("Identity v2 is not available")
@classmethod
- def setup_credentials(cls):
- super(BotoTestCase, cls).setup_credentials()
- cls.os = cls.get_client_manager()
-
- @classmethod
def resource_setup(cls):
super(BotoTestCase, cls).resource_setup()
cls.conclusion = decision_maker()
diff --git a/tempest/thirdparty/boto/test_ec2_instance_run.py b/tempest/thirdparty/boto/test_ec2_instance_run.py
index 8894de023..19a77dce3 100644
--- a/tempest/thirdparty/boto/test_ec2_instance_run.py
+++ b/tempest/thirdparty/boto/test_ec2_instance_run.py
@@ -68,12 +68,21 @@ class InstanceRunTest(boto_test.BotoTestCase):
"ari":
{"name": data_utils.rand_name("ari-name"),
"location": cls.bucket_name + "/" + ari_manifest}}
- for image in cls.images.itervalues():
+ for image_type in ("aki", "ari"):
+ image = cls.images[image_type]
image["image_id"] = cls.ec2_client.register_image(
name=image["name"],
image_location=image["location"])
cls.addResourceCleanUp(cls.ec2_client.deregister_image,
image["image_id"])
+ image = cls.images["ami"]
+ image["image_id"] = cls.ec2_client.register_image(
+ name=image["name"],
+ image_location=image["location"],
+ kernel_id=cls.images["aki"]["image_id"],
+ ramdisk_id=cls.images["ari"]["image_id"])
+ cls.addResourceCleanUp(cls.ec2_client.deregister_image,
+ image["image_id"])
for image in cls.images.itervalues():
def _state():