Browse Source

Replace assertNotEqual(None,) with assertIsNotNone

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

Change-Id: I1bb7c0bef3444cba5aa987c31a56c323e08913c7
Closes-bug: #1280522
tags/4.0.0.0b3
Bo Wang 3 years ago
parent
commit
6b07bca1ab
1 changed files with 2 additions and 2 deletions
  1. 2
    2
      sahara/tests/unit/utils/test_rpc.py

+ 2
- 2
sahara/tests/unit/utils/test_rpc.py View File

@@ -34,8 +34,8 @@ class TestMessagingSetup(base.SaharaTestCase):
34 34
 
35 35
     def _install(self):
36 36
         messaging.setup()
37
-        self.assertNotEqual(None, messaging.TRANSPORT)
38
-        self.assertNotEqual(None, messaging.NOTIFIER)
37
+        self.assertIsNotNone(messaging.TRANSPORT)
38
+        self.assertIsNotNone(messaging.NOTIFIER)
39 39
 
40 40
     def _remove_install(self):
41 41
         if messaging.TRANSPORT:

Loading…
Cancel
Save