Fix misuse of assertTrue

Replace assertTrue with assertEqual.

Change-Id: I8bfbd171b3fb0d07b666420592df37392aad405c
Story: 2005228
Task: 30010
This commit is contained in:
Takashi NATSUME 2019-03-14 09:23:26 +09:00
parent c9556d8b51
commit 618b94c717
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)