def test_robot_command(self): """Test 'robot_command'.""" nodes_list = ["m3-1", "m3-2", "m3-3"] ret = robot.robot_command(self.api, 'status', 123, nodes_list) self.assertEqual(my_mock.API_RET, ret) self.api.robot_command.assert_called_with('status', 123, nodes_list)
def test_robot_command(self): """ Test 'robot_command' """ api = my_mock.api_mock() nodes_list = ["m3-1", "m3-2", "m3-3"] api.reset_mock() res = robot.robot_command(api, 'status', 123, nodes_list) self.assertEqual(my_mock.API_RET, res) api.robot_command.assert_called_with('status', 123, nodes_list)