Prepare for functional testing

Prepare for functional testing by creating two new directories:
  * ironic/tests/unit
  * ironic/tests/functional

Move all files currently in ironic/tests/* to ironic/tests/unit/

Update imports from 'ironic.tests.YYY' to 'ironic.tests.unit.YYY'

Fix any PEP8 issues due to longer lines

Partial-Bug: #1491670
Change-Id: I1166f20adf8c84b2042b62e348926502a4851e08
This commit is contained in:
John L. Villalovos 2015-09-28 11:36:37 -07:00 committed by John L. Villalovos
parent efb8b2abb6
commit f350d87af8
142 changed files with 343 additions and 335 deletions

View File

@ -1,4 +1,4 @@
[DEFAULT]
test_command=OS_STDOUT_CAPTURE=${OS_STDOUT_CAPTURE:-1} OS_STDERR_CAPTURE=${OS_STDERR_CAPTURE:-1} OS_TEST_TIMEOUT=60 ${PYTHON:-python} -m subunit.run discover -t ./ ${TESTS_DIR:-./ironic/tests/} $LISTOPT $IDOPTION
test_command=OS_STDOUT_CAPTURE=${OS_STDOUT_CAPTURE:-1} OS_STDERR_CAPTURE=${OS_STDERR_CAPTURE:-1} OS_TEST_TIMEOUT=60 ${PYTHON:-python} -m subunit.run discover -t ./ ${TESTS_DIR:-./ironic/tests/unit/} $LISTOPT $IDOPTION
test_id_option=--load-list $IDFILE
test_list_option=--list

View File

@ -1,34 +0,0 @@
# Copyright 2010 United States Government as represented by the
# Administrator of the National Aeronautics and Space Administration.
# 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.
"""
:mod:`Ironic.tests` -- ironic Unittests
=====================================================
.. automodule:: ironic.tests
:platform: Unix
"""
# TODO(deva): move eventlet imports to ironic.__init__ once we move to PBR
import eventlet
eventlet.monkey_patch(os=False)
# See http://code.google.com/p/python-nose/issues/detail?id=373
# The code below enables nosetests to work with i18n _() blocks
import six.moves.builtins as __builtin__
setattr(__builtin__, '_', lambda x: x)

View File

@ -0,0 +1,34 @@
# Copyright 2010 United States Government as represented by the
# Administrator of the National Aeronautics and Space Administration.
# 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.
"""
:mod:`Ironic.tests` -- ironic Unittests
=====================================================
.. automodule:: ironic.tests.unit
:platform: Unix
"""
# TODO(deva): move eventlet imports to ironic.__init__ once we move to PBR
import eventlet
eventlet.monkey_patch(os=False)
# See http://code.google.com/p/python-nose/issues/detail?id=373
# The code below enables nosetests to work with i18n _() blocks
import six.moves.builtins as __builtin__
setattr(__builtin__, '_', lambda x: x)

View File

@ -26,7 +26,7 @@ import pecan
import pecan.testing
from six.moves.urllib import parse as urlparse
from ironic.tests.db import base
from ironic.tests.unit.db import base
PATH_PREFIX = '/v1'

View File

@ -20,9 +20,9 @@ import mock
from oslo_config import cfg
from six.moves import http_client
from ironic.tests.api import base
from ironic.tests.api import utils
from ironic.tests.db import utils as db_utils
from ironic.tests.unit.api import base
from ironic.tests.unit.api import utils
from ironic.tests.unit.db import utils as db_utils
cfg.CONF.import_opt('cache', 'keystonemiddleware.auth_token',
group='keystone_authtoken')

View File

@ -18,7 +18,7 @@ from six.moves import http_client
from webob import exc
from ironic.api.controllers import base as cbase
from ironic.tests.api import base
from ironic.tests.unit.api import base
class TestBase(base.FunctionalTest):

View File

@ -26,8 +26,8 @@ from webob import exc as webob_exc
from ironic.api.controllers import root
from ironic.api import hooks
from ironic.common import context
from ironic.tests.api import base
from ironic.tests import policy_fixture
from ironic.tests.unit.api import base
from ironic.tests.unit import policy_fixture
class FakeRequest(object):

View File

@ -13,7 +13,7 @@
# License for the specific language governing permissions and limitations
# under the License.
from ironic.tests.api import base
from ironic.tests.unit.api import base
class TestRoot(base.FunctionalTest):

View File

@ -22,7 +22,7 @@ import json
from ironic.api.controllers.v1 import chassis as chassis_controller
from ironic.api.controllers.v1 import node as node_controller
from ironic.api.controllers.v1 import port as port_controller
from ironic.tests.db import utils
from ironic.tests.unit.db import utils
ADMIN_TOKEN = '4562138218392831'
MEMBER_TOKEN = '4562138218392832'

View File

@ -29,10 +29,10 @@ from wsme import types as wtypes
from ironic.api.controllers import base as api_base
from ironic.api.controllers import v1 as api_v1
from ironic.api.controllers.v1 import chassis as api_chassis
from ironic.tests.api import base as test_api_base
from ironic.tests.api import utils as apiutils
from ironic.tests import base
from ironic.tests.objects import utils as obj_utils
from ironic.tests.unit.api import base as test_api_base
from ironic.tests.unit.api import utils as apiutils
from ironic.tests.unit import base
from ironic.tests.unit.objects import utils as obj_utils
class TestChassisObject(base.TestCase):

View File

@ -24,7 +24,7 @@ from ironic.api.controllers import base as api_base
from ironic.api.controllers.v1 import driver
from ironic.common import exception
from ironic.conductor import rpcapi
from ironic.tests.api import base
from ironic.tests.unit.api import base
class TestListDrivers(base.FunctionalTest):

View File

@ -37,10 +37,10 @@ from ironic.common import exception
from ironic.common import states
from ironic.conductor import rpcapi
from ironic import objects
from ironic.tests.api import base as test_api_base
from ironic.tests.api import utils as test_api_utils
from ironic.tests import base
from ironic.tests.objects import utils as obj_utils
from ironic.tests.unit.api import base as test_api_base
from ironic.tests.unit.api import utils as test_api_utils
from ironic.tests.unit import base
from ironic.tests.unit.objects import utils as obj_utils
class TestNodeObject(base.TestCase):

View File

@ -33,11 +33,11 @@ from ironic.api.controllers.v1 import port as api_port
from ironic.api.controllers.v1 import utils as api_utils
from ironic.common import exception
from ironic.conductor import rpcapi
from ironic.tests.api import base as test_api_base
from ironic.tests.api import utils as apiutils
from ironic.tests import base
from ironic.tests.db import utils as dbutils
from ironic.tests.objects import utils as obj_utils
from ironic.tests.unit.api import base as test_api_base
from ironic.tests.unit.api import utils as apiutils
from ironic.tests.unit import base
from ironic.tests.unit.db import utils as dbutils
from ironic.tests.unit.objects import utils as obj_utils
# NOTE(lucasagomes): When creating a port via API (POST)

View File

@ -16,8 +16,8 @@ import mock
from webob import exc as webob_exc
from ironic.api.controllers import v1 as v1_api
from ironic.tests.api import base as api_base
from ironic.tests import base as test_base
from ironic.tests.unit.api import base as api_base
from ironic.tests.unit import base as test_base
class TestV1Routing(api_base.FunctionalTest):

View File

@ -25,7 +25,7 @@ from wsme import types as wtypes
from ironic.api.controllers.v1 import types
from ironic.common import exception
from ironic.common import utils
from ironic.tests import base
from ironic.tests.unit import base
class TestMacAddressType(base.TestCase):

View File

@ -25,8 +25,8 @@ import wsme
from ironic.api.controllers.v1 import utils
from ironic.common import exception
from ironic import objects
from ironic.tests.api import utils as test_api_utils
from ironic.tests import base
from ironic.tests.unit.api import utils as test_api_utils
from ironic.tests.unit import base
CONF = cfg.CONF

View File

@ -18,7 +18,7 @@ Tests for the versions constants and methods.
import re
from ironic.api.controllers.v1 import versions
from ironic.tests import base
from ironic.tests.unit import base
class TestVersionConstants(base.TestCase):

View File

@ -36,8 +36,8 @@ import testtools
from ironic.common import hash_ring
from ironic.objects import base as objects_base
from ironic.tests import conf_fixture
from ironic.tests import policy_fixture
from ironic.tests.unit import conf_fixture
from ironic.tests.unit import policy_fixture
CONF = cfg.CONF

View File

@ -16,7 +16,7 @@
# under the License.
from ironic.db import migration
from ironic.tests.db import base
from ironic.tests.unit.db import base
class DbSyncTestCase(base.DbTestCase):

View File

@ -20,7 +20,7 @@ from testtools.matchers import HasLength
from ironic.common import disk_partitioner
from ironic.common import exception
from ironic.common import utils
from ironic.tests import base
from ironic.tests.unit import base
@mock.patch.object(eventlet.greenthread, 'sleep', lambda seconds: None)

View File

@ -17,7 +17,7 @@ from stevedore import dispatch
from ironic.common import driver_factory
from ironic.common import exception
from ironic.tests import base
from ironic.tests.unit import base
class FakeEp(object):

View File

@ -15,7 +15,7 @@
import six
from ironic.common import exception
from ironic.tests import base
from ironic.tests.unit import base
class TestIronicException(base.TestCase):

View File

@ -15,7 +15,7 @@
# under the License.
from ironic.common import fsm
from ironic.tests import base
from ironic.tests.unit import base
class FSMTest(base.TestCase):

View File

@ -31,8 +31,8 @@ from ironic.common import exception
from ironic.common.glance_service import base_image_service
from ironic.common.glance_service import service_utils
from ironic.common import image_service as service
from ironic.tests import base
from ironic.tests import stubs
from ironic.tests.unit import base
from ironic.tests.unit import stubs
CONF = cfg.CONF

View File

@ -21,8 +21,8 @@ from testtools import matchers
from ironic.common import exception
from ironic.common import hash_ring
from ironic.tests import base
from ironic.tests.db import base as db_base
from ironic.tests.unit import base
from ironic.tests.unit.db import base as db_base
CONF = cfg.CONF

View File

@ -25,7 +25,7 @@ from ironic.common import exception
from ironic.common.glance_service.v1 import image_service as glance_v1_service
from ironic.common import image_service
from ironic.common import keystone
from ironic.tests import base
from ironic.tests.unit import base
if six.PY3:
import io

View File

@ -31,7 +31,7 @@ from ironic.common import image_service
from ironic.common import images
from ironic.common import utils
from ironic.openstack.common import imageutils
from ironic.tests import base
from ironic.tests.unit import base
if six.PY3:
import io

View File

@ -17,7 +17,7 @@ import mock
from ironic.common import exception
from ironic.common import keystone
from ironic.tests import base
from ironic.tests.unit import base
class FakeCatalog(object):

View File

@ -17,10 +17,10 @@ from oslo_utils import uuidutils
from ironic.common import network
from ironic.conductor import task_manager
from ironic.tests.conductor import utils as mgr_utils
from ironic.tests.db import base as db_base
from ironic.tests.db import utils as db_utils
from ironic.tests.objects import utils as object_utils
from ironic.tests.unit.conductor import utils as mgr_utils
from ironic.tests.unit.db import base as db_base
from ironic.tests.unit.db import utils as db_utils
from ironic.tests.unit.objects import utils as object_utils
class TestNetwork(db_base.DbTestCase):

View File

@ -16,7 +16,7 @@
# under the License.
from ironic.common import policy
from ironic.tests import base
from ironic.tests.unit import base
class PolicyTestCase(base.TestCase):

View File

@ -22,9 +22,9 @@ import six
from ironic.common import pxe_utils
from ironic.conductor import task_manager
from ironic.tests.conductor import utils as mgr_utils
from ironic.tests.db import base as db_base
from ironic.tests.objects import utils as object_utils
from ironic.tests.unit.conductor import utils as mgr_utils
from ironic.tests.unit.db import base as db_base
from ironic.tests.unit.objects import utils as object_utils
CONF = cfg.CONF
@ -93,7 +93,7 @@ class TestPXEUtils(db_base.DbTestCase):
'{{ ROOT }}', '{{ DISK_IDENTIFIER }}')
expected_template = open(
'ironic/tests/drivers/pxe_config.template').read().rstrip()
'ironic/tests/unit/drivers/pxe_config.template').read().rstrip()
self.assertEqual(six.text_type(expected_template), rendered_template)
@ -103,8 +103,8 @@ class TestPXEUtils(db_base.DbTestCase):
self.agent_pxe_options, CONF.agent.agent_pxe_config_template,
'{{ ROOT }}', '{{ DISK_IDENTIFIER }}')
expected_template = open(
'ironic/tests/drivers/agent_pxe_config.template').read().rstrip()
template_file = 'ironic/tests/unit/drivers/agent_pxe_config.template'
expected_template = open(template_file).read().rstrip()
self.assertEqual(six.text_type(expected_template), rendered_template)
@ -123,7 +123,7 @@ class TestPXEUtils(db_base.DbTestCase):
'{{ ROOT }}', '{{ DISK_IDENTIFIER }}')
expected_template = open(
'ironic/tests/drivers/ipxe_config.template').read().rstrip()
'ironic/tests/unit/drivers/ipxe_config.template').read().rstrip()
self.assertEqual(six.text_type(expected_template), rendered_template)
@ -135,7 +135,7 @@ class TestPXEUtils(db_base.DbTestCase):
'{{ ROOT }}', '{{ DISK_IDENTIFIER }}')
expected_template = open(
'ironic/tests/drivers/elilo_efi_pxe_config.template'
'ironic/tests/unit/drivers/elilo_efi_pxe_config.template'
).read().rstrip()
self.assertEqual(six.text_type(expected_template), rendered_template)
@ -148,8 +148,8 @@ class TestPXEUtils(db_base.DbTestCase):
rendered_template = pxe_utils._build_pxe_config(
pxe_opts, grub_tmplte, '(( ROOT ))', '(( DISK_IDENTIFIER ))')
expected_template = open(
'ironic/tests/drivers/pxe_grub_config.template').read().rstrip()
template_file = 'ironic/tests/unit/drivers/pxe_grub_config.template'
expected_template = open(template_file).read().rstrip()
self.assertEqual(six.text_type(expected_template), rendered_template)

View File

@ -17,10 +17,10 @@ import json
from ironic.common import exception
from ironic.common import raid
from ironic.drivers import base as drivers_base
from ironic.tests import base
from ironic.tests.db import base as db_base
from ironic.tests.objects import utils as obj_utils
from ironic.tests import raid_constants
from ironic.tests.unit import base
from ironic.tests.unit.db import base as db_base
from ironic.tests.unit.objects import utils as obj_utils
from ironic.tests.unit import raid_constants
class ValidateRaidConfigurationTestCase(base.TestCase):

View File

@ -17,7 +17,7 @@
import six
from ironic.common import states
from ironic.tests import base
from ironic.tests.unit import base
class StatesTest(base.TestCase):

View File

@ -24,7 +24,7 @@ from swiftclient import utils as swift_utils
from ironic.common import exception
from ironic.common import swift
from ironic.tests import base
from ironic.tests.unit import base
CONF = cfg.CONF

View File

@ -30,7 +30,7 @@ import six.moves.builtins as __builtin__
from ironic.common import exception
from ironic.common import utils
from ironic.tests import base
from ironic.tests.unit import base
CONF = cfg.CONF

View File

@ -19,11 +19,11 @@ from ironic.common import states
from ironic.conductor import task_manager
from ironic.conductor import utils as conductor_utils
from ironic import objects
from ironic.tests import base as tests_base
from ironic.tests.conductor import utils as mgr_utils
from ironic.tests.db import base
from ironic.tests.db import utils
from ironic.tests.objects import utils as obj_utils
from ironic.tests.unit import base as tests_base
from ironic.tests.unit.conductor import utils as mgr_utils
from ironic.tests.unit.db import base
from ironic.tests.unit.db import utils
from ironic.tests.unit.objects import utils as obj_utils
class NodeSetBootDeviceTestCase(base.DbTestCase):

View File

@ -44,11 +44,11 @@ from ironic.drivers import base as drivers_base
from ironic.drivers.modules import fake
from ironic import objects
from ironic.objects import base as obj_base
from ironic.tests import base as tests_base
from ironic.tests.conductor import utils as mgr_utils
from ironic.tests.db import base as tests_db_base
from ironic.tests.db import utils
from ironic.tests.objects import utils as obj_utils
from ironic.tests.unit import base as tests_base
from ironic.tests.unit.conductor import utils as mgr_utils
from ironic.tests.unit.db import base as tests_db_base
from ironic.tests.unit.db import utils
from ironic.tests.unit.objects import utils as obj_utils
CONF = cfg.CONF
@ -238,8 +238,8 @@ class StartStopTestCase(_ServiceSetUpMixin, tests_db_base.DbTestCase):
@mock.patch.object(driver_factory.DriverFactory, '__getitem__')
def test_start_registers_driver_specific_tasks(self, get_mock):
init_names = ['fake1']
expected_task_name = 'ironic.tests.conductor.test_manager.task'
expected_task_name2 = 'ironic.tests.conductor.test_manager.iface'
expected_task_name = 'ironic.tests.unit.conductor.test_manager.task'
expected_task_name2 = 'ironic.tests.unit.conductor.test_manager.iface'
self.config(enabled_drivers=init_names)
class TestInterface(object):

View File

@ -30,9 +30,9 @@ from ironic.common import states
from ironic.conductor import manager as conductor_manager
from ironic.conductor import rpcapi as conductor_rpcapi
from ironic import objects
from ironic.tests import base as tests_base
from ironic.tests.db import base
from ironic.tests.db import utils as dbutils
from ironic.tests.unit import base as tests_base
from ironic.tests.unit.db import base
from ironic.tests.unit.db import utils as dbutils
CONF = cfg.CONF

View File

@ -28,9 +28,9 @@ from ironic.common import fsm
from ironic.common import states
from ironic.conductor import task_manager
from ironic import objects
from ironic.tests import base as tests_base
from ironic.tests.db import base as tests_db_base
from ironic.tests.objects import utils as obj_utils
from ironic.tests.unit import base as tests_base
from ironic.tests.unit.db import base as tests_db_base
from ironic.tests.unit.objects import utils as obj_utils
@mock.patch.object(objects.Node, 'get')

View File

@ -17,8 +17,8 @@
"""Tests for Ironic Manager test utils."""
from ironic.tests import base
from ironic.tests.conductor import utils
from ironic.tests.unit import base
from ironic.tests.unit.conductor import utils
class UtilsTestCase(base.TestCase):

View File

@ -13,4 +13,4 @@
# 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 ironic.tests.db import *
from ironic.tests.unit.db import *

View File

@ -26,7 +26,7 @@ from ironic.common import paths
from ironic.db import api as dbapi
from ironic.db.sqlalchemy import migration
from ironic.db.sqlalchemy import models
from ironic.tests import base
from ironic.tests.unit import base
CONF = cfg.CONF

View File

@ -51,7 +51,7 @@ import sqlalchemy.exc
from ironic.common.i18n import _LE
from ironic.db.sqlalchemy import migration
from ironic.db.sqlalchemy import models
from ironic.tests import base
from ironic.tests.unit import base
LOG = logging.getLogger(__name__)

View File

@ -17,7 +17,7 @@ from oslo_utils import uuidutils
import ironic.db.sqlalchemy.api as sa_api
from ironic.db.sqlalchemy import models
from ironic.tests.db import base
from ironic.tests.unit.db import base
class SqlAlchemyCustomTypesTestCase(base.DbTestCase):

View File

@ -19,8 +19,8 @@ from oslo_utils import uuidutils
import six
from ironic.common import exception
from ironic.tests.db import base
from ironic.tests.db import utils
from ironic.tests.unit.db import base
from ironic.tests.unit.db import utils
class DbChassisTestCase(base.DbTestCase):

View File

@ -21,8 +21,8 @@ import mock
from oslo_utils import timeutils
from ironic.common import exception
from ironic.tests.db import base
from ironic.tests.db import utils
from ironic.tests.unit.db import base
from ironic.tests.unit.db import utils
class DbConductorTestCase(base.DbTestCase):

View File

@ -24,8 +24,8 @@ import six
from ironic.common import exception
from ironic.common import states
from ironic.tests.db import base
from ironic.tests.db import utils
from ironic.tests.unit.db import base
from ironic.tests.unit.db import utils
class DbNodeTestCase(base.DbTestCase):

View File

@ -19,8 +19,8 @@ from oslo_utils import uuidutils
import six
from ironic.common import exception
from ironic.tests.db import base
from ironic.tests.db import utils as db_utils
from ironic.tests.unit.db import base
from ironic.tests.unit.db import utils as db_utils
class DbPortTestCase(base.DbTestCase):

View File

@ -23,7 +23,7 @@ from ironic.common import exception
from ironic.dhcp import base as base_class
from ironic.dhcp import neutron
from ironic.dhcp import none
from ironic.tests import base
from ironic.tests.unit import base
class TestDHCPFactory(base.TestCase):

View File

@ -24,9 +24,9 @@ from ironic.common import exception
from ironic.common import pxe_utils
from ironic.conductor import task_manager
from ironic.dhcp import neutron
from ironic.tests.conductor import utils as mgr_utils
from ironic.tests.db import base as db_base
from ironic.tests.objects import utils as object_utils
from ironic.tests.unit.conductor import utils as mgr_utils
from ironic.tests.unit.db import base as db_base
from ironic.tests.unit.objects import utils as object_utils
class TestNeutron(db_base.DbTestCase):

View File

@ -18,4 +18,4 @@
# external libraries mocked, we load the file which does that
# mocking here -- in the __init__.
from ironic.tests.drivers import third_party_driver_mocks # noqa
from ironic.tests.unit.drivers import third_party_driver_mocks # noqa

View File

@ -21,12 +21,13 @@ from oslo_config import cfg
from ironic.common import exception
from ironic.drivers.modules.amt import common as amt_common
from ironic.drivers.modules.amt import resource_uris
from ironic.tests import base
from ironic.tests.db import base as db_base
from ironic.tests.db import utils as db_utils
from ironic.tests.drivers.drac import utils as test_utils
from ironic.tests.drivers import third_party_driver_mock_specs as mock_specs
from ironic.tests.objects import utils as obj_utils
from ironic.tests.unit import base
from ironic.tests.unit.db import base as db_base
from ironic.tests.unit.db import utils as db_utils
from ironic.tests.unit.drivers.drac import utils as test_utils
from ironic.tests.unit.drivers import third_party_driver_mock_specs \
as mock_specs
from ironic.tests.unit.objects import utils as obj_utils
INFO_DICT = db_utils.get_test_amt_info()
CONF = cfg.CONF

View File

@ -24,12 +24,13 @@ from ironic.conductor import task_manager
from ironic.drivers.modules.amt import common as amt_common
from ironic.drivers.modules.amt import management as amt_mgmt
from ironic.drivers.modules.amt import resource_uris
from ironic.tests.conductor import utils as mgr_utils
from ironic.tests.db import base as db_base
from ironic.tests.db import utils as db_utils
from ironic.tests.drivers.drac import utils as test_utils
from ironic.tests.drivers import third_party_driver_mock_specs as mock_specs
from ironic.tests.objects import utils as obj_utils
from ironic.tests.unit.conductor import utils as mgr_utils
from ironic.tests.unit.db import base as db_base
from ironic.tests.unit.db import utils as db_utils
from ironic.tests.unit.drivers.drac import utils as test_utils
from ironic.tests.unit.drivers import third_party_driver_mock_specs \
as mock_specs
from ironic.tests.unit.objects import utils as obj_utils
INFO_DICT = db_utils.get_test_amt_info()
CONF = cfg.CONF

View File

@ -26,11 +26,11 @@ from ironic.drivers.modules.amt import common as amt_common
from ironic.drivers.modules.amt import management as amt_mgmt
from ironic.drivers.modules.amt import power as amt_power
from ironic.drivers.modules.amt import resource_uris
from ironic.tests.conductor import utils as mgr_utils
from ironic.tests.db import base as db_base
from ironic.tests.db import utils as db_utils
from ironic.tests.drivers.drac import utils as test_utils
from ironic.tests.objects import utils as obj_utils
from ironic.tests.unit.conductor import utils as mgr_utils
from ironic.tests.unit.db import base as db_base
from ironic.tests.unit.db import utils as db_utils
from ironic.tests.unit.drivers.drac import utils as test_utils
from ironic.tests.unit.objects import utils as obj_utils
INFO_DICT = db_utils.get_test_amt_info()
CONF = cfg.CONF

View File

@ -20,10 +20,10 @@ from ironic.common import states
from ironic.conductor import task_manager
from ironic.drivers.modules.amt import management as amt_mgmt
from ironic.drivers.modules import iscsi_deploy
from ironic.tests.conductor import utils as mgr_utils
from ironic.tests.db import base as db_base
from ironic.tests.db import utils as db_utils
from ironic.tests.objects import utils as obj_utils
from ironic.tests.unit.conductor import utils as mgr_utils
from ironic.tests.unit.db import base as db_base
from ironic.tests.unit.db import utils as db_utils
from ironic.tests.unit.objects import utils as obj_utils
INFO_DICT = db_utils.get_test_amt_info()

View File

@ -20,10 +20,10 @@ from oslo_utils import importutils
from ironic.common import exception
from ironic.conductor import task_manager
from ironic.drivers.modules.cimc import common as cimc_common
from ironic.tests.conductor import utils as mgr_utils
from ironic.tests.db import base as db_base
from ironic.tests.db import utils as db_utils
from ironic.tests.objects import utils as obj_utils
from ironic.tests.unit.conductor import utils as mgr_utils
from ironic.tests.unit.db import base as db_base
from ironic.tests.unit.db import utils as db_utils
from ironic.tests.unit.objects import utils as obj_utils
imcsdk = importutils.try_import('ImcSdk')

View File

@ -20,7 +20,7 @@ from ironic.common import boot_devices
from ironic.common import exception
from ironic.conductor import task_manager
from ironic.drivers.modules.cimc import common
from ironic.tests.drivers.cimc import test_common
from ironic.tests.unit.drivers.cimc import test_common
imcsdk = importutils.try_import('ImcSdk')

View File

@ -22,7 +22,7 @@ from ironic.common import states
from ironic.conductor import task_manager
from ironic.drivers.modules.cimc import common
from ironic.drivers.modules.cimc import power
from ironic.tests.drivers.cimc import test_common
from ironic.tests.unit.drivers.cimc import test_common
imcsdk = importutils.try_import('ImcSdk')

View File

@ -27,12 +27,12 @@ from ironic.drivers.modules.drac import bios
from ironic.drivers.modules.drac import client as drac_client
from ironic.drivers.modules.drac import management as drac_mgmt
from ironic.drivers.modules.drac import resource_uris
from ironic.tests.conductor import utils as mgr_utils
from ironic.tests.db import base as db_base
from ironic.tests.db import utils as db_utils
from ironic.tests.drivers.drac import bios_wsman_mock
from ironic.tests.drivers.drac import utils as test_utils
from ironic.tests.objects import utils as obj_utils
from ironic.tests.unit.conductor import utils as mgr_utils
from ironic.tests.unit.db import base as db_base
from ironic.tests.unit.db import utils as db_utils
from ironic.tests.unit.drivers.drac import bios_wsman_mock
from ironic.tests.unit.drivers.drac import utils as test_utils
from ironic.tests.unit.objects import utils as obj_utils
from six.moves.urllib.parse import unquote
FAKE_DRAC = db_utils.get_test_drac_info()

View File

@ -22,10 +22,11 @@ import mock
from ironic.common import exception
from ironic.drivers.modules.drac import client as drac_client
from ironic.tests import base
from ironic.tests.db import utils as db_utils
from ironic.tests.drivers.drac import utils as test_utils
from ironic.tests.drivers import third_party_driver_mock_specs as mock_specs
from ironic.tests.unit import base
from ironic.tests.unit.db import utils as db_utils
from ironic.tests.unit.drivers.drac import utils as test_utils
from ironic.tests.unit.drivers import third_party_driver_mock_specs \
as mock_specs
INFO_DICT = db_utils.get_test_drac_info()

View File

@ -21,9 +21,9 @@ from testtools.matchers import HasLength
from ironic.common import exception
from ironic.drivers.modules.drac import common as drac_common
from ironic.tests.db import base as db_base
from ironic.tests.db import utils as db_utils
from ironic.tests.objects import utils as obj_utils
from ironic.tests.unit.db import base as db_base
from ironic.tests.unit.db import utils as db_utils
from ironic.tests.unit.objects import utils as obj_utils
INFO_DICT = db_utils.get_test_drac_info()

View File

@ -28,12 +28,13 @@ from ironic.drivers.modules.drac import client as drac_client
from ironic.drivers.modules.drac import common as drac_common
from ironic.drivers.modules.drac import management as drac_mgmt
from ironic.drivers.modules.drac import resource_uris
from ironic.tests.conductor import utils as mgr_utils
from ironic.tests.db import base as db_base
from ironic.tests.db import utils as db_utils
from ironic.tests.drivers.drac import utils as test_utils
from ironic.tests.drivers import third_party_driver_mock_specs as mock_specs
from ironic.tests.objects import utils as obj_utils
from ironic.tests.unit.conductor import utils as mgr_utils
from ironic.tests.unit.db import base as db_base
from ironic.tests.unit.db import utils as db_utils
from ironic.tests.unit.drivers.drac import utils as test_utils
from ironic.tests.unit.drivers import third_party_driver_mock_specs \
as mock_specs
from ironic.tests.unit.objects import utils as obj_utils
INFO_DICT = db_utils.get_test_drac_info()

View File

@ -24,11 +24,12 @@ from ironic.drivers.modules.drac import client as drac_client
from ironic.drivers.modules.drac import common as drac_common
from ironic.drivers.modules.drac import power as drac_power
from ironic.drivers.modules.drac import resource_uris
from ironic.tests.conductor import utils as mgr_utils
from ironic.tests.db import base
from ironic.tests.db import utils as db_utils
from ironic.tests.drivers.drac import utils as test_utils
from ironic.tests.drivers import third_party_driver_mock_specs as mock_specs
from ironic.tests.unit.conductor import utils as mgr_utils
from ironic.tests.unit.db import base
from ironic.tests.unit.db import utils as db_utils
from ironic.tests.unit.drivers.drac import utils as test_utils
from ironic.tests.unit.drivers import third_party_driver_mock_specs \
as mock_specs
INFO_DICT = db_utils.get_test_drac_info()

View File

@ -30,10 +30,10 @@ from ironic.common import swift
from ironic.common import utils
from ironic.conductor import task_manager
from ironic.drivers.modules.ilo import common as ilo_common
from ironic.tests.conductor import utils as mgr_utils
from ironic.tests.db import base as db_base
from ironic.tests.db import utils as db_utils
from ironic.tests.objects import utils as obj_utils
from ironic.tests.unit.conductor import utils as mgr_utils
from ironic.tests.unit.db import base as db_base
from ironic.tests.unit.db import utils as db_utils
from ironic.tests.unit.objects import utils as obj_utils
ilo_client = importutils.try_import('proliantutils.ilo.client')
ilo_error = importutils.try_import('proliantutils.exception')

View File

@ -38,10 +38,10 @@ from ironic.drivers.modules.ilo import common as ilo_common
from ironic.drivers.modules.ilo import deploy as ilo_deploy
from ironic.drivers.modules import iscsi_deploy
from ironic.drivers import utils as driver_utils
from ironic.tests.conductor import utils as mgr_utils
from ironic.tests.db import base as db_base
from ironic.tests.db import utils as db_utils
from ironic.tests.objects import utils as obj_utils
from ironic.tests.unit.conductor import utils as mgr_utils
from ironic.tests.unit.db import base as db_base
from ironic.tests.unit.db import utils as db_utils
from ironic.tests.unit.objects import utils as obj_utils
if six.PY3:

View File

@ -28,10 +28,10 @@ from ironic.db import api as dbapi
from ironic.drivers.modules.ilo import common as ilo_common
from ironic.drivers.modules.ilo import inspect as ilo_inspect
from ironic.drivers.modules.ilo import power as ilo_power
from ironic.tests.conductor import utils as mgr_utils
from ironic.tests.db import base as db_base
from ironic.tests.db import utils as db_utils
from ironic.tests.objects import utils as obj_utils
from ironic.tests.unit.conductor import utils as mgr_utils
from ironic.tests.unit.db import base as db_base
from ironic.tests.unit.db import utils as db_utils
from ironic.tests.unit.objects import utils as obj_utils
INFO_DICT = db_utils.get_test_ilo_info()

View File

@ -24,10 +24,10 @@ from ironic.conductor import task_manager
from ironic.drivers.modules.ilo import common as ilo_common
from ironic.drivers.modules.ilo import management as ilo_management
from ironic.drivers.modules import ipmitool
from ironic.tests.conductor import utils as mgr_utils
from ironic.tests.db import base as db_base
from ironic.tests.db import utils as db_utils
from ironic.tests.objects import utils as obj_utils
from ironic.tests.unit.conductor import utils as mgr_utils
from ironic.tests.unit.db import base as db_base
from ironic.tests.unit.db import utils as db_utils
from ironic.tests.unit.objects import utils as obj_utils
ilo_error = importutils.try_import('proliantutils.exception')

View File

@ -26,10 +26,10 @@ from ironic.conductor import task_manager
from ironic.conductor import utils as manager_utils
from ironic.drivers.modules.ilo import common as ilo_common
from ironic.drivers.modules.ilo import power as ilo_power
from ironic.tests.conductor import utils as mgr_utils
from ironic.tests.db import base as db_base
from ironic.tests.db import utils as db_utils
from ironic.tests.objects import utils as obj_utils
from ironic.tests.unit.conductor import utils as mgr_utils
from ironic.tests.unit.db import base as db_base
from ironic.tests.unit.db import utils as db_utils
from ironic.tests.unit.objects import utils as obj_utils
ilo_error = importutils.try_import('proliantutils.exception')

View File

@ -21,11 +21,12 @@ import mock
from ironic.common import exception
from ironic.conductor import task_manager
from ironic.drivers.modules.irmc import common as irmc_common
from ironic.tests.conductor import utils as mgr_utils
from ironic.tests.db import base as db_base
from ironic.tests.db import utils as db_utils
from ironic.tests.drivers import third_party_driver_mock_specs as mock_specs
from ironic.tests.objects import utils as obj_utils
from ironic.tests.unit.conductor import utils as mgr_utils
from ironic.tests.unit.db import base as db_base
from ironic.tests.unit.db import utils as db_utils
from ironic.tests.unit.drivers import third_party_driver_mock_specs \
as mock_specs
from ironic.tests.unit.objects import utils as obj_utils
class IRMCValidateParametersTestCase(db_base.DbTestCase):

View File

@ -39,10 +39,10 @@ from ironic.drivers.modules import deploy_utils
from ironic.drivers.modules.irmc import common as irmc_common
from ironic.drivers.modules.irmc import deploy as irmc_deploy
from ironic.drivers.modules import iscsi_deploy
from ironic.tests.conductor import utils as mgr_utils
from ironic.tests.db import base as db_base
from ironic.tests.db import utils as db_utils
from ironic.tests.objects import utils as obj_utils
from ironic.tests.unit.conductor import utils as mgr_utils
from ironic.tests.unit.db import base as db_base
from ironic.tests.unit.db import utils as db_utils
from ironic.tests.unit.objects import utils as obj_utils
if six.PY3:

View File

@ -29,11 +29,12 @@ from ironic.drivers.modules import ipmitool
from ironic.drivers.modules.irmc import common as irmc_common
from ironic.drivers.modules.irmc import management as irmc_management
from ironic.drivers import utils as driver_utils
from ironic.tests.conductor import utils as mgr_utils
from ironic.tests.db import base as db_base
from ironic.tests.db import utils as db_utils
from ironic.tests.drivers import third_party_driver_mock_specs as mock_specs
from ironic.tests.objects import utils as obj_utils
from ironic.tests.unit.conductor import utils as mgr_utils
from ironic.tests.unit.db import base as db_base
from ironic.tests.unit.db import utils as db_utils
from ironic.tests.unit.drivers import third_party_driver_mock_specs \
as mock_specs
from ironic.tests.unit.objects import utils as obj_utils
INFO_DICT = db_utils.get_test_irmc_info()

View File

@ -27,10 +27,10 @@ from ironic.conductor import utils as manager_utils
from ironic.drivers.modules.irmc import common as irmc_common
from ironic.drivers.modules.irmc import deploy as irmc_deploy
from ironic.drivers.modules.irmc import power as irmc_power
from ironic.tests.conductor import utils as mgr_utils
from ironic.tests.db import base as db_base
from ironic.tests.db import utils as db_utils
from ironic.tests.objects import utils as obj_utils
from ironic.tests.unit.conductor import utils as mgr_utils
from ironic.tests.unit.db import base as db_base
from ironic.tests.unit.db import utils as db_utils
from ironic.tests.unit.objects import utils as obj_utils
INFO_DICT = db_utils.get_test_irmc_info()
CONF = cfg.CONF

View File

@ -22,10 +22,10 @@ import mock
from ironic.common import exception
from ironic.conductor import task_manager
from ironic.drivers.modules.msftocs import common as msftocs_common
from ironic.tests.conductor import utils as mgr_utils
from ironic.tests.db import base as db_base
from ironic.tests.db import utils as db_utils
from ironic.tests.objects import utils as obj_utils
from ironic.tests.unit.conductor import utils as mgr_utils
from ironic.tests.unit.db import base as db_base
from ironic.tests.unit.db import utils as db_utils
from ironic.tests.unit.objects import utils as obj_utils
INFO_DICT = db_utils.get_test_msftocs_info()

View File

@ -25,10 +25,10 @@ from ironic.conductor import task_manager
from ironic.drivers.modules.msftocs import common as msftocs_common
from ironic.drivers.modules.msftocs import msftocsclient
from ironic.drivers import utils as drivers_utils
from ironic.tests.conductor import utils as mgr_utils
from ironic.tests.db import base as db_base
from ironic.tests.db import utils as db_utils
from ironic.tests.objects import utils as obj_utils
from ironic.tests.unit.conductor import utils as mgr_utils
from ironic.tests.unit.db import base as db_base
from ironic.tests.unit.db import utils as db_utils
from ironic.tests.unit.objects import utils as obj_utils
INFO_DICT = db_utils.get_test_msftocs_info()

View File

@ -23,7 +23,7 @@ from requests import exceptions as requests_exceptions
from ironic.common import exception
from ironic.drivers.modules.msftocs import msftocsclient
from ironic.tests import base
from ironic.tests.unit import base
FAKE_BOOT_RESPONSE = (

View File

@ -24,10 +24,10 @@ from ironic.common import states
from ironic.conductor import task_manager
from ironic.drivers.modules.msftocs import common as msftocs_common
from ironic.drivers.modules.msftocs import msftocsclient
from ironic.tests.conductor import utils as mgr_utils
from ironic.tests.db import base as db_base
from ironic.tests.db import utils as db_utils
from ironic.tests.objects import utils as obj_utils
from ironic.tests.unit.conductor import utils as mgr_utils
from ironic.tests.unit.db import base as db_base
from ironic.tests.unit.db import utils as db_utils
from ironic.tests.unit.objects import utils as obj_utils
INFO_DICT = db_utils.get_test_msftocs_info()

Some files were not shown because too many files have changed in this diff Show More