Merge "Fix misuse of assertTrue"

This commit is contained in:
Zuul 2019-03-14 15:44:34 +00:00 committed by Gerrit Code Review
commit 89ac1d4ec0
2 changed files with 2 additions and 2 deletions

View File

@ -681,7 +681,7 @@ class IRMCDeployPrivateMethodsTestCase(test_common.BaseIRMCTest):
_get_iso_name_mock.assert_has_calls(
[mock.call(task.node, label='deploy'),
mock.call(task.node, label='rescue')])
self.assertTrue(_remove_share_file_mock.call_count, 3)
self.assertEqual(3, _remove_share_file_mock.call_count)
_remove_share_file_mock.assert_has_calls(
[mock.call(_get_floppy_image_name_mock(task.node)),
mock.call(_get_iso_name_mock(task.node, label='deploy')),

View File

@ -348,7 +348,7 @@ class IRMCInspectTestCase(test_common.BaseIRMCTest):
_inspect_hardware_mock.assert_called_once_with(task.node,
existing_traits)
self.assertTrue(port_mock.call_count, 2)
self.assertEqual(2, port_mock.call_count)
task.node.refresh()
self.assertEqual(inspected_props, task.node.properties)
self.assertEqual(states.MANAGEABLE, result)