1
0
Fork 0
mirror of https://github.com/ansible-collections/community.general.git synced 2024-09-14 20:13:21 +02:00

Fix imports, part 2 (#42)

* Recover missing netapp.ontap module doc fragments from ansible/ansible@pre-ansible-base.

* Fix PEP8 issues.

* Remove netbox empty files, and test which shouldn't be here.

* Add forgotten file for kubevirt tests.

* Fix unit test imports.

* ansible/ansible#68415 has been fixed.

* Clean up/rearrange imports.

* Update ignore.txt, fix boilerplate.

* Netapp docs fragment: fix spacing

* Forgot to adjust kubevirt tests.
This commit is contained in:
Felix Fontein 2020-03-25 12:43:51 +01:00 committed by GitHub
parent 25394eeafb
commit 07ecfc940c
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
118 changed files with 486 additions and 423 deletions

View file

@ -0,0 +1,114 @@
# -*- coding: utf-8 -*-
# Copyright: (c) 2018, Sumit Kumar <sumit4@netapp.com>, chris Archibald <carchi@netapp.com>
# GNU General Public License v3.0+ (see COPYING or https://www.gnu.org/licenses/gpl-3.0.txt)
from __future__ import (absolute_import, division, print_function)
__metaclass__ = type
class ModuleDocFragment(object):
DOCUMENTATION = r'''
options:
- See respective platform section for more details
requirements:
- See respective platform section for more details
notes:
- Ansible modules are available for the following NetApp Storage Platforms: E-Series, ONTAP, SolidFire
'''
# Documentation fragment for ONTAP (na_cdot)
ONTAP = r'''
options:
hostname:
required: true
description:
- The hostname or IP address of the ONTAP instance.
username:
required: true
description:
- This can be a Cluster-scoped or SVM-scoped account, depending on whether a Cluster-level or SVM-level API is required.
For more information, please read the documentation U(https://mysupport.netapp.com/NOW/download/software/nmsdk/9.4/).
aliases: ['user']
password:
required: true
description:
- Password for the specified user.
aliases: ['pass']
requirements:
- A physical or virtual clustered Data ONTAP system. The modules were developed with Clustered Data ONTAP 8.3
- Ansible 2.2
- netapp-lib (2015.9.25). Install using 'pip install netapp-lib'
notes:
- The modules prefixed with na\\_cdot are built to support the ONTAP storage platform.
'''
# Documentation fragment for SolidFire
SOLIDFIRE = r'''
options:
hostname:
required: true
description:
- The hostname or IP address of the SolidFire cluster.
username:
required: true
description:
- Please ensure that the user has the adequate permissions. For more information, please read the official documentation
U(https://mysupport.netapp.com/documentation/docweb/index.html?productID=62636&language=en-US).
aliases: ['user']
password:
required: true
description:
- Password for the specified user.
aliases: ['pass']
requirements:
- The modules were developed with SolidFire 10.1
- solidfire-sdk-python (1.1.0.92) or greater. Install using 'pip install solidfire-sdk-python'
notes:
- The modules prefixed with na\\_elementsw are built to support the SolidFire storage platform.
'''
# Documentation fragment for E-Series
ESERIES = r'''
options:
api_username:
required: true
type: str
description:
- The username to authenticate with the SANtricity Web Services Proxy or Embedded Web Services API.
api_password:
required: true
type: str
description:
- The password to authenticate with the SANtricity Web Services Proxy or Embedded Web Services API.
api_url:
required: true
type: str
description:
- The url to the SANtricity Web Services Proxy or Embedded Web Services API.
Example https://prod-1.wahoo.acme.com/devmgr/v2
validate_certs:
required: false
default: true
description:
- Should https certificates be validated?
type: bool
ssid:
required: false
type: str
default: 1
description:
- The ID of the array to manage. This value must be unique for each array.
notes:
- The E-Series Ansible modules require either an instance of the Web Services Proxy (WSP), to be available to manage
the storage-system, or an E-Series storage-system that supports the Embedded Web Services API.
- Embedded Web Services is currently available on the E2800, E5700, EF570, and newer hardware models.
- M(netapp_e_storage_system) may be utilized for configuring the systems managed by a WSP instance.
'''

View file

@ -53,10 +53,10 @@ from ansible.errors import AnsibleError, AnsibleParserError
from ansible.plugins.lookup import LookupBase
from ansible.utils.display import Display
from ansible_collections.community.general.plugins.module_utils.network.avi.avi_api import (ApiSession,
AviCredentials,
AviServerError,
ObjectNotFound,
APIError)
AviCredentials,
AviServerError,
ObjectNotFound,
APIError)
display = Display()

View file

@ -172,8 +172,8 @@ tags:
from ansible.module_utils.basic import AnsibleModule
from ansible_collections.community.general.plugins.module_utils.cloudscale import (AnsibleCloudscaleBase,
cloudscale_argument_spec,
)
cloudscale_argument_spec,
)
class AnsibleCloudscaleVolume(AnsibleCloudscaleBase):

View file

@ -148,8 +148,8 @@ project:
from ansible.module_utils.basic import AnsibleModule
from ansible_collections.community.general.plugins.module_utils.cloudstack import (AnsibleCloudStack,
cs_argument_spec,
cs_required_together)
cs_argument_spec,
cs_required_together)
class AnsibleCloudStackInstanceNic(AnsibleCloudStack):

View file

@ -132,10 +132,10 @@ RETURN = '''
###############################################################################
from ansible_collections.community.general.plugins.module_utils.hwc_utils import (Config, HwcClientException,
HwcClientException404, HwcModule,
are_different_dicts, is_empty_value,
wait_to_finish, get_region,
build_path, navigate_value)
HwcClientException404, HwcModule,
are_different_dicts, is_empty_value,
wait_to_finish, get_region,
build_path, navigate_value)
import re
###############################################################################

View file

@ -111,9 +111,9 @@ update_time:
###############################################################################
from ansible_collections.community.general.plugins.module_utils.hwc_utils import (Config, HwcClientException,
HwcModule, navigate_value,
are_different_dicts, is_empty_value,
build_path, get_region)
HwcModule, navigate_value,
are_different_dicts, is_empty_value,
build_path, get_region)
import re
###############################################################################

View file

@ -213,8 +213,8 @@ except ImportError:
from ansible.module_utils.basic import AnsibleModule
from ansible_collections.community.general.plugins.module_utils.rax import (FINAL_STATUSES, rax_argument_spec, rax_find_bootable_volume,
rax_find_image, rax_find_network, rax_find_volume,
rax_required_together, rax_to_dict, setup_rax_module)
rax_find_image, rax_find_network, rax_find_volume,
rax_required_together, rax_to_dict, setup_rax_module)
from ansible.module_utils.six.moves import xrange
from ansible.module_utils.six import string_types

View file

@ -105,7 +105,7 @@ except ImportError:
from ansible.module_utils.basic import AnsibleModule
from ansible_collections.community.general.plugins.module_utils.rax import (VOLUME_STATUS, rax_argument_spec, rax_find_image, rax_find_volume,
rax_required_together, rax_to_dict, setup_rax_module)
rax_required_together, rax_to_dict, setup_rax_module)
def cloud_block_storage(module, state, name, description, meta, size,

View file

@ -82,13 +82,13 @@ except ImportError:
from ansible.module_utils.basic import AnsibleModule
from ansible_collections.community.general.plugins.module_utils.rax import (NON_CALLABLES,
rax_argument_spec,
rax_find_server,
rax_find_volume,
rax_required_together,
rax_to_dict,
setup_rax_module,
)
rax_argument_spec,
rax_find_server,
rax_find_volume,
rax_required_together,
rax_to_dict,
setup_rax_module,
)
def cloud_block_storage_attachments(module, state, volume, server, device,

View file

@ -133,12 +133,12 @@ except ImportError:
from ansible.module_utils.basic import AnsibleModule
from ansible_collections.community.general.plugins.module_utils.rax import (CLB_ALGORITHMS,
CLB_PROTOCOLS,
rax_argument_spec,
rax_required_together,
rax_to_dict,
setup_rax_module,
)
CLB_PROTOCOLS,
rax_argument_spec,
rax_required_together,
rax_to_dict,
setup_rax_module,
)
def cloud_load_balancer(module, state, name, meta, algorithm, port, protocol,

View file

@ -102,11 +102,11 @@ except ImportError:
from ansible.module_utils.basic import AnsibleModule
from ansible_collections.community.general.plugins.module_utils.rax import (rax_argument_spec,
rax_find_loadbalancer,
rax_required_together,
rax_to_dict,
setup_rax_module,
)
rax_find_loadbalancer,
rax_required_together,
rax_to_dict,
setup_rax_module,
)
def cloud_load_balancer_ssl(module, loadbalancer, state, enabled, private_key,

View file

@ -71,10 +71,10 @@ except ImportError:
from ansible.module_utils.basic import AnsibleModule
from ansible_collections.community.general.plugins.module_utils.rax import (rax_argument_spec,
rax_required_together,
rax_to_dict,
setup_rax_module,
)
rax_required_together,
rax_to_dict,
setup_rax_module,
)
def rax_dns(module, comment, email, name, state, ttl):

View file

@ -123,12 +123,12 @@ except ImportError:
from ansible.module_utils.basic import AnsibleModule
from ansible_collections.community.general.plugins.module_utils.rax import (rax_argument_spec,
rax_find_loadbalancer,
rax_find_server,
rax_required_together,
rax_to_dict,
setup_rax_module,
)
rax_find_loadbalancer,
rax_find_server,
rax_required_together,
rax_to_dict,
setup_rax_module,
)
def rax_dns_record_ptr(module, data=None, comment=None, loadbalancer=None,

View file

@ -58,10 +58,10 @@ except ImportError:
from ansible.module_utils.basic import AnsibleModule
from ansible_collections.community.general.plugins.module_utils.rax import (rax_argument_spec,
rax_required_together,
rax_to_dict,
setup_rax_module,
)
rax_required_together,
rax_to_dict,
setup_rax_module,
)
def rax_facts(module, address, name, server_id):

View file

@ -54,7 +54,7 @@ except ImportError:
from ansible.module_utils.basic import AnsibleModule
from ansible_collections.community.general.plugins.module_utils.rax import (rax_argument_spec, rax_required_together, rax_to_dict,
setup_rax_module)
setup_rax_module)
def cloud_identity(module, state, identity):

View file

@ -88,10 +88,10 @@ except ImportError:
from ansible.module_utils.basic import AnsibleModule
from ansible_collections.community.general.plugins.module_utils.rax import (rax_argument_spec,
rax_required_together,
rax_to_dict,
setup_rax_module,
)
rax_required_together,
rax_to_dict,
setup_rax_module,
)
def rax_keypair(module, name, public_key, state):

View file

@ -144,7 +144,7 @@ except ImportError:
from ansible.module_utils.basic import AnsibleModule
from ansible_collections.community.general.plugins.module_utils.rax import (rax_argument_spec, rax_find_image, rax_find_network,
rax_required_together, rax_to_dict, setup_rax_module)
rax_required_together, rax_to_dict, setup_rax_module)
from ansible.module_utils.six import string_types

View file

@ -124,7 +124,7 @@ except ImportError:
from ansible.module_utils.basic import AnsibleModule
from ansible_collections.community.general.plugins.module_utils.rax import (UUID, rax_argument_spec, rax_required_together, rax_to_dict,
setup_rax_module)
setup_rax_module)
def rax_asp(module, at=None, change=0, cron=None, cooldown=300,

View file

@ -443,10 +443,10 @@ from ansible.module_utils.basic import AnsibleModule
from ansible.module_utils.common.network import is_mac
from ansible.module_utils import six
from ansible_collections.community.general.plugins.module_utils.xenserver import (xenserver_common_argument_spec, XAPI, XenServerObject, get_object_ref,
gather_vm_params, gather_vm_facts, set_vm_power_state, wait_for_vm_ip_address,
is_valid_ip_addr, is_valid_ip_netmask, is_valid_ip_prefix,
ip_prefix_to_netmask, ip_netmask_to_prefix,
is_valid_ip6_addr, is_valid_ip6_prefix)
gather_vm_params, gather_vm_facts, set_vm_power_state,
wait_for_vm_ip_address, is_valid_ip_addr, is_valid_ip_netmask,
is_valid_ip_prefix, ip_prefix_to_netmask, ip_netmask_to_prefix,
is_valid_ip6_addr, is_valid_ip6_prefix)
class XenServerVM(XenServerObject):

View file

@ -163,7 +163,7 @@ except ImportError:
from ansible.module_utils.basic import AnsibleModule
from ansible_collections.community.general.plugins.module_utils.xenserver import (xenserver_common_argument_spec, XAPI, XenServerObject, get_object_ref,
gather_vm_params, gather_vm_facts)
gather_vm_params, gather_vm_facts)
class XenServerVM(XenServerObject):

View file

@ -186,7 +186,8 @@ except ImportError:
from ansible.module_utils.basic import AnsibleModule
from ansible_collections.community.general.plugins.module_utils.xenserver import (xenserver_common_argument_spec, XAPI, XenServerObject, get_object_ref,
gather_vm_params, gather_vm_facts, set_vm_power_state, wait_for_vm_ip_address)
gather_vm_params, gather_vm_facts, set_vm_power_state,
wait_for_vm_ip_address)
class XenServerVM(XenServerObject):

View file

@ -96,8 +96,8 @@ content:
'''
import json
from ansible_collections.community.general.plugins.module_utils.network.a10.a10 import (axapi_call, a10_argument_spec, axapi_authenticate, axapi_failure, axapi_get_port_protocol,
axapi_enabled_disabled, AXAPI_PORT_PROTOCOLS)
from ansible_collections.community.general.plugins.module_utils.network.a10.a10 import (axapi_call, a10_argument_spec, axapi_authenticate, axapi_failure,
axapi_get_port_protocol, axapi_enabled_disabled, AXAPI_PORT_PROTOCOLS)
from ansible.module_utils.basic import AnsibleModule
from ansible.module_utils.urls import url_argument_spec

