diff options
author | Sergey Lukjanov <slukjanov@mirantis.com> | 2013-06-02 20:41:20 +0400 |
---|---|---|
committer | Sergey Lukjanov <slukjanov@mirantis.com> | 2013-06-03 07:53:21 +0400 |
commit | e3545f828dabe165dc08b2f1670e5f1f19919d0d (patch) | |
tree | ead970c643632ed624c6bda25e902f47cf13b49e /tests | |
parent | 15d8d698b7c67c43dc7a2b0c2c6952734bd2ba66 (diff) | |
download | oslo-e3545f828dabe165dc08b2f1670e5f1f19919d0d.tar.gz oslo-e3545f828dabe165dc08b2f1670e5f1f19919d0d.tar.xz oslo-e3545f828dabe165dc08b2f1670e5f1f19919d0d.zip |
Enable hacking H402 test
H402 one line docstring needs punctuation
Change-Id: Ie848453cace318d8310cdf0234c512f4c1121119
Diffstat (limited to 'tests')
-rw-r--r-- | tests/unit/plugin/test_callback_plugin.py | 2 | ||||
-rw-r--r-- | tests/unit/rpc/amqp.py | 2 | ||||
-rw-r--r-- | tests/unit/rpc/test_kombu.py | 16 | ||||
-rw-r--r-- | tests/unit/rpc/test_service.py | 4 | ||||
-rw-r--r-- | tests/unit/scheduler/test_host_filters.py | 2 | ||||
-rw-r--r-- | tests/unit/test_lockutils.py | 6 | ||||
-rw-r--r-- | tests/unit/test_log.py | 2 | ||||
-rw-r--r-- | tests/unit/test_loopingcall.py | 2 | ||||
-rw-r--r-- | tests/unit/test_notifier.py | 4 | ||||
-rw-r--r-- | tests/unit/test_periodic.py | 2 | ||||
-rw-r--r-- | tests/unit/test_plugin.py | 4 | ||||
-rw-r--r-- | tests/unit/test_rootwrap.py | 6 | ||||
-rw-r--r-- | tests/unit/test_service.py | 2 | ||||
-rw-r--r-- | tests/unit/test_threadgroup.py | 2 |
14 files changed, 28 insertions, 28 deletions
diff --git a/tests/unit/plugin/test_callback_plugin.py b/tests/unit/plugin/test_callback_plugin.py index cbe2601..3f3fd63 100644 --- a/tests/unit/plugin/test_callback_plugin.py +++ b/tests/unit/plugin/test_callback_plugin.py @@ -47,7 +47,7 @@ class TestCBP(callbackplugin.CallbackPlugin): class CallbackTestCase(test_utils.BaseTestCase): - """Tests for the callback plugin convenience class""" + """Tests for the callback plugin convenience class.""" def test_callback_plugin_subclass(self): diff --git a/tests/unit/rpc/amqp.py b/tests/unit/rpc/amqp.py index 69d647a..432dd35 100644 --- a/tests/unit/rpc/amqp.py +++ b/tests/unit/rpc/amqp.py @@ -223,7 +223,7 @@ class BaseRpcAMQPTestCase(common.BaseRpcTestCase): self.config(amqp_rpc_single_reply_queue=False) def test_duplicate_message_check(self): - """Test sending *not-dict* to a topic exchange/queue""" + """Test sending *not-dict* to a topic exchange/queue.""" conn = self.rpc.create_connection(FLAGS) message = {'args': 'topic test message', '_unique_id': 'aaaabbbbcccc'} diff --git a/tests/unit/rpc/test_kombu.py b/tests/unit/rpc/test_kombu.py index a524c73..159fefb 100644 --- a/tests/unit/rpc/test_kombu.py +++ b/tests/unit/rpc/test_kombu.py @@ -95,7 +95,7 @@ class RpcKombuTestCase(amqp.BaseRpcAMQPTestCase): self.assertEqual(conn1, conn2) def test_topic_send_receive(self): - """Test sending to a topic exchange/queue""" + """Test sending to a topic exchange/queue.""" conn = self.rpc.create_connection(FLAGS) message = 'topic test message' @@ -132,7 +132,7 @@ class RpcKombuTestCase(amqp.BaseRpcAMQPTestCase): conn.close() def test_topic_send_receive_exchange_name(self): - """Test sending to a topic exchange/queue with an exchange name""" + """Test sending to a topic exchange/queue with an exchange name.""" conn = self.rpc.create_connection(FLAGS) message = 'topic test message' @@ -151,7 +151,7 @@ class RpcKombuTestCase(amqp.BaseRpcAMQPTestCase): self.assertEqual(self.received_message, message) def test_topic_multiple_queues(self): - """Test sending to a topic exchange with multiple queues""" + """Test sending to a topic exchange with multiple queues.""" conn = self.rpc.create_connection(FLAGS) message = 'topic test message' @@ -233,7 +233,7 @@ class RpcKombuTestCase(amqp.BaseRpcAMQPTestCase): self.assertEqual(self.received_message_2, message) def test_direct_send_receive(self): - """Test sending to a direct exchange/queue""" + """Test sending to a direct exchange/queue.""" conn = self.rpc.create_connection(FLAGS) message = 'direct test message' @@ -250,7 +250,7 @@ class RpcKombuTestCase(amqp.BaseRpcAMQPTestCase): self.assertEqual(self.received_message, message) def test_cast_interface_uses_default_options(self): - """Test kombu rpc.cast""" + """Test kombu rpc.cast.""" ctxt = rpc_common.CommonRpcContext(user='fake_user', project='fake_project') @@ -276,7 +276,7 @@ class RpcKombuTestCase(amqp.BaseRpcAMQPTestCase): impl_kombu.cast(FLAGS, ctxt, 'fake_topic', {'msg': 'fake'}) def test_cast_to_server_uses_server_params(self): - """Test kombu rpc.cast""" + """Test kombu rpc.cast.""" ctxt = rpc_common.CommonRpcContext(user='fake_user', project='fake_project') @@ -309,7 +309,7 @@ class RpcKombuTestCase(amqp.BaseRpcAMQPTestCase): 'fake_topic', {'msg': 'fake'}) def test_fanout_send_receive(self): - """Test sending to a fanout exchange and consuming from 2 queues""" + """Test sending to a fanout exchange and consuming from 2 queues.""" self.skipTest("kombu memory transport seems buggy with " "fanout queues as this test passes when " @@ -366,7 +366,7 @@ class RpcKombuTestCase(amqp.BaseRpcAMQPTestCase): self.assertTrue(isinstance(result, self.rpc.DirectConsumer)) def test_declare_consumer_ioerrors_will_reconnect(self): - """Test that an IOError exception causes a reconnection""" + """Test that an IOError exception causes a reconnection.""" info = _raise_exc_stub(self.stubs, 2, self.rpc.DirectConsumer, '__init__', 'Socket closed', exc_class=IOError) diff --git a/tests/unit/rpc/test_service.py b/tests/unit/rpc/test_service.py index 9293d3e..e9f8313 100644 --- a/tests/unit/rpc/test_service.py +++ b/tests/unit/rpc/test_service.py @@ -21,7 +21,7 @@ from tests import utils class FakeService(service.Service): - """Fake manager for tests""" + """Fake manager for tests.""" def __init__(self, host, topic): super(FakeService, self).__init__(host, topic, None) self.method_result = 'manager' @@ -43,7 +43,7 @@ class FakeHookService(FakeService): class RpcServiceManagerTestCase(utils.BaseTestCase): - """Test cases for Services""" + """Test cases for Services.""" def setUp(self): super(RpcServiceManagerTestCase, self).setUp() self.config(fake_rabbit=True) diff --git a/tests/unit/scheduler/test_host_filters.py b/tests/unit/scheduler/test_host_filters.py index c36021c..b452955 100644 --- a/tests/unit/scheduler/test_host_filters.py +++ b/tests/unit/scheduler/test_host_filters.py @@ -425,7 +425,7 @@ class HostFiltersTestCase(utils.BaseTestCase): self.assertFalse(filt_cls.host_passes(host, filter_properties)) def test_json_filter_happy_day(self): - """Test json filter more thoroughly""" + """Test json filter more thoroughly.""" filt_cls = self.class_map['JsonFilter']() raw = ['and', '$capabilities.enabled', diff --git a/tests/unit/test_lockutils.py b/tests/unit/test_lockutils.py index c37b030..84afa2d 100644 --- a/tests/unit/test_lockutils.py +++ b/tests/unit/test_lockutils.py @@ -75,7 +75,7 @@ class LockTestCase(utils.BaseTestCase): "got mangled") def test_synchronized_internally(self): - """We can lock across multiple green threads""" + """We can lock across multiple green threads.""" saved_sem_num = len(lockutils._semaphores) seen_threads = list() @@ -105,7 +105,7 @@ class LockTestCase(utils.BaseTestCase): "Semaphore leak detected") def test_nested_external_works(self): - """We can nest external syncs""" + """We can nest external syncs.""" tempdir = tempfile.mkdtemp() try: self.config(lock_path=tempdir) @@ -126,7 +126,7 @@ class LockTestCase(utils.BaseTestCase): shutil.rmtree(tempdir) def _do_test_synchronized_externally(self): - """We can lock across multiple processes""" + """We can lock across multiple processes.""" @lockutils.synchronized('external', 'test-', external=True) def lock_files(handles_dir): diff --git a/tests/unit/test_log.py b/tests/unit/test_log.py index f87a1da..1641497 100644 --- a/tests/unit/test_log.py +++ b/tests/unit/test_log.py @@ -238,7 +238,7 @@ class ContextFormatterTestCase(test_utils.BaseTestCase): class ExceptionLoggingTestCase(test_utils.BaseTestCase): - """Test that Exceptions are logged""" + """Test that Exceptions are logged.""" def test_excepthook_logs_exception(self): product_name = 'somename' diff --git a/tests/unit/test_loopingcall.py b/tests/unit/test_loopingcall.py index f7d21b3..89cf336 100644 --- a/tests/unit/test_loopingcall.py +++ b/tests/unit/test_loopingcall.py @@ -58,7 +58,7 @@ class LoopingCallTestCase(utils.BaseTestCase): self.assertFalse(timer.start(interval=0.5).wait()) def test_interval_adjustment(self): - """Ensure the interval is adjusted to account for task duration""" + """Ensure the interval is adjusted to account for task duration.""" self.num_runs = 3 now = datetime.datetime.utcnow() diff --git a/tests/unit/test_notifier.py b/tests/unit/test_notifier.py index b762d5e..6c3b886 100644 --- a/tests/unit/test_notifier.py +++ b/tests/unit/test_notifier.py @@ -29,7 +29,7 @@ ctxt2 = context.get_admin_context() class NotifierTestCase(test_utils.BaseTestCase): - """Test case for notifications""" + """Test case for notifications.""" def setUp(self): super(NotifierTestCase, self).setUp() notification_driver = [ @@ -209,7 +209,7 @@ class SimpleNotifier(object): class MultiNotifierTestCase(test_utils.BaseTestCase): - """Test case for notifications""" + """Test case for notifications.""" def setUp(self): super(MultiNotifierTestCase, self).setUp() diff --git a/tests/unit/test_periodic.py b/tests/unit/test_periodic.py index 1fb1574..d663f8b 100644 --- a/tests/unit/test_periodic.py +++ b/tests/unit/test_periodic.py @@ -48,7 +48,7 @@ class AService(periodic_task.PeriodicTasks): class PeriodicTasksTestCase(utils.BaseTestCase): - """Test cases for PeriodicTasks""" + """Test cases for PeriodicTasks.""" def test_is_called(self): serv = AService() diff --git a/tests/unit/test_plugin.py b/tests/unit/test_plugin.py index 8ee405a..fd653d7 100644 --- a/tests/unit/test_plugin.py +++ b/tests/unit/test_plugin.py @@ -37,7 +37,7 @@ class ManagerTestCase(utils.BaseTestCase): class NotifyTestCase(utils.BaseTestCase): - """Test case for the plugin notification interface""" + """Test case for the plugin notification interface.""" def test_add_notifier(self): notifier1 = SimpleNotifier() @@ -99,7 +99,7 @@ class MockExtManager(): class APITestCase(utils.BaseTestCase): - """Test case for the plugin api extension interface""" + """Test case for the plugin api extension interface.""" def test_add_extension(self): def mock_load(_s): return TestPluginClass() diff --git a/tests/unit/test_rootwrap.py b/tests/unit/test_rootwrap.py index 5a5d9ca..25b2051 100644 --- a/tests/unit/test_rootwrap.py +++ b/tests/unit/test_rootwrap.py @@ -113,7 +113,7 @@ class RootwrapTestCase(utils.BaseTestCase): p.wait() def test_KillFilter_no_raise(self): - """Makes sure ValueError from bug 926412 is gone""" + """Makes sure ValueError from bug 926412 is gone.""" f = filters.KillFilter("root", "") # Providing anything other than kill should be False usercmd = ['notkill', 999999] @@ -123,7 +123,7 @@ class RootwrapTestCase(utils.BaseTestCase): self.assertFalse(f.match(usercmd)) def test_KillFilter_deleted_exe(self): - """Makes sure deleted exe's are killed correctly""" + """Makes sure deleted exe's are killed correctly.""" # See bug #967931. def fake_readlink(blah): return '/bin/commandddddd (deleted)' @@ -135,7 +135,7 @@ class RootwrapTestCase(utils.BaseTestCase): self.assertTrue(f.match(usercmd)) def test_KillFilter_upgraded_exe(self): - """Makes sure upgraded exe's are killed correctly""" + """Makes sure upgraded exe's are killed correctly.""" # See bug #1179793. def fake_readlink(blah): return '/bin/commandddddd\0\05190bfb2 (deleted)' diff --git a/tests/unit/test_service.py b/tests/unit/test_service.py index b7ba4f7..4a2827e 100644 --- a/tests/unit/test_service.py +++ b/tests/unit/test_service.py @@ -44,7 +44,7 @@ class ExtendedService(service.Service): class ServiceManagerTestCase(utils.BaseTestCase): - """Test cases for Services""" + """Test cases for Services.""" def test_override_manager_method(self): serv = ExtendedService() serv.start() diff --git a/tests/unit/test_threadgroup.py b/tests/unit/test_threadgroup.py index f627215..5af6653 100644 --- a/tests/unit/test_threadgroup.py +++ b/tests/unit/test_threadgroup.py @@ -27,7 +27,7 @@ LOG = logging.getLogger(__name__) class ThreadGroupTestCase(utils.BaseTestCase): - """Test cases for thread group""" + """Test cases for thread group.""" def setUp(self): super(ThreadGroupTestCase, self).setUp() self.tg = threadgroup.ThreadGroup() |