assertIsNone(val) instead of assertEqual(None,val)
use assertIsNone(val) instead of assertEqual(None, val). Change-Id: Ib395d3805b9affca06477ffeca7d7cad070ebb7e
This commit is contained in:
parent
a4f83d97b9
commit
417f079c2b
@ -285,4 +285,4 @@ class TestWithRealKafkaBroker(test_utils.BaseTestCase):
|
||||
deadline = time.time() + 3
|
||||
received_message = listener.poll(timeout=3)
|
||||
self.assertEqual(0, int(deadline - time.time()))
|
||||
self.assertEqual(None, received_message)
|
||||
self.assertIsNone(received_message)
|
||||
|
@ -84,7 +84,7 @@ class TestLogNotifier(test_utils.BaseTestCase):
|
||||
n['priority'])
|
||||
self.assertEqual('logrecord', n['event_type'])
|
||||
self.assertEqual(str(timeutils.utcnow()), n['timestamp'])
|
||||
self.assertEqual(None, n['publisher_id'])
|
||||
self.assertIsNone(n['publisher_id'])
|
||||
self.assertEqual(
|
||||
{'process': os.getpid(),
|
||||
'funcName': None,
|
||||
@ -134,7 +134,7 @@ class TestLogNotifier(test_utils.BaseTestCase):
|
||||
n['priority'])
|
||||
self.assertEqual('logrecord', n['event_type'])
|
||||
self.assertEqual(str(timeutils.utcnow()), n['timestamp'])
|
||||
self.assertEqual(None, n['publisher_id'])
|
||||
self.assertIsNone(n['publisher_id'])
|
||||
pathname = __file__
|
||||
if pathname.endswith(('.pyc', '.pyo')):
|
||||
pathname = pathname[:-1]
|
||||
|
@ -76,7 +76,6 @@ class TestConfFixture(test_utils.BaseTestCase):
|
||||
|
||||
self.assertEqual([],
|
||||
conf.oslo_messaging_notifications.driver)
|
||||
self.assertEqual(None,
|
||||
conf.oslo_messaging_notifications.transport_url)
|
||||
self.assertIsNone(conf.oslo_messaging_notifications.transport_url)
|
||||
self.assertEqual(['notifications'],
|
||||
conf.oslo_messaging_notifications.topics)
|
@ -56,7 +56,7 @@ class TimerTestCase(test_utils.BaseTestCase):
|
||||
t = common.DecayingTimer()
|
||||
t.start()
|
||||
remaining = t.check_return()
|
||||
self.assertEqual(None, remaining)
|
||||
self.assertIsNone(remaining)
|
||||
|
||||
def test_no_duration_but_maximum(self):
|
||||
t = common.DecayingTimer()
|
||||
|
Loading…
Reference in New Issue
Block a user