Browse Source

Replace assertEqual(None, *) with assertIsNone in tests

Replace assertEqual(None, *) with assertIsNone in tests to have more
clear messages in case of failure.

Change-Id: Idb0376964ecc65d04e5b79753efd8f6a0b822bf8
Closes-Bug: #1280522
tags/5.6.0
weiweigu 2 years ago
parent
commit
689ba08173
1 changed files with 1 additions and 1 deletions
  1. 1
    1
      oslo_messaging/tests/notify/test_dispatcher.py

+ 1
- 1
oslo_messaging/tests/notify/test_dispatcher.py View File

@@ -132,7 +132,7 @@ class TestDispatcher(test_utils.BaseTestCase):
132 132
         dispatcher = notify_dispatcher.NotificationDispatcher(
133 133
             [mock.Mock()], None)
134 134
         res = dispatcher.dispatch(mock.Mock(ctxt={}, message=msg))
135
-        self.assertEqual(None, res)
135
+        self.assertIsNone(res)
136 136
         mylog.warning.assert_called_once_with('Unknown priority "%s"',
137 137
                                               'what???')
138 138
 

Loading…
Cancel
Save