Move Cinder non-admin tests into unversioned path

As http://lists.openstack.org/pipermail/openstack-dev/2017-March/114507.html
we will use the existing Cinder V2 API tests for testing the base
microversion of Cinder V3 API also.
So it is not necessary to contain versioned path in test module pathes.
This patch just moves Cinder non-admin tests to unversioned pathes.

NOTE: v2 path still contain test_volumes_list and test_volumes_snapshots_list.
      These module names are conflict to unversioned ones, and we still need
      some works for merging them. We will follow that after this patch.

Change-Id: Ibfa348eaf83dc9f3812562848b31f6099b023124
This commit is contained in:
Ken'ichi Ohmichi 2017-04-03 14:00:29 -07:00 committed by Ken'ichi Ohmichi
parent 8c18908b0d
commit d3eb1c05c7
5 changed files with 14 additions and 46 deletions

@ -68,3 +68,17 @@ class VolumesSnapshotNegativeTestJSON(base.BaseVolumeTest):
self.assertRaises(lib_exc.BadRequest,
self.snapshots_client.list_snapshots,
limit='invalid')
@test.attr(type=['negative'])
@decorators.idempotent_id('27b5f37f-bf69-4e8c-986e-c44f3d6819b8')
def test_list_snapshots_invalid_param_sort(self):
self.assertRaises(lib_exc.BadRequest,
self.snapshots_client.list_snapshots,
sort_key='invalid')
@test.attr(type=['negative'])
@decorators.idempotent_id('b68deeda-ca79-4a32-81af-5c51179e553a')
def test_list_snapshots_invalid_param_marker(self):
self.assertRaises(lib_exc.NotFound,
self.snapshots_client.list_snapshots,
marker=data_utils.rand_uuid())

@ -1,46 +0,0 @@
# Copyright 2017 Red Hat, Inc.
# All Rights Reserved.
#
# Licensed under the Apache License, Version 2.0 (the "License"); you may
# not use this file except in compliance with the License. You may obtain
# a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, software
# distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
# WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
# License for the specific language governing permissions and limitations
# under the License.
from tempest.api.volume import base
from tempest import config
from tempest.lib.common.utils import data_utils
from tempest.lib import decorators
from tempest.lib import exceptions as lib_exc
from tempest import test
CONF = config.CONF
class VolumesSnapshotNegativeTest(base.BaseVolumeTest):
@classmethod
def skip_checks(cls):
super(VolumesSnapshotNegativeTest, cls).skip_checks()
if not CONF.volume_feature_enabled.snapshot:
raise cls.skipException("Cinder volume snapshots are disabled")
@test.attr(type=['negative'])
@decorators.idempotent_id('27b5f37f-bf69-4e8c-986e-c44f3d6819b8')
def test_list_snapshots_invalid_param_sort(self):
self.assertRaises(lib_exc.BadRequest,
self.snapshots_client.list_snapshots,
sort_key='invalid')
@test.attr(type=['negative'])
@decorators.idempotent_id('b68deeda-ca79-4a32-81af-5c51179e553a')
def test_list_snapshots_invalid_param_marker(self):
self.assertRaises(lib_exc.NotFound,
self.snapshots_client.list_snapshots,
marker=data_utils.rand_uuid())