View file

@ -113,7 +113,8 @@ content:
'''
import json
from ansible_collections.community.general.plugins.module_utils.network.a10.a10 import (axapi_call, a10_argument_spec, axapi_authenticate, axapi_failure, axapi_enabled_disabled)
from ansible_collections.community.general.plugins.module_utils.network.a10.a10 import (axapi_call, a10_argument_spec, axapi_authenticate,
axapi_failure, axapi_enabled_disabled)
from ansible.module_utils.basic import AnsibleModule
from ansible.module_utils.urls import url_argument_spec

View file

@ -102,7 +102,8 @@ content:
import json
from ansible_collections.community.general.plugins.module_utils.network.a10.a10 import (axapi_call, a10_argument_spec, axapi_authenticate, axapi_failure,
axapi_enabled_disabled, axapi_get_vport_protocol, AXAPI_VPORT_PROTOCOLS)
axapi_enabled_disabled, axapi_get_vport_protocol,
AXAPI_VPORT_PROTOCOLS)
from ansible.module_utils.basic import AnsibleModule
from ansible.module_utils.urls import url_argument_spec

View file

@ -409,7 +409,7 @@ download:
from ansible.module_utils.basic import AnsibleModule
from ansible_collections.community.general.plugins.module_utils.network.ingate.common import (ingate_argument_spec,
ingate_create_client)
ingate_create_client)
try:
from ingate import ingatesdk

View file

@ -124,8 +124,8 @@ unit-information:
from ansible.module_utils.basic import AnsibleModule
from ansible.module_utils._text import to_native
from ansible_collections.community.general.plugins.module_utils.network.ingate.common import (ingate_argument_spec,
ingate_create_client,
is_ingatesdk_installed)
ingate_create_client,
is_ingatesdk_installed)
try:
from ingate import ingatesdk

View file

@ -113,7 +113,8 @@ diff:
'''
from ansible.module_utils.basic import AnsibleModule
from ansible_collections.community.general.plugins.module_utils.network.netscaler.netscaler import ConfigProxy, get_nitro_client, netscaler_common_arguments, log, loglines, ensure_feature_is_enabled
from ansible_collections.community.general.plugins.module_utils.network.netscaler.netscaler import (ConfigProxy, get_nitro_client, netscaler_common_arguments,
log, loglines, ensure_feature_is_enabled)
try:
from nssrc.com.citrix.netscaler.nitro.resource.config.cs.cspolicy import cspolicy
from nssrc.com.citrix.netscaler.nitro.exception.nitro_exception import nitro_exception

View file

@ -158,8 +158,10 @@ except ImportError as e:
PYTHON_SDK_IMPORTED = False
from ansible.module_utils.basic import AnsibleModule
from ansible_collections.community.general.plugins.module_utils.network.netscaler.netscaler import ConfigProxy, get_nitro_client, netscaler_common_arguments, log, loglines, \
get_immutables_intersection
from ansible_collections.community.general.plugins.module_utils.network.netscaler.netscaler import (ConfigProxy, get_nitro_client,
netscaler_common_arguments,
log, loglines,
get_immutables_intersection)
def server_exists(client, module):

View file

@ -427,8 +427,8 @@ except ImportError as e:
PYTHON_SDK_IMPORTED = False
from ansible.module_utils.basic import AnsibleModule
from ansible_collections.community.general.plugins.module_utils.network.netscaler.netscaler import (ConfigProxy, get_nitro_client, netscaler_common_arguments, log, loglines,
get_immutables_intersection)
from ansible_collections.community.general.plugins.module_utils.network.netscaler.netscaler import (ConfigProxy, get_nitro_client, netscaler_common_arguments,
log, loglines, get_immutables_intersection)
def service_exists(client, module):

View file

@ -398,8 +398,8 @@ diff:
from ansible.module_utils.basic import AnsibleModule
import copy
from ansible_collections.community.general.plugins.module_utils.network.netscaler.netscaler import ConfigProxy, get_nitro_client, netscaler_common_arguments, log, \
loglines, get_immutables_intersection
from ansible_collections.community.general.plugins.module_utils.network.netscaler.netscaler import (ConfigProxy, get_nitro_client, netscaler_common_arguments,
log, loglines, get_immutables_intersection)
try:
from nssrc.com.citrix.netscaler.nitro.resource.config.basic.servicegroup import servicegroup
from nssrc.com.citrix.netscaler.nitro.resource.config.basic.servicegroup_servicegroupmember_binding import servicegroup_servicegroupmember_binding

View file

@ -152,8 +152,8 @@ except ImportError as e:
PYTHON_SDK_IMPORTED = False
from ansible.module_utils.basic import AnsibleModule
from ansible_collections.community.general.plugins.module_utils.network.netscaler.netscaler import ConfigProxy, get_nitro_client, netscaler_common_arguments, log, loglines, \
get_immutables_intersection
from ansible_collections.community.general.plugins.module_utils.network.netscaler.netscaler import (ConfigProxy, get_nitro_client, netscaler_common_arguments,
log, loglines, get_immutables_intersection)
def key_exists(client, module):

View file

@ -79,7 +79,7 @@ RETURN = '''
from ansible.module_utils.basic import AnsibleModule
from ansible_collections.community.general.plugins.module_utils.ibm_sa_utils import (execute_pyxcli_command, connect_ssl,
spectrum_accelerate_spec, is_pyxcli_installed)
spectrum_accelerate_spec, is_pyxcli_installed)
def main():

View file

@ -94,7 +94,7 @@ RETURN = '''
from ansible.module_utils.basic import AnsibleModule
from ansible_collections.community.general.plugins.module_utils.ibm_sa_utils import (execute_pyxcli_command,
connect_ssl, spectrum_accelerate_spec, is_pyxcli_installed)
connect_ssl, spectrum_accelerate_spec, is_pyxcli_installed)
def main():

View file

@ -18,7 +18,7 @@ module: na_cdot_aggregate
short_description: Manage NetApp cDOT aggregates.
extends_documentation_fragment:
- netapp.ontap.netapp.na_ontap
- community.general.netapp.ontap
author: Sumit Kumar (@timuster) <sumit4@netapp.com>

View file

