mirror of
https://github.com/ansible-collections/community.general.git
synced 2025-05-03 07:41:30 -07:00
Makes all unit tests look the same (#25762)
Just a little cleanup from an earlier patch that makes f5 unit tests only run if the f5 sdk is installed
This commit is contained in:
parent
41f6f8f410
commit
c51b73d800
12 changed files with 173 additions and 207 deletions
|
@ -20,14 +20,13 @@
|
|||
from __future__ import (absolute_import, division, print_function)
|
||||
__metaclass__ = type
|
||||
|
||||
import sys
|
||||
|
||||
if sys.version_info < (2, 7):
|
||||
from nose.plugins.skip import SkipTest
|
||||
raise SkipTest("F5 Ansible modules require Python >= 2.7")
|
||||
|
||||
import os
|
||||
import json
|
||||
import sys
|
||||
|
||||
from nose.plugins.skip import SkipTest
|
||||
if sys.version_info < (2, 7):
|
||||
raise SkipTest("F5 Ansible modules require Python >= 2.7")
|
||||
|
||||
from ansible.compat.tests import unittest
|
||||
from ansible.compat.tests.mock import patch, Mock
|
||||
|
@ -45,11 +44,10 @@ except ImportError:
|
|||
from ansible.modules.network.f5.bigip_command import ModuleManager
|
||||
from ansible.modules.network.f5.bigip_command import ArgumentSpec
|
||||
except ImportError:
|
||||
from nose.plugins.skip import SkipTest
|
||||
raise SkipTest("%s requires the python modules for f5/bigip" % __file__)
|
||||
|
||||
raise SkipTest("F5 Ansible modules require the f5-sdk Python library")
|
||||
|
||||
fixture_path = os.path.join(os.path.dirname(__file__), 'fixtures')
|
||||
fixture_data = {}
|
||||
|
||||
|
||||
def set_module_args(args):
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue