]> review.fuel-infra Code Review - openstack-build/cinder-build.git/commitdiff
Replace assertEqual(None, *) with assertIsNone in tests
authorllg8212 <lilinguo@huawei.com>
Sat, 15 Feb 2014 04:42:56 +0000 (12:42 +0800)
committerllg8212 <lilinguo@huawei.com>
Sat, 15 Feb 2014 04:45:00 +0000 (12:45 +0800)
Replace assertEqual(None, *) with assertIsNone in tests to have
more clear messages in case of failure.

Change-Id: Iac9462620bf4ae338998fa6aea7f1514a945059b
Closes-Bug:#1280522

cinder/tests/test_volume.py

index 841b05ec3c3daadcb6236220a0c3954b824a5327..f2b11ab023cf7b04c7ff861d75b8170648b257bd 100644 (file)
@@ -1104,7 +1104,7 @@ class VolumeTestCase(BaseVolumeTestCase):
             conn_info = self.volume.initialize_connection(self.context,
                                                           'fake_volume_id',
                                                           connector)
-            self.assertEqual(None, conn_info['data']['qos_specs'])
+            self.assertIsNone(conn_info['data']['qos_specs'])
 
     def test_run_attach_detach_volume_for_instance(self):
         """Make sure volume can be attached and detached from instance."""