Merge "Remove unused config imports/objects"
This commit is contained in:
commit
9323533503
|
@ -12,8 +12,6 @@
|
||||||
|
|
||||||
from unittest import mock
|
from unittest import mock
|
||||||
|
|
||||||
from oslo_config import cfg
|
|
||||||
|
|
||||||
from cinder import context
|
from cinder import context
|
||||||
from cinder import db
|
from cinder import db
|
||||||
from cinder import exception
|
from cinder import exception
|
||||||
|
@ -25,8 +23,6 @@ from cinder.tests.unit import utils as tests_utils
|
||||||
from cinder.volume import api as volume_api
|
from cinder.volume import api as volume_api
|
||||||
from cinder.volume import configuration as conf
|
from cinder.volume import configuration as conf
|
||||||
|
|
||||||
CONF = cfg.CONF
|
|
||||||
|
|
||||||
|
|
||||||
class AttachmentManagerTestCase(test.TestCase):
|
class AttachmentManagerTestCase(test.TestCase):
|
||||||
"""Attachment related test for volume/api.py."""
|
"""Attachment related test for volume/api.py."""
|
||||||
|
|
|
@ -17,7 +17,6 @@
|
||||||
|
|
||||||
from unittest import mock
|
from unittest import mock
|
||||||
|
|
||||||
from oslo_config import cfg
|
|
||||||
from sqlalchemy.orm import exc
|
from sqlalchemy.orm import exc
|
||||||
|
|
||||||
from cinder import db
|
from cinder import db
|
||||||
|
@ -26,9 +25,6 @@ from cinder.tests.unit import test_db_api
|
||||||
from cinder.tests.unit import utils
|
from cinder.tests.unit import utils
|
||||||
|
|
||||||
|
|
||||||
CONF = cfg.CONF
|
|
||||||
|
|
||||||
|
|
||||||
class ClusterTestCase(test_db_api.BaseTest):
|
class ClusterTestCase(test_db_api.BaseTest):
|
||||||
"""Unit tests for cinder.db.api.cluster_*."""
|
"""Unit tests for cinder.db.api.cluster_*."""
|
||||||
|
|
||||||
|
|
|
@ -9,13 +9,10 @@
|
||||||
# WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
|
# WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
|
||||||
# License for the specific language governing permissions and limitations
|
# License for the specific language governing permissions and limitations
|
||||||
# under the License.
|
# under the License.
|
||||||
from oslo_config import cfg
|
|
||||||
|
|
||||||
from cinder.message import defined_messages
|
from cinder.message import defined_messages
|
||||||
from cinder.tests.unit import test
|
from cinder.tests.unit import test
|
||||||
|
|
||||||
CONF = cfg.CONF
|
|
||||||
|
|
||||||
|
|
||||||
class DefinedMessagesTest(test.TestCase):
|
class DefinedMessagesTest(test.TestCase):
|
||||||
def test_event_id_formats(self):
|
def test_event_id_formats(self):
|
||||||
|
|
|
@ -14,14 +14,11 @@ import inspect
|
||||||
from itertools import chain
|
from itertools import chain
|
||||||
|
|
||||||
import ddt
|
import ddt
|
||||||
from oslo_config import cfg
|
|
||||||
|
|
||||||
from cinder import exception
|
from cinder import exception
|
||||||
from cinder.message import message_field
|
from cinder.message import message_field
|
||||||
from cinder.tests.unit import test
|
from cinder.tests.unit import test
|
||||||
|
|
||||||
CONF = cfg.CONF
|
|
||||||
|
|
||||||
|
|
||||||
@ddt.ddt
|
@ddt.ddt
|
||||||
class MessageFieldTest(test.TestCase):
|
class MessageFieldTest(test.TestCase):
|
||||||
|
|
|
@ -15,15 +15,12 @@ from unittest import mock
|
||||||
from keystoneauth1.identity.generic import password
|
from keystoneauth1.identity.generic import password
|
||||||
from keystoneauth1 import loading as ks_loading
|
from keystoneauth1 import loading as ks_loading
|
||||||
from keystoneauth1 import service_token
|
from keystoneauth1 import service_token
|
||||||
from oslo_config import cfg
|
|
||||||
|
|
||||||
from cinder import context
|
from cinder import context
|
||||||
from cinder import exception
|
from cinder import exception
|
||||||
from cinder import service_auth
|
from cinder import service_auth
|
||||||
from cinder.tests.unit import test
|
from cinder.tests.unit import test
|
||||||
|
|
||||||
CONF = cfg.CONF
|
|
||||||
|
|
||||||
|
|
||||||
class ServiceAuthTestCase(test.TestCase):
|
class ServiceAuthTestCase(test.TestCase):
|
||||||
|
|
||||||
|
|
|
@ -14,15 +14,12 @@
|
||||||
# under the License.
|
# under the License.
|
||||||
import json
|
import json
|
||||||
|
|
||||||
from oslo_config import cfg
|
|
||||||
import requests
|
import requests
|
||||||
import six
|
import six
|
||||||
|
|
||||||
from cinder.volume.drivers.dell_emc.powerflex import driver
|
from cinder.volume.drivers.dell_emc.powerflex import driver
|
||||||
from cinder.volume.drivers.dell_emc.powerflex import rest_client
|
from cinder.volume.drivers.dell_emc.powerflex import rest_client
|
||||||
|
|
||||||
CONF = cfg.CONF
|
|
||||||
|
|
||||||
|
|
||||||
class PowerFlexDriver(driver.PowerFlexDriver):
|
class PowerFlexDriver(driver.PowerFlexDriver):
|
||||||
"""Mock PowerFlex Driver class.
|
"""Mock PowerFlex Driver class.
|
||||||
|
|
|
@ -22,7 +22,6 @@ from unittest import mock
|
||||||
|
|
||||||
import ddt
|
import ddt
|
||||||
import eventlet
|
import eventlet
|
||||||
from oslo_config import cfg
|
|
||||||
import requests
|
import requests
|
||||||
|
|
||||||
from cinder import context
|
from cinder import context
|
||||||
|
@ -35,8 +34,6 @@ from cinder.volume.drivers.inspur.as13000 import as13000_driver
|
||||||
from cinder.volume import volume_utils
|
from cinder.volume import volume_utils
|
||||||
|
|
||||||
|
|
||||||
CONF = cfg.CONF
|
|
||||||
|
|
||||||
test_config = configuration.Configuration(None)
|
test_config = configuration.Configuration(None)
|
||||||
test_config.san_ip = 'some_ip'
|
test_config.san_ip = 'some_ip'
|
||||||
test_config.san_api_port = 'as13000_api_port'
|
test_config.san_api_port = 'as13000_api_port'
|
||||||
|
|
|
@ -18,7 +18,6 @@ import time
|
||||||
from unittest import mock
|
from unittest import mock
|
||||||
|
|
||||||
import ddt
|
import ddt
|
||||||
from oslo_config import cfg
|
|
||||||
from oslo_utils import units
|
from oslo_utils import units
|
||||||
|
|
||||||
from cinder import context
|
from cinder import context
|
||||||
|
@ -34,8 +33,6 @@ from cinder.volume.drivers.kaminario import kaminario_fc
|
||||||
from cinder.volume.drivers.kaminario import kaminario_iscsi
|
from cinder.volume.drivers.kaminario import kaminario_iscsi
|
||||||
from cinder.volume import volume_utils
|
from cinder.volume import volume_utils
|
||||||
|
|
||||||
CONF = cfg.CONF
|
|
||||||
|
|
||||||
CONNECTOR = {'initiator': 'iqn.1993-08.org.debian:01:12aa12aa12aa',
|
CONNECTOR = {'initiator': 'iqn.1993-08.org.debian:01:12aa12aa12aa',
|
||||||
'ip': '192.168.2.5', 'platform': 'x86_64', 'host': 'test-k2',
|
'ip': '192.168.2.5', 'platform': 'x86_64', 'host': 'test-k2',
|
||||||
'wwpns': ['12341a2a00001234', '12341a2a00001235'],
|
'wwpns': ['12341a2a00001234', '12341a2a00001235'],
|
||||||
|
|
|
@ -15,7 +15,6 @@
|
||||||
|
|
||||||
from unittest import mock
|
from unittest import mock
|
||||||
|
|
||||||
from oslo_config import cfg
|
|
||||||
from oslo_utils import timeutils
|
from oslo_utils import timeutils
|
||||||
|
|
||||||
from cinder import exception as cinder_exception
|
from cinder import exception as cinder_exception
|
||||||
|
@ -23,8 +22,6 @@ from cinder.tests.unit import test
|
||||||
from cinder.volume import configuration as conf
|
from cinder.volume import configuration as conf
|
||||||
from cinder.volume.drivers import linstordrv as drv
|
from cinder.volume.drivers import linstordrv as drv
|
||||||
|
|
||||||
CONF = cfg.CONF
|
|
||||||
|
|
||||||
CINDER_UNKNOWN = 'unknown'
|
CINDER_UNKNOWN = 'unknown'
|
||||||
DISKLESS = 'DISKLESS'
|
DISKLESS = 'DISKLESS'
|
||||||
LVM = 'LVM'
|
LVM = 'LVM'
|
||||||
|
|
|
@ -21,7 +21,6 @@ from ddt import ddt
|
||||||
from ddt import unpack
|
from ddt import unpack
|
||||||
import eventlet
|
import eventlet
|
||||||
from lxml import etree as ET
|
from lxml import etree as ET
|
||||||
from oslo_config import cfg
|
|
||||||
from oslo_utils import units
|
from oslo_utils import units
|
||||||
import requests
|
import requests
|
||||||
import six
|
import six
|
||||||
|
@ -33,8 +32,6 @@ from cinder import utils
|
||||||
from cinder.volume import driver
|
from cinder.volume import driver
|
||||||
from cinder.volume.drivers import qnap
|
from cinder.volume.drivers import qnap
|
||||||
|
|
||||||
CONF = cfg.CONF
|
|
||||||
|
|
||||||
FAKE_LUNNAA = {'LUNNAA': 'fakeLunNaa'}
|
FAKE_LUNNAA = {'LUNNAA': 'fakeLunNaa'}
|
||||||
FAKE_SNAPSHOT = {'snapshot_id': 'fakeSnapshotId'}
|
FAKE_SNAPSHOT = {'snapshot_id': 'fakeSnapshotId'}
|
||||||
|
|
||||||
|
|
|
@ -19,7 +19,6 @@ import tempfile
|
||||||
from unittest import mock
|
from unittest import mock
|
||||||
from xml.dom.minidom import Document
|
from xml.dom.minidom import Document
|
||||||
|
|
||||||
from oslo_config import cfg
|
|
||||||
from oslo_utils.secretutils import md5
|
from oslo_utils.secretutils import md5
|
||||||
import requests
|
import requests
|
||||||
|
|
||||||
|
@ -29,7 +28,6 @@ from cinder.tests.unit import test
|
||||||
from cinder.volume import configuration as conf
|
from cinder.volume import configuration as conf
|
||||||
from cinder.volume.drivers.veritas_access import veritas_iscsi
|
from cinder.volume.drivers.veritas_access import veritas_iscsi
|
||||||
|
|
||||||
CONF = cfg.CONF
|
|
||||||
FAKE_BACKEND = 'fake_backend'
|
FAKE_BACKEND = 'fake_backend'
|
||||||
|
|
||||||
|
|
||||||
|
|
|
@ -26,7 +26,6 @@ Limitations:
|
||||||
import random
|
import random
|
||||||
import threading
|
import threading
|
||||||
|
|
||||||
from oslo_config import cfg
|
|
||||||
from oslo_log import log as logging
|
from oslo_log import log as logging
|
||||||
from oslo_utils import excutils
|
from oslo_utils import excutils
|
||||||
import six
|
import six
|
||||||
|
@ -41,8 +40,6 @@ from cinder.zonemanager import utils as fczm_utils
|
||||||
|
|
||||||
LOG = logging.getLogger(__name__)
|
LOG = logging.getLogger(__name__)
|
||||||
|
|
||||||
CONF = cfg.CONF
|
|
||||||
|
|
||||||
|
|
||||||
@interface.volumedriver
|
@interface.volumedriver
|
||||||
class FlashSystemFCDriver(fscommon.FlashSystemDriver):
|
class FlashSystemFCDriver(fscommon.FlashSystemDriver):
|
||||||
|
|
|
@ -17,7 +17,6 @@
|
||||||
FC volume driver for Inspur InStorage family storage systems.
|
FC volume driver for Inspur InStorage family storage systems.
|
||||||
"""
|
"""
|
||||||
|
|
||||||
from oslo_config import cfg
|
|
||||||
from oslo_log import log as logging
|
from oslo_log import log as logging
|
||||||
from oslo_utils import excutils
|
from oslo_utils import excutils
|
||||||
|
|
||||||
|
@ -32,8 +31,6 @@ from cinder.zonemanager import utils as fczm_utils
|
||||||
|
|
||||||
LOG = logging.getLogger(__name__)
|
LOG = logging.getLogger(__name__)
|
||||||
|
|
||||||
CONF = cfg.CONF
|
|
||||||
|
|
||||||
|
|
||||||
@interface.volumedriver
|
@interface.volumedriver
|
||||||
class InStorageMCSFCDriver(instorage_common.InStorageMCSCommonDriver,
|
class InStorageMCSFCDriver(instorage_common.InStorageMCSCommonDriver,
|
||||||
|
|
Loading…
Reference in New Issue