From f9d5266ea0df652bed61175070802760e2765d6f Mon Sep 17 00:00:00 2001 From: "sonu.kumar" Date: Tue, 6 Oct 2015 11:07:31 +0530 Subject: [PATCH] Use assertFalse instead of assertEqual(False, ***) The usage of assertEqual(False, ***) should be changed to a more meaningful format of assertFalse(***). Change-Id: I133f7784280132ca1dcfeeba5f42bb17806a497a --- .../tests/test_pool_manager/test_service.py | 16 ++++++++-------- 1 file changed, 8 insertions(+), 8 deletions(-) diff --git a/designate/tests/test_pool_manager/test_service.py b/designate/tests/test_pool_manager/test_service.py index 5dee34d97..63f909eff 100644 --- a/designate/tests/test_pool_manager/test_service.py +++ b/designate/tests/test_pool_manager/test_service.py @@ -142,7 +142,7 @@ class PoolManagerServiceNoopTest(PoolManagerTestCase): # Pool manager needs to call into mdns to calculate consensus as # there is no cache. So update_status is never called. - self.assertEqual(False, mock_update_status.called) + self.assertFalse(mock_update_status.called) @patch.object(mdns_rpcapi.MdnsAPI, 'get_serial_number', side_effect=messaging.MessagingException) @@ -166,8 +166,8 @@ class PoolManagerServiceNoopTest(PoolManagerTestCase): # Ensure notify_zone_changed and poll_for_serial_number # were never called. - self.assertEqual(False, mock_notify_zone_changed.called) - self.assertEqual(False, mock_poll_for_serial_number.called) + self.assertFalse(mock_notify_zone_changed.called) + self.assertFalse(mock_poll_for_serial_number.called) # Since consensus is not reached this early, we immediatly call # central's update_status. @@ -231,7 +231,7 @@ class PoolManagerServiceNoopTest(PoolManagerTestCase): self.service.pool.nameservers[1], 30, 15, 10, 5)], mock_poll_for_serial_number.call_args_list) - self.assertEqual(False, mock_update_status.called) + self.assertFalse(mock_update_status.called) @patch.object(impl_fake.FakeBackend, 'delete_domain', side_effect=exceptions.Backend) @@ -308,7 +308,7 @@ class PoolManagerServiceNoopTest(PoolManagerTestCase): self.assertEqual(0, len(update_statuses)) # Ensure update_status was not called. - self.assertEqual(False, mock_update_status.called) + self.assertFalse(mock_update_status.called) self.service.update_status(self.admin_context, domain, self.service.pool.nameservers[1], @@ -319,7 +319,7 @@ class PoolManagerServiceNoopTest(PoolManagerTestCase): self.assertEqual(0, len(update_statuses)) # Ensure update_status was not called. - self.assertEqual(False, mock_update_status.called) + self.assertFalse(mock_update_status.called) @patch.object(mdns_rpcapi.MdnsAPI, 'get_serial_number', side_effect=messaging.MessagingException) @@ -367,7 +367,7 @@ class PoolManagerServiceNoopTest(PoolManagerTestCase): self.assertEqual(0, len(update_statuses)) # Ensure update_status was not called. - self.assertEqual(False, mock_update_status.called) + self.assertFalse(mock_update_status.called) self.service.update_status(self.admin_context, domain, self.service.pool.nameservers[1], @@ -402,7 +402,7 @@ class PoolManagerServiceNoopTest(PoolManagerTestCase): self.assertEqual(0, len(update_statuses)) # Ensure update_status was not called. - self.assertEqual(False, mock_update_status.called) + self.assertFalse(mock_update_status.called) # Reset the mock call attributes. mock_update_status.reset_mock()