@ -18,7 +18,7 @@ module: na_cdot_license
short_description: Manage NetApp cDOT protocol and feature licenses
extends_documentation_fragment:
- netapp.ontap.netapp.na_ontap
- community.general.netapp.ontap
author: Sumit Kumar (@timuster) <sumit4@netapp.com>

View file

@ -18,7 +18,7 @@ module: na_cdot_lun
short_description: Manage NetApp cDOT luns
extends_documentation_fragment:
- netapp.ontap.netapp.na_ontap
- community.general.netapp.ontap
author: Sumit Kumar (@timuster) <sumit4@netapp.com>

View file

@ -18,7 +18,7 @@ module: na_cdot_qtree
short_description: Manage qtrees
extends_documentation_fragment:
- netapp.ontap.netapp.na_ontap
- community.general.netapp.ontap
author: Sumit Kumar (@timuster) <sumit4@netapp.com>

View file

@ -18,7 +18,7 @@ module: na_cdot_svm
short_description: Manage NetApp cDOT svm
extends_documentation_fragment:
- netapp.ontap.netapp.na_ontap
- community.general.netapp.ontap
author: Sumit Kumar (@timuster) <sumit4@netapp.com>

View file

@ -18,7 +18,7 @@ module: na_cdot_user
short_description: useradmin configuration and management
extends_documentation_fragment:
- netapp.ontap.netapp.na_ontap
- community.general.netapp.ontap
author: Sumit Kumar (@timuster) <sumit4@netapp.com>

View file

@ -18,7 +18,7 @@ module: na_cdot_user_role
short_description: useradmin configuration and management
extends_documentation_fragment:
- netapp.ontap.netapp.na_ontap
- community.general.netapp.ontap
author: Sumit Kumar (@timuster) <sumit4@netapp.com>

View file

@ -18,7 +18,7 @@ module: na_cdot_volume
short_description: Manage NetApp cDOT volumes
extends_documentation_fragment:
- netapp.ontap.netapp.na_ontap
- community.general.netapp.ontap
author: Sumit Kumar (@timuster) <sumit4@netapp.com>

View file

@ -20,7 +20,7 @@ description:
- This module will allow the owner of the system to specify email recipients for these messages.
author: Michael Price (@lmprice)
extends_documentation_fragment:
- netapp.ontap.netapp.eseries
- community.general.netapp.eseries
options:
state:

View file

@ -19,7 +19,7 @@ description:
- Allows for the creation, removal and updating of Asynchronous Mirror Groups for NetApp E-series storage arrays
author: Kevin Hulquest (@hulquest)
extends_documentation_fragment:
- netapp.ontap.netapp.eseries
- community.general.netapp.eseries
options:
name:

View file

@ -19,7 +19,7 @@ description:
- Allow the auto-support settings to be configured for an individual E-Series storage-system
author: Michael Price (@lmprice)
extends_documentation_fragment:
- netapp.ontap.netapp.eseries
- community.general.netapp.eseries
options:
state:

View file

@ -19,7 +19,7 @@ description:
- This module allows an e-series storage system owner to set audit-log configuration parameters.
author: Nathan Swartz (@ndswartz)
extends_documentation_fragment:
- netapp.ontap.netapp.eseries
- community.general.netapp.eseries
options:
max_records:

View file

@ -20,7 +20,7 @@ description:
author:
- Nathan Swartz (@ndswartz)
extends_documentation_fragment:
- netapp.ontap.netapp.eseries
- community.general.netapp.eseries
options:
firmware:

View file

