Various f5 modules fixes (#40037)

* Add members to bigip_gtm_pool
* Add monitors to bigip_gtm_pool
* Add availability_requirements to bigip_gtm_pool
* Refactor bigip_gtm_pool
* Normalize the product value returned by gtm facts
* Corrected various documentation
* Updated various F5 coding conventions
* Add partition to bigip_static_route
* Added more unit tests
This commit is contained in:
Tim Rupp
2018-05-11 14:07:28 -07:00
committed by GitHub
parent 61e7c77dec
commit 383a4f026e
14 changed files with 746 additions and 126 deletions

View File

@@ -20,15 +20,17 @@ from ansible.compat.tests.mock import patch
from ansible.module_utils.basic import AnsibleModule
try:
from library.bigip_hostname import Parameters
from library.bigip_hostname import ModuleManager
from library.bigip_hostname import ArgumentSpec
from library.modules.bigip_hostname import ApiParameters
from library.modules.bigip_hostname import ModuleParameters
from library.modules.bigip_hostname import ModuleManager
from library.modules.bigip_hostname import ArgumentSpec
from library.module_utils.network.f5.common import F5ModuleError
from library.module_utils.network.f5.common import iControlUnexpectedHTTPError
from test.unit.modules.utils import set_module_args
except ImportError:
try:
from ansible.modules.network.f5.bigip_hostname import Parameters
from ansible.modules.network.f5.bigip_hostname import ApiParameters
from ansible.modules.network.f5.bigip_hostname import ModuleParameters
from ansible.modules.network.f5.bigip_hostname import ModuleManager
from ansible.modules.network.f5.bigip_hostname import ArgumentSpec
from ansible.module_utils.network.f5.common import F5ModuleError
@@ -64,7 +66,7 @@ class TestParameters(unittest.TestCase):
args = dict(
hostname='foo.internal.com'
)
p = Parameters(params=args)
p = ModuleParameters(params=args)
assert p.hostname == 'foo.internal.com'
@@ -83,8 +85,8 @@ class TestManager(unittest.TestCase):
# Configure the parameters that would be returned by querying the
# remote device
current = Parameters(
dict(
current = ApiParameters(
params=dict(
hostname='foo.internal.com'
)
)