diff --git a/bin/marconi-self-host b/bin/marconi-self-host index 4487957f8..4684b0115 100644 --- a/bin/marconi-self-host +++ b/bin/marconi-self-host @@ -18,12 +18,12 @@ """Bootstrap for self-hosting a Marconi node Alternatively, to host a WSGI app with an external server, configure -kernel with the WSGI transport and export the WSGI app callable, e.g.: +bootstrap with the WSGI transport and export the WSGI app callable, e.g.: logging.config.fileConfig(logging_conf_file) - kernel = Kernel(conf_file) + boot = Bootstrap(conf_file) - app = kernel.transport.app + app = boot.transport.app """ diff --git a/marconi/__init__.py b/marconi/__init__.py index ff5efd56a..67185ce88 100644 --- a/marconi/__init__.py +++ b/marconi/__init__.py @@ -15,7 +15,7 @@ # Import guard. No module level import during the setup procedure. try: - __MARCONI_SETUP__ + __MARCONI_SETUP__ # NOQA except NameError: import gettext gettext.install("marconi", unicode=1) diff --git a/marconi/tests/storage/base.py b/marconi/tests/storage/base.py index 18c9ac485..149aa0d8f 100644 --- a/marconi/tests/storage/base.py +++ b/marconi/tests/storage/base.py @@ -15,10 +15,10 @@ from marconi import storage -from marconi.tests.util import suite +from marconi.tests import util as testing -class ControllerBaseTest(suite.TestSuite): +class ControllerBaseTest(testing.TestBase): tenant = "tenant" driver_class = None controller_class = None diff --git a/marconi/tests/storage/test_base.py b/marconi/tests/storage/test_base.py index 0c47aa731..9429d7848 100644 --- a/marconi/tests/storage/test_base.py +++ b/marconi/tests/storage/test_base.py @@ -15,7 +15,7 @@ from marconi import storage -from marconi.tests.util import suite +from marconi.tests import util as testing class Driver(storage.DriverBase): @@ -56,7 +56,7 @@ class QueueController(storage.QueueBase): marker=marker, limit=limit) -class TestQueueBase(suite.TestSuite): +class TestQueueBase(testing.TestBase): def setUp(self): super(TestQueueBase, self).setUp() diff --git a/marconi/tests/storage/test_impl_mongodb.py b/marconi/tests/storage/test_impl_mongodb.py index 801bf6a9a..bafe4cfb7 100644 --- a/marconi/tests/storage/test_impl_mongodb.py +++ b/marconi/tests/storage/test_impl_mongodb.py @@ -19,13 +19,13 @@ from marconi.common import config from marconi.storage import mongodb from marconi.storage.mongodb import controllers from marconi.tests.storage import base -from marconi.tests.util import suite +from marconi.tests import util as testing cfg = config.namespace("drivers:storage:mongodb").from_options() -class MongodbDriverTest(suite.TestSuite): +class MongodbDriverTest(testing.TestBase): def setUp(self): if not os.environ.get("MONGODB_TEST_LIVE"): diff --git a/marconi/tests/test_config.py b/marconi/tests/test_config.py index 5fc4e797a..a4d56902a 100644 --- a/marconi/tests/test_config.py +++ b/marconi/tests/test_config.py @@ -16,7 +16,7 @@ import testtools from marconi.common import config -from marconi.tests.util import suite +from marconi.tests import util as testing cfg_handle = config.project() @@ -25,7 +25,7 @@ cfg = cfg_handle.from_options( with_help=(None, "nonsense")) -class TestConfig(suite.TestSuite): +class TestConfig(testing.TestBase): def test_cli(self): args = ['--with_help', 'sense'] diff --git a/marconi/tests/test_simple.py b/marconi/tests/test_simple.py index 176a144d8..580a0aea5 100644 --- a/marconi/tests/test_simple.py +++ b/marconi/tests/test_simple.py @@ -13,15 +13,15 @@ # under the License. import marconi -from marconi.tests.util import suite +from marconi.tests import util as testing -class TestSimple(suite.TestSuite): +class TestSimple(testing.TestBase): def test_simple(self): """Doesn't really test much.""" conf_file = self.conf_path('wsgi_reference.conf') boot = marconi.Bootstrap(conf_file) transport = boot.transport - wsgi_app = transport.app + wsgi_app = transport.app # NOQA self.assertTrue(True) diff --git a/marconi/tests/test_sqlite.py b/marconi/tests/test_sqlite.py index 881605f1c..601f09d37 100644 --- a/marconi/tests/test_sqlite.py +++ b/marconi/tests/test_sqlite.py @@ -17,10 +17,10 @@ import testtools from marconi.storage import exceptions from marconi.storage import sqlite -from marconi.tests.util import suite +from marconi.tests import util as testing -class TestSqlite(suite.TestSuite): +class TestSqlite(testing.TestBase): def test_sqlite(self): storage = sqlite.Driver() diff --git a/marconi/tests/util/__init__.py b/marconi/tests/util/__init__.py index 16ce89d72..301e9148f 100644 --- a/marconi/tests/util/__init__.py +++ b/marconi/tests/util/__init__.py @@ -1 +1,3 @@ """Test utilities""" + +from marconi.tests.util.base import TestBase # NOQA diff --git a/marconi/tests/util/suite.py b/marconi/tests/util/base.py similarity index 97% rename from marconi/tests/util/suite.py rename to marconi/tests/util/base.py index 8c4eb4645..dd832d40a 100644 --- a/marconi/tests/util/suite.py +++ b/marconi/tests/util/base.py @@ -16,14 +16,13 @@ import os import testtools - from marconi.common import config cfg = config.project() -class TestSuite(testtools.TestCase): +class TestBase(testtools.TestCase): """ Child class of testtools.TestCase for testing Marconi