@ -20,7 +20,7 @@ author:
- Kevin Hulquest (@hulquest)
- Nathan Swartz (@ndswartz)
extends_documentation_fragment:
- netapp.ontap.netapp.eseries
- community.general.netapp.eseries
'''

View file

@ -20,7 +20,7 @@ description:
author:
- Nathan Swartz (@ndswartz)
extends_documentation_fragment:
- netapp.ontap.netapp.eseries
- community.general.netapp.eseries
options:
nvsram:

View file

@ -19,7 +19,7 @@ description:
- Allow the user to configure several of the global settings associated with an E-Series storage-system
author: Michael Price (@lmprice)
extends_documentation_fragment:
- netapp.ontap.netapp.eseries
- community.general.netapp.eseries
options:
name:

View file

@ -20,7 +20,7 @@ author:
- Kevin Hulquest (@hulquest)
- Nathan Swartz (@ndswartz)
extends_documentation_fragment:
- netapp.ontap.netapp.eseries
- community.general.netapp.eseries
options:
name:

View file

@ -22,7 +22,7 @@ author:
- Nathan Swartz (@ndswartz)
description: Create, update or destroy host groups on a NetApp E-Series storage array.
extends_documentation_fragment:
- netapp.ontap.netapp.eseries
- community.general.netapp.eseries
options:
state:

View file

@ -19,7 +19,7 @@ description:
- Configure settings of an E-Series iSCSI interface
author: Michael Price (@lmprice)
extends_documentation_fragment:
- netapp.ontap.netapp.eseries
- community.general.netapp.eseries
options:
controller:

View file

@ -19,7 +19,7 @@ description:
- Configure the settings of an E-Series iSCSI target
author: Michael Price (@lmprice)
extends_documentation_fragment:
- netapp.ontap.netapp.eseries
- community.general.netapp.eseries
options:
name:

View file

@ -19,7 +19,7 @@ description:
- Configure an E-Series system to allow authentication via an LDAP server
author: Michael Price (@lmprice)
extends_documentation_fragment:
- netapp.ontap.netapp.eseries
- community.general.netapp.eseries
options:
state:

View file

@ -21,7 +21,7 @@ short_description: NetApp E-Series create, delete, or modify lun mappings
description:
- Create, delete, or modify mappings between a volume and a targeted host/host+ group.
extends_documentation_fragment:
- netapp.ontap.netapp.eseries
- community.general.netapp.eseries
options:
state:

View file

@ -21,7 +21,7 @@ author:
- Michael Price (@lmprice)
- Nathan Swartz (@ndswartz)
extends_documentation_fragment:
- netapp.ontap.netapp.eseries
- community.general.netapp.eseries
options:
state:

View file

@ -20,7 +20,7 @@ author:
- Kevin Hulquest (@hulquest)
- Nathan Swartz (@ndswartz)
extends_documentation_fragment:
- netapp.ontap.netapp.eseries
- community.general.netapp.eseries
options:
state:

View file

@ -19,7 +19,7 @@ description:
- Allow the syslog settings to be configured for an individual E-Series storage-system
author: Nathan Swartz (@ndswartz)
extends_documentation_fragment:
- netapp.ontap.netapp.eseries
- community.general.netapp.eseries
options:
state:

View file

@ -21,7 +21,7 @@ author:
- Kevin Hulquest (@hulquest)
- Nathan Swartz (@ndswartz)
extends_documentation_fragment:
- netapp.ontap.netapp.eseries
- community.general.netapp.eseries
options:
state:

View file

@ -20,7 +20,7 @@ description:
- Create and delete snapshots images on volume groups for NetApp E-series storage arrays.
author: Kevin Hulquest (@hulquest)
extends_documentation_fragment:
- netapp.ontap.netapp.eseries
- community.general.netapp.eseries
options:
api_username:

View file

@ -21,7 +21,7 @@ deprecated:
alternative: please use M(na_elementsw_account)
short_description: Manage SolidFire accounts
extends_documentation_fragment:
- netapp.ontap.netapp.solidfire
- community.general.netapp.solidfire
author: Sumit Kumar (@timuster) <sumit4@netapp.com>
description:

View file

@ -21,7 +21,7 @@ deprecated:
alternative: please use M(na_elementsw_check_connections)
short_description: Check connectivity to MVIP and SVIP.
extends_documentation_fragment:
- netapp.ontap.netapp.solidfire
- community.general.netapp.solidfire
author: Sumit Kumar (@timuster) <sumit4@netapp.com>
description:

View file

@ -20,7 +20,7 @@ deprecated:
alternative: please use M(na_elementsw_snapshot_schedule)
short_description: Manage SolidFire snapshot schedules
extends_documentation_fragment:
- netapp.ontap.netapp.solidfire
- community.general.netapp.solidfire
author: Sumit Kumar (@timuster) <sumit4@netapp.com>
description:

View file

@ -21,7 +21,7 @@ deprecated:
alternative: please use M(na_elementsw_access_group)
short_description: Manage SolidFire Volume Access Groups
extends_documentation_fragment:
- netapp.ontap.netapp.solidfire
- community.general.netapp.solidfire
author: Sumit Kumar (@timuster) <sumit4@netapp.com>
description:

View file

@ -21,7 +21,7 @@ deprecated:
alternative: please use M(na_elementsw_volume)
short_description: Manage SolidFire volumes
extends_documentation_fragment:
- netapp.ontap.netapp.solidfire
- community.general.netapp.solidfire
author: Sumit Kumar (@timuster) <sumit4@netapp.com>
description:

View file

@ -3502,8 +3502,6 @@ tests/unit/module_utils/hwc/test_dict_comparison.py future-import-boilerplate
tests/unit/module_utils/hwc/test_dict_comparison.py metaclass-boilerplate
tests/unit/module_utils/hwc/test_hwc_utils.py future-import-boilerplate
tests/unit/module_utils/hwc/test_hwc_utils.py metaclass-boilerplate
tests/unit/module_utils/net_tools/netbox/test_netbox_utils.py future-import-boilerplate
tests/unit/module_utils/net_tools/netbox/test_netbox_utils.py metaclass-boilerplate
tests/unit/module_utils/network/avi/test_avi_api_utils.py future-import-boilerplate
tests/unit/module_utils/network/avi/test_avi_api_utils.py metaclass-boilerplate
tests/unit/module_utils/network/ftd/test_common.py future-import-boilerplate

View file

@ -3539,8 +3539,6 @@ tests/unit/module_utils/hwc/test_dict_comparison.py future-import-boilerplate
tests/unit/module_utils/hwc/test_dict_comparison.py metaclass-boilerplate
tests/unit/module_utils/hwc/test_hwc_utils.py future-import-boilerplate
tests/unit/module_utils/hwc/test_hwc_utils.py metaclass-boilerplate
tests/unit/module_utils/net_tools/netbox/test_netbox_utils.py future-import-boilerplate
tests/unit/module_utils/net_tools/netbox/test_netbox_utils.py metaclass-boilerplate
tests/unit/module_utils/network/avi/test_avi_api_utils.py future-import-boilerplate
tests/unit/module_utils/network/avi/test_avi_api_utils.py metaclass-boilerplate
tests/unit/module_utils/network/ftd/test_common.py future-import-boilerplate

View file

@ -21,8 +21,8 @@ import pytest
from ansible_collections.community.general.tests.unit.compat import mock, unittest
from ansible_collections.community.general.plugins.module_utils.gcp import (_get_gcp_ansible_credentials, _get_gcp_credentials, _get_gcp_environ_var,
_get_gcp_environment_credentials,
_validate_credentials_file)
_get_gcp_environment_credentials,
_validate_credentials_file)
# Fake data/function used for testing
fake_env_data = {'GCE_EMAIL': 'gce-email'}

View file

@ -17,9 +17,9 @@
# along with Ansible. If not, see <http://www.gnu.org/licenses/>.
from ansible_collections.community.general.tests.unit.compat import unittest
from ansible_collections.google.cloud.plugins.module_utils.gcp_utils import (GcpRequest,
navigate_hash,
remove_nones_from_dict,
replace_resource_dict)
navigate_hash,
remove_nones_from_dict,
replace_resource_dict)
class ReplaceResourceDictTestCase(unittest.TestCase):

View file

@ -1,152 +0,0 @@
# -*- coding: utf-8 -*-
# Copyright: (c) 2019, Bruno Inec (@sweenu) <bruno@inec.fr>
# GNU General Public License v3.0+ (see COPYING or https://www.gnu.org/licenses/gpl-3.0.txt)
import pytest
from ansible_collections.netbox.netbox.plugins.module_utils.net_tools.netbox.netbox_utils import (
QUERY_TYPES,
_build_diff,
create_netbox_object,
delete_netbox_object,
update_netbox_object,
normalize_data,
)
def test_normalize_data():
assert "name" not in QUERY_TYPES
assert QUERY_TYPES.get("rack") == "slug"
assert QUERY_TYPES.get("primary_ip") != "slug"
raw_data = {
"name": "Some name",
"primary_ip": "10.3.72.74/31",
"rack": "Some rack",
}
normalized_data = raw_data.copy()
normalized_data["rack"] = "some-rack"
assert normalize_data(raw_data) == normalized_data
def test_build_diff():
before = "The state before"
after = {"A": "more", "complicated": "state"}
diff = _build_diff(before=before, after=after)
assert diff == {"before": before, "after": after}
@pytest.fixture
def nb_obj_mock(mocker):
serialized_object = {"The serialized": "object"}
nb_obj = mocker.Mock(name="nb_obj_mock")
nb_obj.delete.return_value = True
nb_obj.update.return_value = True
nb_obj.update.side_effect = serialized_object.update
nb_obj.serialize.return_value = serialized_object
return nb_obj
@pytest.fixture
def endpoint_mock(mocker, nb_obj_mock):
endpoint = mocker.Mock(name="endpoint_mock")
endpoint.create.return_value = nb_obj_mock
return endpoint
@pytest.fixture
def on_creation_diff():
return _build_diff(before={"state": "absent"}, after={"state": "present"})
@pytest.fixture
def on_deletion_diff():
return _build_diff(before={"state": "present"}, after={"state": "absent"})
@pytest.fixture
def data():
return {"name": "Some Netbox object name"}
def test_create_netbox_object(endpoint_mock, data, on_creation_diff):
return_value = endpoint_mock.create().serialize()
serialized_obj, diff = create_netbox_object(
endpoint_mock, data, check_mode=False
)
assert endpoint_mock.create.called_once_with(data)
assert serialized_obj == return_value
assert diff == on_creation_diff
def test_create_netbox_object_in_check_mode(endpoint_mock, data, on_creation_diff):
serialized_obj, diff = create_netbox_object(
endpoint_mock, data, check_mode=True
)
assert endpoint_mock.create.not_called()
assert serialized_obj == data
assert diff == on_creation_diff
def test_delete_netbox_object(nb_obj_mock, on_deletion_diff):
serialized_obj, diff = delete_netbox_object(nb_obj_mock, check_mode=False)
assert nb_obj_mock.delete.called_once()
assert serialized_obj == nb_obj_mock.serialize()
assert diff == on_deletion_diff
def test_delete_netbox_object_in_check_mode(nb_obj_mock, on_deletion_diff):
serialized_obj, diff = delete_netbox_object(nb_obj_mock, check_mode=True)
assert nb_obj_mock.delete.not_called()
assert serialized_obj == nb_obj_mock.serialize()
assert diff == on_deletion_diff
def test_update_netbox_object_no_changes(nb_obj_mock):
unchanged_data = nb_obj_mock.serialize()
serialized_obj, diff = update_netbox_object(nb_obj_mock, unchanged_data, check_mode=True)
assert nb_obj_mock.update.not_called()
assert serialized_obj == unchanged_data
assert diff is None
@pytest.fixture
def changed_serialized_obj(nb_obj_mock):
changed_serialized_obj = nb_obj_mock.serialize().copy()
changed_serialized_obj[list(changed_serialized_obj.keys())[0]] += " (modified)"
return changed_serialized_obj
@pytest.fixture
def on_update_diff(nb_obj_mock, changed_serialized_obj):
return _build_diff(before=nb_obj_mock.serialize().copy(), after=changed_serialized_obj)
def test_update_netbox_object_with_changes(
nb_obj_mock, changed_serialized_obj, on_update_diff
):
serialized_obj, diff = update_netbox_object(
nb_obj_mock, changed_serialized_obj, check_mode=False
)
assert nb_obj_mock.update.called_once_with(changed_serialized_obj)
assert serialized_obj == nb_obj_mock.serialize()
assert diff == on_update_diff
def test_update_netbox_object_with_changes_in_check_mode(
nb_obj_mock, changed_serialized_obj, on_update_diff
):
updated_serialized_obj = nb_obj_mock.serialize().copy()
updated_serialized_obj.update(changed_serialized_obj)
serialized_obj, diff = update_netbox_object(
nb_obj_mock, changed_serialized_obj, check_mode=True
)
assert nb_obj_mock.update.not_called()
assert serialized_obj == updated_serialized_obj
assert diff == on_update_diff

View file

@ -9,7 +9,7 @@ __metaclass__ = type
import sys
from ansible_collections.community.general.tests.unit.compat import unittest
from ansible_collections.cisco.aci.plugins.module_utils.network.aci.aci import ACIModule
from ansible_collections.cisco.aci.plugins.module_utils.aci import ACIModule
from ansible.module_utils.six import PY2
from ansible.module_utils._text import to_native

View file

@ -21,7 +21,8 @@ from ansible_collections.community.general.tests.unit.compat import unittest
from ansible_collections.community.general.tests.unit.compat.mock import Mock
from ansible_collections.community.general.plugins.module_utils.network.netscaler.netscaler import ConfigProxy, get_immutables_intersection, ensure_feature_is_enabled, log, loglines
from ansible_collections.community.general.plugins.module_utils.network.netscaler.netscaler import (ConfigProxy, get_immutables_intersection,
ensure_feature_is_enabled, log, loglines)
class TestNetscalerConfigProxy(unittest.TestCase):

View file

@ -0,0 +1,73 @@
from __future__ import (absolute_import, division, print_function)
__metaclass__ = type
import pytest
from ansible_collections.community.general.tests.unit.compat.mock import MagicMock
from ansible_collections.community.kubernetes.plugins.module_utils.common import K8sAnsibleMixin
from ansible_collections.community.kubernetes.plugins.module_utils.raw import KubernetesRawModule
from ansible_collections.community.general.plugins.module_utils.kubevirt import KubeVirtRawModule
import openshift.dynamic
RESOURCE_DEFAULT_ARGS = {'api_version': 'v1alpha3', 'group': 'kubevirt.io',
'prefix': 'apis', 'namespaced': True}
class AnsibleExitJson(Exception):
"""Exception class to be raised by module.exit_json and caught
by the test case"""
def __init__(self, **kwargs):
for k in kwargs:
setattr(self, k, kwargs[k])
def __getitem__(self, attr):
return getattr(self, attr)
class AnsibleFailJson(Exception):
"""Exception class to be raised by module.fail_json and caught
by the test case"""
def __init__(self, **kwargs):
for k in kwargs:
setattr(self, k, kwargs[k])
def __getitem__(self, attr):
return getattr(self, attr)
def exit_json(*args, **kwargs):
kwargs['success'] = True
if 'changed' not in kwargs:
kwargs['changed'] = False
raise AnsibleExitJson(**kwargs)
def fail_json(*args, **kwargs):
kwargs['success'] = False
raise AnsibleFailJson(**kwargs)
@pytest.fixture()
def base_fixture(monkeypatch):
monkeypatch.setattr(
KubernetesRawModule, "exit_json", exit_json)
monkeypatch.setattr(
KubernetesRawModule, "fail_json", fail_json)
# Create mock methods in Resource directly, otherwise dyn client
# tries binding those to corresponding methods in DynamicClient
# (with partial()), which is more problematic to intercept
openshift.dynamic.Resource.get = MagicMock()
openshift.dynamic.Resource.create = MagicMock()
openshift.dynamic.Resource.delete = MagicMock()
openshift.dynamic.Resource.patch = MagicMock()
openshift.dynamic.Resource.search = MagicMock()
openshift.dynamic.Resource.watch = MagicMock()
# Globally mock some methods, since all tests will use this
KubernetesRawModule.patch_resource = MagicMock()
KubernetesRawModule.patch_resource.return_value = ({}, None)
K8sAnsibleMixin.get_api_client = MagicMock()
K8sAnsibleMixin.get_api_client.return_value = None
K8sAnsibleMixin.find_resource = MagicMock()
KubeVirtRawModule.find_supported_resource = MagicMock()

View file

@ -3,9 +3,9 @@ import pytest
openshiftdynamic = pytest.importorskip("openshift.dynamic")
from ansible_collections.community.general.tests.unit.modules.utils import set_module_args
from ansible_collections.community.general.tests.unit.utils.kubevirt_fixtures import base_fixture, RESOURCE_DEFAULT_ARGS, AnsibleExitJson
from .kubevirt_fixtures import base_fixture, RESOURCE_DEFAULT_ARGS, AnsibleExitJson
from ansible_collections.community.kubernetes.plugins.module_utils.k8s.raw import KubernetesRawModule
from ansible_collections.community.kubernetes.plugins.module_utils.raw import KubernetesRawModule
from ansible_collections.community.general.plugins.modules.cloud.kubevirt import kubevirt_rs as mymodule
KIND = 'VirtualMachineInstanceReplicaSet'

View file

@ -3,7 +3,7 @@ import pytest
openshiftdynamic = pytest.importorskip("openshift.dynamic")
from ansible_collections.community.general.tests.unit.modules.utils import set_module_args
from ansible_collections.community.general.tests.unit.utils.kubevirt_fixtures import base_fixture, RESOURCE_DEFAULT_ARGS, AnsibleExitJson
from .kubevirt_fixtures import base_fixture, RESOURCE_DEFAULT_ARGS, AnsibleExitJson
from ansible_collections.community.general.plugins.module_utils.kubevirt import KubeVirtRawModule
from ansible_collections.community.general.plugins.modules.cloud.kubevirt import kubevirt_vm as mymodule

View file

@ -130,10 +130,13 @@ testcase_module_params_wait = {
@pytest.mark.parametrize('power_state', testcase_set_powerstate['params'], ids=testcase_set_powerstate['ids'])
def test_xenserver_guest_powerstate_set_power_state(mocker, fake_ansible_module, XenAPI, xenserver_guest_powerstate, power_state):
"""Tests power state change handling."""
mocker.patch('ansible_collections.community.general.plugins.modules.cloud.xenserver.xenserver_guest_powerstate.get_object_ref', return_value=fake_xenapi_ref('VM'))
mocker.patch('ansible_collections.community.general.plugins.modules.cloud.xenserver.xenserver_guest_powerstate.gather_vm_params', return_value={"power_state": "Someoldstate"})
mocked_set_vm_power_state = mocker.patch('ansible_collections.community.general.plugins.modules.cloud.xenserver.xenserver_guest_powerstate.set_vm_power_state',
return_value=power_state)
mocker.patch('ansible_collections.community.general.plugins.modules.cloud.xenserver.xenserver_guest_powerstate.get_object_ref',
return_value=fake_xenapi_ref('VM'))
mocker.patch('ansible_collections.community.general.plugins.modules.cloud.xenserver.xenserver_guest_powerstate.gather_vm_params',
return_value={"power_state": "Someoldstate"})
mocked_set_vm_power_state = mocker.patch(
'ansible_collections.community.general.plugins.modules.cloud.xenserver.xenserver_guest_powerstate.set_vm_power_state',
return_value=power_state)
mocked_xenapi = mocker.patch.object(XenAPI.Session, 'xenapi', create=True)
@ -171,13 +174,17 @@ def test_xenserver_guest_powerstate_present(mocker, patch_ansible_module, capfd,
"""
fake_vm_facts = {"fake-vm-fact": True}
mocker.patch('ansible_collections.community.general.plugins.modules.cloud.xenserver.xenserver_guest_powerstate.get_object_ref', return_value=fake_xenapi_ref('VM'))
mocker.patch('ansible_collections.community.general.plugins.modules.cloud.xenserver.xenserver_guest_powerstate.get_object_ref',
return_value=fake_xenapi_ref('VM'))
mocker.patch('ansible_collections.community.general.plugins.modules.cloud.xenserver.xenserver_guest_powerstate.gather_vm_params', return_value={})
mocker.patch('ansible_collections.community.general.plugins.modules.cloud.xenserver.xenserver_guest_powerstate.gather_vm_facts', return_value=fake_vm_facts)
mocked_set_vm_power_state = mocker.patch('ansible_collections.community.general.plugins.modules.cloud.xenserver.xenserver_guest_powerstate.set_vm_power_state',
return_value=(True, "somenewstate"))
mocked_wait_for_vm_ip_address = mocker.patch('ansible_collections.community.general.plugins.modules.cloud.xenserver.xenserver_guest_powerstate.wait_for_vm_ip_address',
return_value={})
mocker.patch('ansible_collections.community.general.plugins.modules.cloud.xenserver.xenserver_guest_powerstate.gather_vm_facts',
return_value=fake_vm_facts)
mocked_set_vm_power_state = mocker.patch(
'ansible_collections.community.general.plugins.modules.cloud.xenserver.xenserver_guest_powerstate.set_vm_power_state',
return_value=(True, "somenewstate"))
mocked_wait_for_vm_ip_address = mocker.patch(
'ansible_collections.community.general.plugins.modules.cloud.xenserver.xenserver_guest_powerstate.wait_for_vm_ip_address',
return_value={})
mocked_xenapi = mocker.patch.object(XenAPI.Session, 'xenapi', create=True)
@ -214,7 +221,8 @@ def test_xenserver_guest_powerstate_other(mocker, patch_ansible_module, capfd, X
"""
fake_vm_facts = {"fake-vm-fact": True}
mocker.patch('ansible_collections.community.general.plugins.modules.cloud.xenserver.xenserver_guest_powerstate.get_object_ref', return_value=fake_xenapi_ref('VM'))
mocker.patch('ansible_collections.community.general.plugins.modules.cloud.xenserver.xenserver_guest_powerstate.get_object_ref',
return_value=fake_xenapi_ref('VM'))
mocker.patch('ansible_collections.community.general.plugins.modules.cloud.xenserver.xenserver_guest_powerstate.gather_vm_params', return_value={})
mocker.patch('ansible_collections.community.general.plugins.modules.cloud.xenserver.xenserver_guest_powerstate.gather_vm_facts', return_value=fake_vm_facts)
mocked_set_vm_power_state = mocker.patch(
@ -258,7 +266,8 @@ def test_xenserver_guest_powerstate_wait(mocker, patch_ansible_module, capfd, Xe
"""
fake_vm_facts = {"fake-vm-fact": True}
mocker.patch('ansible_collections.community.general.plugins.modules.cloud.xenserver.xenserver_guest_powerstate.get_object_ref', return_value=fake_xenapi_ref('VM'))
mocker.patch('ansible_collections.community.general.plugins.modules.cloud.xenserver.xenserver_guest_powerstate.get_object_ref',
return_value=fake_xenapi_ref('VM'))
mocker.patch('ansible_collections.community.general.plugins.modules.cloud.xenserver.xenserver_guest_powerstate.gather_vm_params', return_value={})
mocker.patch('ansible_collections.community.general.plugins.modules.cloud.xenserver.xenserver_guest_powerstate.gather_vm_facts', return_value=fake_vm_facts)
mocked_set_vm_power_state = mocker.patch(

View file

@ -39,7 +39,8 @@ class TestExosFactsModule(TestExosModule):
self.mock_run_commands = patch('ansible_collections.community.general.plugins.module_utils.network.exos.facts.legacy.base.run_commands')
self.run_commands = self.mock_run_commands.start()
self.mock_get_resource_connection = patch('ansible_collections.ansible.netcommon.plugins.module_utils.network.common.facts.facts.get_resource_connection')
self.mock_get_resource_connection = patch('ansible_collections.ansible.netcommon.plugins.module_utils.network.'
'common.facts.facts.get_resource_connection')
self.get_resource_connection = self.mock_get_resource_connection.start()
def tearDown(self):

View file

@ -19,7 +19,7 @@ __metaclass__ = type
import os
import json
from ansible_collections.fortinet.fortios.plugins.module_utils.network.fortimanager.fortimanager import FortiManagerHandler
from ansible_collections.fortinet.fortios.plugins.module_utils.fortimanager.fortimanager import FortiManagerHandler
import pytest
try:
@ -61,7 +61,7 @@ fmg_instance = FortiManagerHandler(connection_mock, module_mock)
def test_discover_device(fixture_data, mocker):
mocker.patch('ansible_collections.fortinet.fortios.plugins.module_utils.network.fortimanager.fortimanager.FortiManagerHandler.process_request',
mocker.patch('ansible_collections.fortinet.fortios.plugins.module_utils.fortimanager.fortimanager.FortiManagerHandler.process_request',
side_effect=fixture_data)
# Fixture sets used:###########################
@ -105,7 +105,7 @@ def test_discover_device(fixture_data, mocker):
def test_add_device(fixture_data, mocker):
mocker.patch('ansible_collections.fortinet.fortios.plugins.module_utils.network.fortimanager.fortimanager.FortiManagerHandler.process_request',
mocker.patch('ansible_collections.fortinet.fortios.plugins.module_utils.fortimanager.fortimanager.FortiManagerHandler.process_request',
side_effect=fixture_data)
# Fixture sets used:###########################
@ -149,7 +149,7 @@ def test_add_device(fixture_data, mocker):
def test_delete_device(fixture_data, mocker):
mocker.patch('ansible_collections.fortinet.fortios.plugins.module_utils.network.fortimanager.fortimanager.FortiManagerHandler.process_request',
mocker.patch('ansible_collections.fortinet.fortios.plugins.module_utils.fortimanager.fortimanager.FortiManagerHandler.process_request',
side_effect=fixture_data)
# Fixture sets used:###########################
@ -193,7 +193,7 @@ def test_delete_device(fixture_data, mocker):
def test_get_device(fixture_data, mocker):
mocker.patch('ansible_collections.fortinet.fortios.plugins.module_utils.network.fortimanager.fortimanager.FortiManagerHandler.process_request',
mocker.patch('ansible_collections.fortinet.fortios.plugins.module_utils.fortimanager.fortimanager.FortiManagerHandler.process_request',
side_effect=fixture_data)
# Fixture sets used:###########################

View file

@ -19,7 +19,7 @@ __metaclass__ = type
import os
import json
from ansible_collections.fortinet.fortios.plugins.module_utils.network.fortimanager.fortimanager import FortiManagerHandler
from ansible_collections.fortinet.fortios.plugins.module_utils.fortimanager.fortimanager import FortiManagerHandler
import pytest
try:
@ -61,7 +61,7 @@ fmg_instance = FortiManagerHandler(connection_mock, module_mock)
def test_update_device_hostname(fixture_data, mocker):
mocker.patch('ansible_collections.fortinet.fortios.plugins.module_utils.network.fortimanager.fortimanager.FortiManagerHandler.process_request',
mocker.patch('ansible_collections.fortinet.fortios.plugins.module_utils.fortimanager.fortimanager.FortiManagerHandler.process_request',
side_effect=fixture_data)
# Fixture sets used:###########################
@ -108,7 +108,7 @@ def test_update_device_hostname(fixture_data, mocker):
def test_update_device_interface(fixture_data, mocker):
mocker.patch('ansible_collections.fortinet.fortios.plugins.module_utils.network.fortimanager.fortimanager.FortiManagerHandler.process_request',
mocker.patch('ansible_collections.fortinet.fortios.plugins.module_utils.fortimanager.fortimanager.FortiManagerHandler.process_request',
side_effect=fixture_data)
# Fixture sets used:###########################
@ -155,7 +155,7 @@ def test_update_device_interface(fixture_data, mocker):
def test_exec_config(fixture_data, mocker):
mocker.patch('ansible_collections.fortinet.fortios.plugins.module_utils.network.fortimanager.fortimanager.FortiManagerHandler.process_request',
mocker.patch('ansible_collections.fortinet.fortios.plugins.module_utils.fortimanager.fortimanager.FortiManagerHandler.process_request',
side_effect=fixture_data)
# Fixture sets used:###########################

View file

@ -19,7 +19,7 @@ __metaclass__ = type
import os
import json
from ansible_collections.fortinet.fortios.plugins.module_utils.network.fortimanager.fortimanager import FortiManagerHandler
from ansible_collections.fortinet.fortios.plugins.module_utils.fortimanager.fortimanager import FortiManagerHandler
import pytest
try:
@ -61,7 +61,7 @@ fmg_instance = FortiManagerHandler(connection_mock, module_mock)
def test_add_device_group(fixture_data, mocker):
mocker.patch('ansible_collections.fortinet.fortios.plugins.module_utils.network.fortimanager.fortimanager.FortiManagerHandler.process_request',
mocker.patch('ansible_collections.fortinet.fortios.plugins.module_utils.fortimanager.fortimanager.FortiManagerHandler.process_request',
side_effect=fixture_data)
# Fixture sets used:###########################
@ -113,7 +113,7 @@ def test_add_device_group(fixture_data, mocker):
def test_delete_device_group(fixture_data, mocker):
mocker.patch('ansible_collections.fortinet.fortios.plugins.module_utils.network.fortimanager.fortimanager.FortiManagerHandler.process_request',
mocker.patch('ansible_collections.fortinet.fortios.plugins.module_utils.fortimanager.fortimanager.FortiManagerHandler.process_request',
side_effect=fixture_data)
# Fixture sets used:###########################
@ -143,7 +143,7 @@ def test_delete_device_group(fixture_data, mocker):
def test_add_group_member(fixture_data, mocker):
mocker.patch('ansible_collections.fortinet.fortios.plugins.module_utils.network.fortimanager.fortimanager.FortiManagerHandler.process_request',
mocker.patch('ansible_collections.fortinet.fortios.plugins.module_utils.fortimanager.fortimanager.FortiManagerHandler.process_request',
side_effect=fixture_data)
# Fixture sets used:###########################
@ -173,7 +173,7 @@ def test_add_group_member(fixture_data, mocker):
def test_delete_group_member(fixture_data, mocker):
mocker.patch('ansible_collections.fortinet.fortios.plugins.module_utils.network.fortimanager.fortimanager.FortiManagerHandler.process_request',
mocker.patch('ansible_collections.fortinet.fortios.plugins.module_utils.fortimanager.fortimanager.FortiManagerHandler.process_request',
side_effect=fixture_data)
# Fixture sets used:###########################

View file

@ -19,7 +19,7 @@ __metaclass__ = type
import os
import json
from ansible_collections.fortinet.fortios.plugins.module_utils.network.fortimanager.fortimanager import FortiManagerHandler
from ansible_collections.fortinet.fortios.plugins.module_utils.fortimanager.fortimanager import FortiManagerHandler
import pytest
try:
@ -63,7 +63,7 @@ fmg_instance = FortiManagerHandler(connection_mock, module_mock)
def test_get_devprof(fixture_data, mocker):
mocker.patch('ansible_collections.fortinet.fortios.plugins.module_utils.network.fortimanager.fortimanager.FortiManagerHandler.process_request',
mocker.patch('ansible_collections.fortinet.fortios.plugins.module_utils.fortimanager.fortimanager.FortiManagerHandler.process_request',
side_effect=fixture_data)
# Fixture sets used:###########################
@ -771,7 +771,7 @@ def test_get_devprof(fixture_data, mocker):
def test_set_devprof(fixture_data, mocker):
mocker.patch('ansible_collections.fortinet.fortios.plugins.module_utils.network.fortimanager.fortimanager.FortiManagerHandler.process_request',
mocker.patch('ansible_collections.fortinet.fortios.plugins.module_utils.fortimanager.fortimanager.FortiManagerHandler.process_request',
side_effect=fixture_data)
# Fixture sets used:###########################
@ -849,7 +849,7 @@ def test_set_devprof(fixture_data, mocker):
def test_set_devprof_scope(fixture_data, mocker):
mocker.patch('ansible_collections.fortinet.fortios.plugins.module_utils.network.fortimanager.fortimanager.FortiManagerHandler.process_request',
mocker.patch('ansible_collections.fortinet.fortios.plugins.module_utils.fortimanager.fortimanager.FortiManagerHandler.process_request',
side_effect=fixture_data)
# Fixture sets used:###########################
@ -927,7 +927,7 @@ def test_set_devprof_scope(fixture_data, mocker):
def test_set_devprof_snmp(fixture_data, mocker):
mocker.patch('ansible_collections.fortinet.fortios.plugins.module_utils.network.fortimanager.fortimanager.FortiManagerHandler.process_request',
mocker.patch('ansible_collections.fortinet.fortios.plugins.module_utils.fortimanager.fortimanager.FortiManagerHandler.process_request',
side_effect=fixture_data)
# Fixture sets used:###########################
@ -1145,7 +1145,7 @@ def test_set_devprof_snmp(fixture_data, mocker):
def test_set_devprof_snmp_v2c(fixture_data, mocker):
mocker.patch('ansible_collections.fortinet.fortios.plugins.module_utils.network.fortimanager.fortimanager.FortiManagerHandler.process_request',
mocker.patch('ansible_collections.fortinet.fortios.plugins.module_utils.fortimanager.fortimanager.FortiManagerHandler.process_request',
side_effect=fixture_data)
# Fixture sets used:###########################
@ -1223,7 +1223,7 @@ def test_set_devprof_snmp_v2c(fixture_data, mocker):
def test_set_devprof_snmp_v3(fixture_data, mocker):
mocker.patch('ansible_collections.fortinet.fortios.plugins.module_utils.network.fortimanager.fortimanager.FortiManagerHandler.process_request',
mocker.patch('ansible_collections.fortinet.fortios.plugins.module_utils.fortimanager.fortimanager.FortiManagerHandler.process_request',
side_effect=fixture_data)
# Fixture sets used:###########################
@ -1301,7 +1301,7 @@ def test_set_devprof_snmp_v3(fixture_data, mocker):
def test_set_devprof_syslog(fixture_data, mocker):
mocker.patch('ansible_collections.fortinet.fortios.plugins.module_utils.network.fortimanager.fortimanager.FortiManagerHandler.process_request',
mocker.patch('ansible_collections.fortinet.fortios.plugins.module_utils.fortimanager.fortimanager.FortiManagerHandler.process_request',
side_effect=fixture_data)
# Fixture sets used:###########################
@ -1379,7 +1379,7 @@ def test_set_devprof_syslog(fixture_data, mocker):
def test_set_devprof_ntp(fixture_data, mocker):
mocker.patch('ansible_collections.fortinet.fortios.plugins.module_utils.network.fortimanager.fortimanager.FortiManagerHandler.process_request',
mocker.patch('ansible_collections.fortinet.fortios.plugins.module_utils.fortimanager.fortimanager.FortiManagerHandler.process_request',
side_effect=fixture_data)
# Fixture sets used:###########################
@ -1527,7 +1527,7 @@ def test_set_devprof_ntp(fixture_data, mocker):
def test_set_devprof_admin(fixture_data, mocker):
mocker.patch('ansible_collections.fortinet.fortios.plugins.module_utils.network.fortimanager.fortimanager.FortiManagerHandler.process_request',
mocker.patch('ansible_collections.fortinet.fortios.plugins.module_utils.fortimanager.fortimanager.FortiManagerHandler.process_request',
side_effect=fixture_data)
# Fixture sets used:###########################
@ -1605,7 +1605,7 @@ def test_set_devprof_admin(fixture_data, mocker):
def test_set_devprof_smtp(fixture_data, mocker):
mocker.patch('ansible_collections.fortinet.fortios.plugins.module_utils.network.fortimanager.fortimanager.FortiManagerHandler.process_request',
mocker.patch('ansible_collections.fortinet.fortios.plugins.module_utils.fortimanager.fortimanager.FortiManagerHandler.process_request',
side_effect=fixture_data)
# Fixture sets used:###########################
@ -1683,7 +1683,7 @@ def test_set_devprof_smtp(fixture_data, mocker):
def test_set_devprof_dns(fixture_data, mocker):
mocker.patch('ansible_collections.fortinet.fortios.plugins.module_utils.network.fortimanager.fortimanager.FortiManagerHandler.process_request',
mocker.patch('ansible_collections.fortinet.fortios.plugins.module_utils.fortimanager.fortimanager.FortiManagerHandler.process_request',
side_effect=fixture_data)
# Fixture sets used:###########################

View file

@ -19,7 +19,7 @@ __metaclass__ = type
import os
import json
from ansible_collections.fortinet.fortios.plugins.module_utils.network.fortimanager.fortimanager import FortiManagerHandler
from ansible_collections.fortinet.fortios.plugins.module_utils.fortimanager.fortimanager import FortiManagerHandler
import pytest
try:
@ -61,7 +61,7 @@ fmg_instance = FortiManagerHandler(connection_mock, module_mock)
def test_fmgr_fwobj_ipv4(fixture_data, mocker):
mocker.patch('ansible_collections.fortinet.fortios.plugins.module_utils.network.fortimanager.fortimanager.FortiManagerHandler.process_request',
mocker.patch('ansible_collections.fortinet.fortios.plugins.module_utils.fortimanager.fortimanager.FortiManagerHandler.process_request',
side_effect=fixture_data)
# Test using fixture 1 #
@ -121,7 +121,7 @@ def test_fmgr_fwobj_ipv4(fixture_data, mocker):
def test_fmgr_fwobj_ipv6(fixture_data, mocker):
mocker.patch('ansible_collections.fortinet.fortios.plugins.module_utils.network.fortimanager.fortimanager.FortiManagerHandler.process_request',
mocker.patch('ansible_collections.fortinet.fortios.plugins.module_utils.fortimanager.fortimanager.FortiManagerHandler.process_request',
side_effect=fixture_data)
# Test using fixture 1 #
@ -142,7 +142,7 @@ def test_fmgr_fwobj_ipv6(fixture_data, mocker):
def test_fmgr_fwobj_multicast(fixture_data, mocker):
mocker.patch('ansible_collections.fortinet.fortios.plugins.module_utils.network.fortimanager.fortimanager.FortiManagerHandler.process_request',
mocker.patch('ansible_collections.fortinet.fortios.plugins.module_utils.fortimanager.fortimanager.FortiManagerHandler.process_request',
side_effect=fixture_data)
# Test using fixture 1 #

View file

@ -19,7 +19,7 @@ __metaclass__ = type
import os
import json
from ansible_collections.fortinet.fortios.plugins.module_utils.network.fortimanager.fortimanager import FortiManagerHandler
from ansible_collections.fortinet.fortios.plugins.module_utils.fortimanager.fortimanager import FortiManagerHandler
import pytest
try:
@ -61,7 +61,7 @@ fmg_instance = FortiManagerHandler(connection_mock, module_mock)
def test_fmgr_fwobj_ippool_modify(fixture_data, mocker):
mocker.patch('ansible_collections.fortinet.fortios.plugins.module_utils.network.fortimanager.fortimanager.FortiManagerHandler.process_request',
mocker.patch('ansible_collections.fortinet.fortios.plugins.module_utils.fortimanager.fortimanager.FortiManagerHandler.process_request',
side_effect=fixture_data)
# Test using fixture 1 #

View file

@ -19,7 +19,7 @@ __metaclass__ = type
import os
import json
from ansible_collections.fortinet.fortios.plugins.module_utils.network.fortimanager.fortimanager import FortiManagerHandler
from ansible_collections.fortinet.fortios.plugins.module_utils.fortimanager.fortimanager import FortiManagerHandler
import pytest
try:
@ -61,7 +61,7 @@ fmg_instance = FortiManagerHandler(connection_mock, module_mock)
def test_fmgr_fwobj_ippool6_modify(fixture_data, mocker):
mocker.patch('ansible_collections.fortinet.fortios.plugins.module_utils.network.fortimanager.fortimanager.FortiManagerHandler.process_request',
mocker.patch('ansible_collections.fortinet.fortios.plugins.module_utils.fortimanager.fortimanager.FortiManagerHandler.process_request',
side_effect=fixture_data)
# Test using fixture 1 #

View file

@ -19,7 +19,7 @@ __metaclass__ = type
import os
import json
from ansible_collections.fortinet.fortios.plugins.module_utils.network.fortimanager.fortimanager import FortiManagerHandler
from ansible_collections.fortinet.fortios.plugins.module_utils.fortimanager.fortimanager import FortiManagerHandler
import pytest
try:
@ -61,7 +61,7 @@ fmg_instance = FortiManagerHandler(connection_mock, module_mock)
def test_fmgr_fwobj_service_custom(fixture_data, mocker):
mocker.patch('ansible_collections.fortinet.fortios.plugins.module_utils.network.fortimanager.fortimanager.FortiManagerHandler.process_request',
mocker.patch('ansible_collections.fortinet.fortios.plugins.module_utils.fortimanager.fortimanager.FortiManagerHandler.process_request',
side_effect=fixture_data)
# Test using fixture 1 #
@ -103,7 +103,7 @@ def test_fmgr_fwobj_service_custom(fixture_data, mocker):
def test_fmgr_fwobj_service_group(fixture_data, mocker):
mocker.patch('ansible_collections.fortinet.fortios.plugins.module_utils.network.fortimanager.fortimanager.FortiManagerHandler.process_request',
mocker.patch('ansible_collections.fortinet.fortios.plugins.module_utils.fortimanager.fortimanager.FortiManagerHandler.process_request',
side_effect=fixture_data)
# Test using fixture 1 #
@ -115,7 +115,7 @@ def test_fmgr_fwobj_service_group(fixture_data, mocker):
def test_fmgr_fwobj_service_category(fixture_data, mocker):
mocker.patch('ansible_collections.fortinet.fortios.plugins.module_utils.network.fortimanager.fortimanager.FortiManagerHandler.process_request',
mocker.patch('ansible_collections.fortinet.fortios.plugins.module_utils.fortimanager.fortimanager.FortiManagerHandler.process_request',
side_effect=fixture_data)
# Test using fixture 1 #

View file

@ -19,7 +19,7 @@ __metaclass__ = type
import os
import json
from ansible_collections.fortinet.fortios.plugins.module_utils.network.fortimanager.fortimanager import FortiManagerHandler
from ansible_collections.fortinet.fortios.plugins.module_utils.fortimanager.fortimanager import FortiManagerHandler
import pytest
try:
@ -61,7 +61,7 @@ fmg_instance = FortiManagerHandler(connection_mock, module_mock)
def test_fmgr_firewall_vip_modify(fixture_data, mocker):
mocker.patch('ansible_collections.fortinet.fortios.plugins.module_utils.network.fortimanager.fortimanager.FortiManagerHandler.process_request',
mocker.patch('ansible_collections.fortinet.fortios.plugins.module_utils.fortimanager.fortimanager.FortiManagerHandler.process_request',
side_effect=fixture_data)
# Fixture sets used:###########################

View file

@ -19,7 +19,7 @@ __metaclass__ = type
import os
import json
from ansible_collections.fortinet.fortios.plugins.module_utils.network.fortimanager.fortimanager import FortiManagerHandler
from ansible_collections.fortinet.fortios.plugins.module_utils.fortimanager.fortimanager import FortiManagerHandler
import pytest
try:
@ -61,7 +61,7 @@ fmg_instance = FortiManagerHandler(connection_mock, module_mock)
def test_fmgr_firewall_policy_modify(fixture_data, mocker):
mocker.patch('ansible_collections.fortinet.fortios.plugins.module_utils.network.fortimanager.fortimanager.FortiManagerHandler.process_request',
mocker.patch('ansible_collections.fortinet.fortios.plugins.module_utils.fortimanager.fortimanager.FortiManagerHandler.process_request',
side_effect=fixture_data)
# Fixture sets used:###########################

View file

@ -20,7 +20,7 @@ __metaclass__ = type
import os
import json
from ansible_collections.fortinet.fortios.plugins.module_utils.network.fortimanager.fortimanager import FortiManagerHandler
from ansible_collections.fortinet.fortios.plugins.module_utils.fortimanager.fortimanager import FortiManagerHandler
import pytest
try:
@ -62,7 +62,7 @@ fmg_instance = FortiManagerHandler(connection_mock, module_mock)
def test_fmgr_fwpol_package(fixture_data, mocker):
mocker.patch('ansible_collections.fortinet.fortios.plugins.module_utils.network.fortimanager.fortimanager.FortiManagerHandler.process_request',
mocker.patch('ansible_collections.fortinet.fortios.plugins.module_utils.fortimanager.fortimanager.FortiManagerHandler.process_request',
side_effect=fixture_data)
# Test using fixture 1 #
@ -80,7 +80,7 @@ def test_fmgr_fwpol_package(fixture_data, mocker):
def test_fmgr_fwpol_package_folder(fixture_data, mocker):
mocker.patch('ansible_collections.fortinet.fortios.plugins.module_utils.network.fortimanager.fortimanager.FortiManagerHandler.process_request',
mocker.patch('ansible_collections.fortinet.fortios.plugins.module_utils.fortimanager.fortimanager.FortiManagerHandler.process_request',
side_effect=fixture_data)
# Test using fixture 1 #

View file

@ -19,7 +19,7 @@ __metaclass__ = type
import os
import json
from ansible_collections.fortinet.fortios.plugins.module_utils.network.fortimanager.fortimanager import FortiManagerHandler
from ansible_collections.fortinet.fortios.plugins.module_utils.fortimanager.fortimanager import FortiManagerHandler
import pytest
try:
@ -61,7 +61,7 @@ fmg_instance = FortiManagerHandler(connection_mock, module_mock)
def test_fmgr_set_ha_mode(fixture_data, mocker):
mocker.patch('ansible_collections.fortinet.fortios.plugins.module_utils.network.fortimanager.fortimanager.FortiManagerHandler.process_request',
mocker.patch('ansible_collections.fortinet.fortios.plugins.module_utils.fortimanager.fortimanager.FortiManagerHandler.process_request',
side_effect=fixture_data)
# Fixture sets used:###########################
@ -133,7 +133,7 @@ def test_fmgr_set_ha_mode(fixture_data, mocker):
def test_fmgr_get_ha_peer_list(fixture_data, mocker):
mocker.patch('ansible_collections.fortinet.fortios.plugins.module_utils.network.fortimanager.fortimanager.FortiManagerHandler.process_request',
mocker.patch('ansible_collections.fortinet.fortios.plugins.module_utils.fortimanager.fortimanager.FortiManagerHandler.process_request',
side_effect=fixture_data)
# Fixture sets used:###########################
@ -173,7 +173,7 @@ def test_fmgr_get_ha_peer_list(fixture_data, mocker):
def test_fmgr_set_ha_peer(fixture_data, mocker):
mocker.patch('ansible_collections.fortinet.fortios.plugins.module_utils.network.fortimanager.fortimanager.FortiManagerHandler.process_request',
mocker.patch('ansible_collections.fortinet.fortios.plugins.module_utils.fortimanager.fortimanager.FortiManagerHandler.process_request',
side_effect=fixture_data)
# Fixture sets used:###########################

View file

@ -19,7 +19,7 @@ __metaclass__ = type
import os
import json
from ansible_collections.fortinet.fortios.plugins.module_utils.network.fortimanager.fortimanager import FortiManagerHandler
from ansible_collections.fortinet.fortios.plugins.module_utils.fortimanager.fortimanager import FortiManagerHandler
import pytest
try:
@ -61,7 +61,7 @@ fmg_instance = FortiManagerHandler(connection_mock, module_mock)
def test_fmgr_get_custom(fixture_data, mocker):
mocker.patch('ansible_collections.fortinet.fortios.plugins.module_utils.network.fortimanager.fortimanager.FortiManagerHandler.process_request',
mocker.patch('ansible_collections.fortinet.fortios.plugins.module_utils.fortimanager.fortimanager.FortiManagerHandler.process_request',
side_effect=fixture_data)
# Fixture sets used:###########################
@ -84,7 +84,7 @@ def test_fmgr_get_custom(fixture_data, mocker):
def test_fmgr_get_task_status(fixture_data, mocker):
mocker.patch('ansible_collections.fortinet.fortios.plugins.module_utils.network.fortimanager.fortimanager.FortiManagerHandler.process_request',
mocker.patch('ansible_collections.fortinet.fortios.plugins.module_utils.fortimanager.fortimanager.FortiManagerHandler.process_request',
side_effect=fixture_data)
# Fixture sets used:###########################

View file

@ -19,7 +19,7 @@ __metaclass__ = type
import os
import json
from ansible_collections.fortinet.fortios.plugins.module_utils.network.fortimanager.fortimanager import FortiManagerHandler
from ansible_collections.fortinet.fortios.plugins.module_utils.fortimanager.fortimanager import FortiManagerHandler
import pytest
try:
@ -61,7 +61,7 @@ fmg_instance = FortiManagerHandler(connection_mock, module_mock)
def test_set_script(fixture_data, mocker):
mocker.patch('ansible_collections.fortinet.fortios.plugins.module_utils.network.fortimanager.fortimanager.FortiManagerHandler.process_request',
mocker.patch('ansible_collections.fortinet.fortios.plugins.module_utils.fortimanager.fortimanager.FortiManagerHandler.process_request',
side_effect=fixture_data)
# Fixture sets used:###########################
@ -84,7 +84,7 @@ def test_set_script(fixture_data, mocker):
def test_delete_script(fixture_data, mocker):
mocker.patch('ansible_collections.fortinet.fortios.plugins.module_utils.network.fortimanager.fortimanager.FortiManagerHandler.process_request',
mocker.patch('ansible_collections.fortinet.fortios.plugins.module_utils.fortimanager.fortimanager.FortiManagerHandler.process_request',
side_effect=fixture_data)
# Fixture sets used:###########################
@ -107,7 +107,7 @@ def test_delete_script(fixture_data, mocker):
def test_execute_script(fixture_data, mocker):
mocker.patch('ansible_collections.fortinet.fortios.plugins.module_utils.network.fortimanager.fortimanager.FortiManagerHandler.process_request',
mocker.patch('ansible_collections.fortinet.fortios.plugins.module_utils.fortimanager.fortimanager.FortiManagerHandler.process_request',
side_effect=fixture_data)
# Fixture sets used:###########################

View file

@ -19,7 +19,7 @@ __metaclass__ = type
import os
import json
from ansible_collections.fortinet.fortios.plugins.module_utils.network.fortimanager.fortimanager import FortiManagerHandler
from ansible_collections.fortinet.fortios.plugins.module_utils.fortimanager.fortimanager import FortiManagerHandler
import pytest
try:
@ -61,7 +61,7 @@ fmg_instance = FortiManagerHandler(connection_mock, module_mock)
def test_fmgr_application_list_modify(fixture_data, mocker):
mocker.patch('ansible_collections.fortinet.fortios.plugins.module_utils.network.fortimanager.fortimanager.FortiManagerHandler.process_request',
mocker.patch('ansible_collections.fortinet.fortios.plugins.module_utils.fortimanager.fortimanager.FortiManagerHandler.process_request',
side_effect=fixture_data)
# Test using fixture 1 #

View file

@ -19,7 +19,7 @@ __metaclass__ = type
import os
import json
from ansible_collections.fortinet.fortios.plugins.module_utils.network.fortimanager.fortimanager import FortiManagerHandler
from ansible_collections.fortinet.fortios.plugins.module_utils.fortimanager.fortimanager import FortiManagerHandler
import pytest
try:
@ -61,7 +61,7 @@ fmg_instance = FortiManagerHandler(connection_mock, module_mock)
def test_fmgr_antivirus_profile_modify(fixture_data, mocker):
mocker.patch('ansible_collections.fortinet.fortios.plugins.module_utils.network.fortimanager.fortimanager.FortiManagerHandler.process_request',
mocker.patch('ansible_collections.fortinet.fortios.plugins.module_utils.fortimanager.fortimanager.FortiManagerHandler.process_request',
side_effect=fixture_data)
# Test using fixture 1 #

View file

@ -19,7 +19,7 @@ __metaclass__ = type
import os
import json
from ansible_collections.fortinet.fortios.plugins.module_utils.network.fortimanager.fortimanager import FortiManagerHandler
from ansible_collections.fortinet.fortios.plugins.module_utils.fortimanager.fortimanager import FortiManagerHandler
import pytest
try:
@ -61,7 +61,7 @@ fmg_instance = FortiManagerHandler(connection_mock, module_mock)
def test_fmgr_dnsfilter_profile_modify(fixture_data, mocker):
mocker.patch('ansible_collections.fortinet.fortios.plugins.module_utils.network.fortimanager.fortimanager.FortiManagerHandler.process_request',
mocker.patch('ansible_collections.fortinet.fortios.plugins.module_utils.fortimanager.fortimanager.FortiManagerHandler.process_request',
side_effect=fixture_data)
# Fixture sets used:###########################

View file

@ -19,7 +19,7 @@ __metaclass__ = type
import os
import json
from ansible_collections.fortinet.fortios.plugins.module_utils.network.fortimanager.fortimanager import FortiManagerHandler
from ansible_collections.fortinet.fortios.plugins.module_utils.fortimanager.fortimanager import FortiManagerHandler
import pytest
try:
@ -61,7 +61,7 @@ fmg_instance = FortiManagerHandler(connection_mock, module_mock)
def test_fmgr_ips_sensor_modify(fixture_data, mocker):
mocker.patch('ansible_collections.fortinet.fortios.plugins.module_utils.network.fortimanager.fortimanager.FortiManagerHandler.process_request',
mocker.patch('ansible_collections.fortinet.fortios.plugins.module_utils.fortimanager.fortimanager.FortiManagerHandler.process_request',
side_effect=fixture_data)
# Test using fixture 1 #

View file

@ -19,7 +19,7 @@ __metaclass__ = type
import os
import json
from ansible_collections.fortinet.fortios.plugins.module_utils.network.fortimanager.fortimanager import FortiManagerHandler
from ansible_collections.fortinet.fortios.plugins.module_utils.fortimanager.fortimanager import FortiManagerHandler
import pytest
try:
@ -61,7 +61,7 @@ fmg_instance = FortiManagerHandler(connection_mock, module_mock)
def test_fmgr_firewall_profile_group_modify(fixture_data, mocker):
mocker.patch('ansible_collections.fortinet.fortios.plugins.module_utils.network.fortimanager.fortimanager.FortiManagerHandler.process_request',
mocker.patch('ansible_collections.fortinet.fortios.plugins.module_utils.fortimanager.fortimanager.FortiManagerHandler.process_request',
side_effect=fixture_data)
# Fixture sets used:###########################

View file

@ -19,7 +19,7 @@ __metaclass__ = type
import os
import json
from ansible_collections.fortinet.fortios.plugins.module_utils.network.fortimanager.fortimanager import FortiManagerHandler
from ansible_collections.fortinet.fortios.plugins.module_utils.fortimanager.fortimanager import FortiManagerHandler
import pytest
try:
@ -61,7 +61,7 @@ fmg_instance = FortiManagerHandler(connection_mock, module_mock)
def test_fmgr_web_proxy_profile_modify(fixture_data, mocker):
mocker.patch('ansible_collections.fortinet.fortios.plugins.module_utils.network.fortimanager.fortimanager.FortiManagerHandler.process_request',
mocker.patch('ansible_collections.fortinet.fortios.plugins.module_utils.fortimanager.fortimanager.FortiManagerHandler.process_request',
side_effect=fixture_data)
# Test using fixture 1 #

View file

@ -19,7 +19,7 @@ __metaclass__ = type
import os
import json
from ansible_collections.fortinet.fortios.plugins.module_utils.network.fortimanager.fortimanager import FortiManagerHandler
from ansible_collections.fortinet.fortios.plugins.module_utils.fortimanager.fortimanager import FortiManagerHandler
import pytest
try:
@ -61,7 +61,7 @@ fmg_instance = FortiManagerHandler(connection_mock, module_mock)
def test_fmgr_spamfilter_profile_modify(fixture_data, mocker):
mocker.patch('ansible_collections.fortinet.fortios.plugins.module_utils.network.fortimanager.fortimanager.FortiManagerHandler.process_request',
mocker.patch('ansible_collections.fortinet.fortios.plugins.module_utils.fortimanager.fortimanager.FortiManagerHandler.process_request',
side_effect=fixture_data)
# Test using fixture 1 #

Some files were not shown because too many files have changed in this diff Show more