[stable-9] Unit tests: replace mock and compat with code from community.internal_test_tools (#9923)
Some checks failed
EOL CI / EOL Sanity (Ⓐ2.13) (push) Has been cancelled
EOL CI / EOL Sanity (Ⓐ2.14) (push) Has been cancelled
EOL CI / EOL Sanity (Ⓐ2.15) (push) Has been cancelled
EOL CI / EOL Units (Ⓐ2.13+py2.7) (push) Has been cancelled
EOL CI / EOL Units (Ⓐ2.13+py3.8) (push) Has been cancelled
EOL CI / EOL Units (Ⓐ2.14+py3.9) (push) Has been cancelled
EOL CI / EOL Units (Ⓐ2.15+py3.10) (push) Has been cancelled
EOL CI / EOL Units (Ⓐ2.15+py3.5) (push) Has been cancelled
EOL CI / EOL I (Ⓐ2.13+alpine3+py:azp/posix/1/) (push) Has been cancelled
EOL CI / EOL I (Ⓐ2.13+alpine3+py:azp/posix/2/) (push) Has been cancelled
EOL CI / EOL I (Ⓐ2.13+alpine3+py:azp/posix/3/) (push) Has been cancelled
EOL CI / EOL I (Ⓐ2.13+fedora35+py:azp/posix/1/) (push) Has been cancelled
EOL CI / EOL I (Ⓐ2.13+fedora35+py:azp/posix/2/) (push) Has been cancelled
EOL CI / EOL I (Ⓐ2.13+fedora35+py:azp/posix/3/) (push) Has been cancelled
EOL CI / EOL I (Ⓐ2.13+opensuse15py2+py:azp/posix/1/) (push) Has been cancelled
EOL CI / EOL I (Ⓐ2.13+opensuse15py2+py:azp/posix/2/) (push) Has been cancelled
EOL CI / EOL I (Ⓐ2.13+opensuse15py2+py:azp/posix/3/) (push) Has been cancelled
EOL CI / EOL I (Ⓐ2.14+alpine3+py:azp/posix/1/) (push) Has been cancelled
EOL CI / EOL I (Ⓐ2.14+alpine3+py:azp/posix/2/) (push) Has been cancelled
EOL CI / EOL I (Ⓐ2.14+alpine3+py:azp/posix/3/) (push) Has been cancelled
EOL CI / EOL I (Ⓐ2.15+fedora37+py:azp/posix/1/) (push) Has been cancelled
EOL CI / EOL I (Ⓐ2.15+fedora37+py:azp/posix/2/) (push) Has been cancelled
EOL CI / EOL I (Ⓐ2.15+fedora37+py:azp/posix/3/) (push) Has been cancelled
import-galaxy / Test to import built collection artifact with Galaxy importer (push) Has been cancelled
Verify REUSE / check (push) Has been cancelled

* Unit tests: replace mock and compat with code from community.internal_test_tools (#9921)

* Replace compat with equivalent from community.internal_test_tools.

* Replace mock with equivalent from community.internal_test_tools.

* Remove ignore.txt entries.

* Add test that's no longer present in later versions.
This commit is contained in:
Felix Fontein 2025-03-22 14:32:01 +01:00 committed by GitHub
parent 928cdaaf87
commit 7df07f31a6
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
134 changed files with 175 additions and 578 deletions

View file

@ -10,6 +10,5 @@ plugins/modules/udm_user.py import-3.11 # Uses deprecated stdlib library 'crypt
plugins/modules/udm_user.py import-3.12 # Uses deprecated stdlib library 'crypt' plugins/modules/udm_user.py import-3.12 # Uses deprecated stdlib library 'crypt'
plugins/modules/xfconf.py validate-modules:return-syntax-error plugins/modules/xfconf.py validate-modules:return-syntax-error
plugins/module_utils/univention_umc.py pylint:use-yield-from # suggested construct does not work with Python 2 plugins/module_utils/univention_umc.py pylint:use-yield-from # suggested construct does not work with Python 2
tests/unit/compat/mock.py pylint:use-yield-from # suggested construct does not work with Python 2
tests/unit/plugins/modules/helper.py pylint:use-yield-from # suggested construct does not work with Python 2 tests/unit/plugins/modules/helper.py pylint:use-yield-from # suggested construct does not work with Python 2
tests/unit/plugins/modules/test_gio_mime.yaml no-smart-quotes tests/unit/plugins/modules/test_gio_mime.yaml no-smart-quotes

View file

@ -10,6 +10,5 @@ plugins/modules/udm_user.py import-3.11 # Uses deprecated stdlib library 'crypt
plugins/modules/udm_user.py import-3.12 # Uses deprecated stdlib library 'crypt' plugins/modules/udm_user.py import-3.12 # Uses deprecated stdlib library 'crypt'
plugins/modules/xfconf.py validate-modules:return-syntax-error plugins/modules/xfconf.py validate-modules:return-syntax-error
plugins/module_utils/univention_umc.py pylint:use-yield-from # suggested construct does not work with Python 2 plugins/module_utils/univention_umc.py pylint:use-yield-from # suggested construct does not work with Python 2
tests/unit/compat/mock.py pylint:use-yield-from # suggested construct does not work with Python 2
tests/unit/plugins/modules/helper.py pylint:use-yield-from # suggested construct does not work with Python 2 tests/unit/plugins/modules/helper.py pylint:use-yield-from # suggested construct does not work with Python 2
tests/unit/plugins/modules/test_gio_mime.yaml no-smart-quotes tests/unit/plugins/modules/test_gio_mime.yaml no-smart-quotes

View file

@ -10,6 +10,5 @@ plugins/modules/udm_user.py import-3.11 # Uses deprecated stdlib library 'crypt
plugins/modules/udm_user.py import-3.12 # Uses deprecated stdlib library 'crypt' plugins/modules/udm_user.py import-3.12 # Uses deprecated stdlib library 'crypt'
plugins/modules/xfconf.py validate-modules:return-syntax-error plugins/modules/xfconf.py validate-modules:return-syntax-error
plugins/module_utils/univention_umc.py pylint:use-yield-from # suggested construct does not work with Python 2 plugins/module_utils/univention_umc.py pylint:use-yield-from # suggested construct does not work with Python 2
tests/unit/compat/mock.py pylint:use-yield-from # suggested construct does not work with Python 2
tests/unit/plugins/modules/helper.py pylint:use-yield-from # suggested construct does not work with Python 2 tests/unit/plugins/modules/helper.py pylint:use-yield-from # suggested construct does not work with Python 2
tests/unit/plugins/modules/test_gio_mime.yaml no-smart-quotes tests/unit/plugins/modules/test_gio_mime.yaml no-smart-quotes

View file

@ -1,20 +0,0 @@
# Copyright (c) 2014, Toshio Kuratomi <tkuratomi@ansible.com>
# GNU General Public License v3.0+ (see LICENSES/GPL-3.0-or-later.txt or https://www.gnu.org/licenses/gpl-3.0.txt)
# SPDX-License-Identifier: GPL-3.0-or-later
# Make coding more python3-ish
from __future__ import (absolute_import, division, print_function)
__metaclass__ = type
#
# Compat for python2.7
#
# One unittest needs to import builtins via __import__() so we need to have
# the string that represents it
try:
import __builtin__ # noqa: F401, pylint: disable=unused-import
except ImportError:
BUILTINS = 'builtins'
else:
BUILTINS = '__builtin__'

View file

@ -1,109 +0,0 @@
# Copyright (c) 2014, Toshio Kuratomi <tkuratomi@ansible.com>
# GNU General Public License v3.0+ (see LICENSES/GPL-3.0-or-later.txt or https://www.gnu.org/licenses/gpl-3.0.txt)
# SPDX-License-Identifier: GPL-3.0-or-later
# Make coding more python3-ish
from __future__ import (absolute_import, division, print_function)
__metaclass__ = type
'''
Compat module for Python3.x's unittest.mock module
'''
import sys
# Python 2.7
# Note: Could use the pypi mock library on python3.x as well as python2.x. It
# is the same as the python3 stdlib mock library
try:
# Allow wildcard import because we really do want to import all of mock's
# symbols into this compat shim
# pylint: disable=wildcard-import,unused-wildcard-import
from unittest.mock import * # noqa: F401, pylint: disable=unused-import
except ImportError:
# Python 2
# pylint: disable=wildcard-import,unused-wildcard-import
try:
from mock import * # noqa: F401, pylint: disable=unused-import
except ImportError:
print('You need the mock library installed on python2.x to run tests')
# Prior to 3.4.4, mock_open cannot handle binary read_data
if sys.version_info >= (3,) and sys.version_info < (3, 4, 4):
file_spec = None
def _iterate_read_data(read_data):
# Helper for mock_open:
# Retrieve lines from read_data via a generator so that separate calls to
# readline, read, and readlines are properly interleaved
sep = b'\n' if isinstance(read_data, bytes) else '\n'
data_as_list = [l + sep for l in read_data.split(sep)]
if data_as_list[-1] == sep:
# If the last line ended in a newline, the list comprehension will have an
# extra entry that's just a newline. Remove this.
data_as_list = data_as_list[:-1]
else:
# If there wasn't an extra newline by itself, then the file being
# emulated doesn't have a newline to end the last line remove the
# newline that our naive format() added
data_as_list[-1] = data_as_list[-1][:-1]
for line in data_as_list:
yield line
def mock_open(mock=None, read_data=''):
"""
A helper function to create a mock to replace the use of `open`. It works
for `open` called directly or used as a context manager.
The `mock` argument is the mock object to configure. If `None` (the
default) then a `MagicMock` will be created for you, with the API limited
to methods or attributes available on standard file handles.
`read_data` is a string for the `read` methoddline`, and `readlines` of the
file handle to return. This is an empty string by default.
"""
def _readlines_side_effect(*args, **kwargs):
if handle.readlines.return_value is not None:
return handle.readlines.return_value
return list(_data)
def _read_side_effect(*args, **kwargs):
if handle.read.return_value is not None:
return handle.read.return_value
return type(read_data)().join(_data)
def _readline_side_effect():
if handle.readline.return_value is not None:
while True:
yield handle.readline.return_value
for line in _data:
yield line
global file_spec
if file_spec is None:
import _io
file_spec = list(set(dir(_io.TextIOWrapper)).union(set(dir(_io.BytesIO))))
if mock is None:
mock = MagicMock(name='open', spec=open)
handle = MagicMock(spec=file_spec)
handle.__enter__.return_value = handle
_data = _iterate_read_data(read_data)
handle.write.return_value = None
handle.read.return_value = None
handle.readline.return_value = None
handle.readlines.return_value = None
handle.read.side_effect = _read_side_effect
handle.readline.side_effect = _readline_side_effect()
handle.readlines.side_effect = _readlines_side_effect
mock.return_value = handle
return mock

View file

@ -1,25 +0,0 @@
# Copyright (c) 2014, Toshio Kuratomi <tkuratomi@ansible.com>
# GNU General Public License v3.0+ (see LICENSES/GPL-3.0-or-later.txt or https://www.gnu.org/licenses/gpl-3.0.txt)
# SPDX-License-Identifier: GPL-3.0-or-later
# Make coding more python3-ish
from __future__ import (absolute_import, division, print_function)
__metaclass__ = type
'''
Compat module for Python2.7's unittest module
'''
import sys
# Allow wildcard import because we really do want to import all of
# unittests's symbols into this compat shim
# pylint: disable=wildcard-import,unused-wildcard-import
if sys.version_info < (2, 7):
try:
# Need unittest2 on python2.6
from unittest2 import * # noqa: F401, pylint: disable=unused-import
except ImportError:
print('You need unittest2 installed on python2.6.x to run tests')
else:
from unittest import * # noqa: F401, pylint: disable=unused-import

View file

@ -1,12 +0,0 @@
# Copyright (c) Ansible Project
# GNU General Public License v3.0+ (see LICENSES/GPL-3.0-or-later.txt or https://www.gnu.org/licenses/gpl-3.0.txt)
# SPDX-License-Identifier: GPL-3.0-or-later
from __future__ import (absolute_import, division, print_function)
__metaclass__ = type
from ansible_collections.community.general.tests.unit.compat.mock import MagicMock
from ansible.utils.path import unfrackpath
mock_unfrackpath_noop = MagicMock(spec_set=unfrackpath, side_effect=lambda x, *args, **kwargs: x)

View file

@ -1,77 +0,0 @@
# Copyright (c) 2016, Matt Davis <mdavis@ansible.com>
# Copyright (c) 2016, Toshio Kuratomi <tkuratomi@ansible.com>
#
# GNU General Public License v3.0+ (see LICENSES/GPL-3.0-or-later.txt or https://www.gnu.org/licenses/gpl-3.0.txt)
# SPDX-License-Identifier: GPL-3.0-or-later
from __future__ import (absolute_import, division, print_function)
__metaclass__ = type
import sys
import json
from contextlib import contextmanager
from io import BytesIO, StringIO
from ansible_collections.community.general.tests.unit.compat import unittest
from ansible.module_utils.six import PY3
from ansible.module_utils.common.text.converters import to_bytes
@contextmanager
def swap_stdin_and_argv(stdin_data='', argv_data=tuple()):
"""
context manager that temporarily masks the test runner's values for stdin and argv
"""
real_stdin = sys.stdin
real_argv = sys.argv
if PY3:
fake_stream = StringIO(stdin_data)
fake_stream.buffer = BytesIO(to_bytes(stdin_data))
else:
fake_stream = BytesIO(to_bytes(stdin_data))
try:
sys.stdin = fake_stream
sys.argv = argv_data
yield
finally:
sys.stdin = real_stdin
sys.argv = real_argv
@contextmanager
def swap_stdout():
"""
context manager that temporarily replaces stdout for tests that need to verify output
"""
old_stdout = sys.stdout
if PY3:
fake_stream = StringIO()
else:
fake_stream = BytesIO()
try:
sys.stdout = fake_stream
yield fake_stream
finally:
sys.stdout = old_stdout
class ModuleTestCase(unittest.TestCase):
def setUp(self, module_args=None):
if module_args is None:
module_args = {'_ansible_remote_tmp': '/tmp', '_ansible_keep_remote_files': False}
args = json.dumps(dict(ANSIBLE_MODULE_ARGS=module_args))
# unittest doesn't have a clean place to use a context manager, so we have to enter/exit manually
self.stdin_swap = swap_stdin_and_argv(stdin_data=args)
self.stdin_swap.__enter__()
def tearDown(self):
# unittest doesn't have a clean place to use a context manager, so we have to enter/exit manually
self.stdin_swap.__exit__(None, None, None)

View file

@ -1,29 +0,0 @@
# Copyright (c) Ansible project
# GNU General Public License v3.0+ (see LICENSES/GPL-3.0-or-later.txt or https://www.gnu.org/licenses/gpl-3.0.txt)
# SPDX-License-Identifier: GPL-3.0-or-later
from __future__ import (absolute_import, division, print_function)
__metaclass__ = type
from ansible.module_utils.common.text.converters import to_bytes
from ansible.parsing.vault import VaultSecret
class TextVaultSecret(VaultSecret):
'''A secret piece of text. ie, a password. Tracks text encoding.
The text encoding of the text may not be the default text encoding so
we keep track of the encoding so we encode it to the same bytes.'''
def __init__(self, text, encoding=None, errors=None, _bytes=None):
super(TextVaultSecret, self).__init__()
self.text = text
self.encoding = encoding or 'utf-8'
self._bytes = _bytes
self.errors = errors or 'strict'
@property
def bytes(self):
'''The text encoded with encoding, unless we specifically set _bytes.'''
return self._bytes or to_bytes(self.text, encoding=self.encoding, errors=self.errors)

View file

@ -1,128 +0,0 @@
# Copyright (c) Ansible project
# GNU General Public License v3.0+ (see LICENSES/GPL-3.0-or-later.txt or https://www.gnu.org/licenses/gpl-3.0.txt)
# SPDX-License-Identifier: GPL-3.0-or-later
from __future__ import (absolute_import, division, print_function)
__metaclass__ = type
import io
import yaml
from ansible.module_utils.six import PY3
from ansible.parsing.yaml.loader import AnsibleLoader
from ansible.parsing.yaml.dumper import AnsibleDumper
class YamlTestUtils(object):
"""Mixin class to combine with a unittest.TestCase subclass."""
def _loader(self, stream):
"""Vault related tests will want to override this.
Vault cases should setup a AnsibleLoader that has the vault password."""
return AnsibleLoader(stream)
def _dump_stream(self, obj, stream, dumper=None):
"""Dump to a py2-unicode or py3-string stream."""
if PY3:
return yaml.dump(obj, stream, Dumper=dumper)
else:
return yaml.dump(obj, stream, Dumper=dumper, encoding=None)
def _dump_string(self, obj, dumper=None):
"""Dump to a py2-unicode or py3-string"""
if PY3:
return yaml.dump(obj, Dumper=dumper)
else:
return yaml.dump(obj, Dumper=dumper, encoding=None)
def _dump_load_cycle(self, obj):
# Each pass though a dump or load revs the 'generation'
# obj to yaml string
string_from_object_dump = self._dump_string(obj, dumper=AnsibleDumper)
# wrap a stream/file like StringIO around that yaml
stream_from_object_dump = io.StringIO(string_from_object_dump)
loader = self._loader(stream_from_object_dump)
# load the yaml stream to create a new instance of the object (gen 2)
obj_2 = loader.get_data()
# dump the gen 2 objects directory to strings
string_from_object_dump_2 = self._dump_string(obj_2,
dumper=AnsibleDumper)
# The gen 1 and gen 2 yaml strings
self.assertEqual(string_from_object_dump, string_from_object_dump_2)
# the gen 1 (orig) and gen 2 py object
self.assertEqual(obj, obj_2)
# again! gen 3... load strings into py objects
stream_3 = io.StringIO(string_from_object_dump_2)
loader_3 = self._loader(stream_3)
obj_3 = loader_3.get_data()
string_from_object_dump_3 = self._dump_string(obj_3, dumper=AnsibleDumper)
self.assertEqual(obj, obj_3)
# should be transitive, but...
self.assertEqual(obj_2, obj_3)
self.assertEqual(string_from_object_dump, string_from_object_dump_3)
def _old_dump_load_cycle(self, obj):
'''Dump the passed in object to yaml, load it back up, dump again, compare.'''
stream = io.StringIO()
yaml_string = self._dump_string(obj, dumper=AnsibleDumper)
self._dump_stream(obj, stream, dumper=AnsibleDumper)
yaml_string_from_stream = stream.getvalue()
# reset stream
stream.seek(0)
loader = self._loader(stream)
# loader = AnsibleLoader(stream, vault_password=self.vault_password)
obj_from_stream = loader.get_data()
stream_from_string = io.StringIO(yaml_string)
loader2 = self._loader(stream_from_string)
# loader2 = AnsibleLoader(stream_from_string, vault_password=self.vault_password)
obj_from_string = loader2.get_data()
stream_obj_from_stream = io.StringIO()
stream_obj_from_string = io.StringIO()
if PY3:
yaml.dump(obj_from_stream, stream_obj_from_stream, Dumper=AnsibleDumper)
yaml.dump(obj_from_stream, stream_obj_from_string, Dumper=AnsibleDumper)
else:
yaml.dump(obj_from_stream, stream_obj_from_stream, Dumper=AnsibleDumper, encoding=None)
yaml.dump(obj_from_stream, stream_obj_from_string, Dumper=AnsibleDumper, encoding=None)
yaml_string_stream_obj_from_stream = stream_obj_from_stream.getvalue()
yaml_string_stream_obj_from_string = stream_obj_from_string.getvalue()
stream_obj_from_stream.seek(0)
stream_obj_from_string.seek(0)
if PY3:
yaml_string_obj_from_stream = yaml.dump(obj_from_stream, Dumper=AnsibleDumper)
yaml_string_obj_from_string = yaml.dump(obj_from_string, Dumper=AnsibleDumper)
else:
yaml_string_obj_from_stream = yaml.dump(obj_from_stream, Dumper=AnsibleDumper, encoding=None)
yaml_string_obj_from_string = yaml.dump(obj_from_string, Dumper=AnsibleDumper, encoding=None)
assert yaml_string == yaml_string_obj_from_stream
assert yaml_string == yaml_string_obj_from_stream == yaml_string_obj_from_string
assert (yaml_string == yaml_string_obj_from_stream == yaml_string_obj_from_string == yaml_string_stream_obj_from_stream ==
yaml_string_stream_obj_from_string)
assert obj == obj_from_stream
assert obj == obj_from_string
assert obj == yaml_string_obj_from_stream
assert obj == yaml_string_obj_from_string
assert obj == obj_from_stream == obj_from_string == yaml_string_obj_from_stream == yaml_string_obj_from_string
return {'obj': obj,
'yaml_string': yaml_string,
'yaml_string_from_stream': yaml_string_from_stream,
'obj_from_stream': obj_from_stream,
'obj_from_string': obj_from_string,
'yaml_string_obj_from_string': yaml_string_obj_from_string}

View file

@ -7,8 +7,8 @@ __metaclass__ = type
from ansible.playbook.task import Task from ansible.playbook.task import Task
from ansible.executor.task_result import TaskResult from ansible.executor.task_result import TaskResult
from ansible_collections.community.general.tests.unit.compat import unittest from ansible_collections.community.internal_test_tools.tests.unit.compat import unittest
from ansible_collections.community.general.tests.unit.compat.mock import patch, MagicMock, Mock from ansible_collections.community.internal_test_tools.tests.unit.compat.mock import patch, MagicMock, Mock
from ansible_collections.community.general.plugins.callback.elastic import ElasticSource, TaskData from ansible_collections.community.general.plugins.callback.elastic import ElasticSource, TaskData
from collections import OrderedDict from collections import OrderedDict
import sys import sys

View file

@ -6,8 +6,8 @@ from __future__ import (absolute_import, division, print_function)
__metaclass__ = type __metaclass__ = type
from ansible.executor.task_result import TaskResult from ansible.executor.task_result import TaskResult
from ansible_collections.community.general.tests.unit.compat import unittest from ansible_collections.community.internal_test_tools.tests.unit.compat import unittest
from ansible_collections.community.general.tests.unit.compat.mock import patch, Mock from ansible_collections.community.internal_test_tools.tests.unit.compat.mock import patch, Mock
from ansible_collections.community.general.plugins.callback.loganalytics import AzureLogAnalyticsSource from ansible_collections.community.general.plugins.callback.loganalytics import AzureLogAnalyticsSource
from datetime import datetime from datetime import datetime

View file

@ -8,8 +8,8 @@ __metaclass__ = type
from ansible.playbook.task import Task from ansible.playbook.task import Task
from ansible.executor.task_result import TaskResult from ansible.executor.task_result import TaskResult
from ansible_collections.community.general.tests.unit.compat import unittest from ansible_collections.community.internal_test_tools.tests.unit.compat import unittest
from ansible_collections.community.general.tests.unit.compat.mock import patch, MagicMock, Mock from ansible_collections.community.internal_test_tools.tests.unit.compat.mock import patch, MagicMock, Mock
from ansible_collections.community.general.plugins.callback.opentelemetry import OpenTelemetrySource, TaskData from ansible_collections.community.general.plugins.callback.opentelemetry import OpenTelemetrySource, TaskData
from collections import OrderedDict from collections import OrderedDict
import sys import sys

View file

@ -6,8 +6,8 @@ from __future__ import (absolute_import, division, print_function)
__metaclass__ = type __metaclass__ = type
from ansible.executor.task_result import TaskResult from ansible.executor.task_result import TaskResult
from ansible_collections.community.general.tests.unit.compat import unittest from ansible_collections.community.internal_test_tools.tests.unit.compat import unittest
from ansible_collections.community.general.tests.unit.compat.mock import patch, Mock from ansible_collections.community.internal_test_tools.tests.unit.compat.mock import patch, Mock
from ansible_collections.community.general.plugins.callback.splunk import SplunkHTTPCollectorSource from ansible_collections.community.general.plugins.callback.splunk import SplunkHTTPCollectorSource
from datetime import datetime from datetime import datetime

View file

@ -14,7 +14,7 @@ from io import StringIO
from ansible.errors import AnsibleError from ansible.errors import AnsibleError
from ansible.playbook.play_context import PlayContext from ansible.playbook.play_context import PlayContext
from ansible.plugins.loader import connection_loader from ansible.plugins.loader import connection_loader
from ansible_collections.community.general.tests.unit.compat import mock from ansible_collections.community.internal_test_tools.tests.unit.compat import mock
@pytest.fixture(autouse=True) @pytest.fixture(autouse=True)

View file

@ -6,7 +6,7 @@
from __future__ import (absolute_import, division, print_function) from __future__ import (absolute_import, division, print_function)
__metaclass__ = type __metaclass__ = type
from ansible_collections.community.general.tests.unit.compat import unittest from ansible_collections.community.internal_test_tools.tests.unit.compat import unittest
from ansible_collections.community.general.plugins.filter.crc32 import crc32s from ansible_collections.community.general.plugins.filter.crc32 import crc32s

View file

@ -20,9 +20,9 @@ from ansible.inventory.data import InventoryData
from ansible.inventory.manager import InventoryManager from ansible.inventory.manager import InventoryManager
from ansible.module_utils.common.text.converters import to_native from ansible.module_utils.common.text.converters import to_native
from ansible_collections.community.internal_test_tools.tests.unit.mock.loader import DictDataLoader from ansible_collections.community.internal_test_tools.tests.unit.mock.loader import DictDataLoader
from ansible_collections.community.internal_test_tools.tests.unit.mock.path import mock_unfrackpath_noop
from ansible_collections.community.general.plugins.inventory.opennebula import InventoryModule from ansible_collections.community.general.plugins.inventory.opennebula import InventoryModule
from ansible_collections.community.general.tests.unit.mock.path import mock_unfrackpath_noop
original_exists = os.path.exists original_exists = os.path.exists

View file

@ -7,8 +7,8 @@ from __future__ import (absolute_import, division, print_function)
__metaclass__ = type __metaclass__ = type
import re import re
from ansible_collections.community.general.tests.unit.compat import unittest from ansible_collections.community.internal_test_tools.tests.unit.compat import unittest
from ansible_collections.community.general.tests.unit.compat.mock import patch from ansible_collections.community.internal_test_tools.tests.unit.compat.mock import patch
from ansible.errors import AnsibleError from ansible.errors import AnsibleError
from ansible.module_utils import six from ansible.module_utils import six

View file

@ -8,8 +8,8 @@ from __future__ import (absolute_import, division, print_function)
__metaclass__ = type __metaclass__ = type
import json import json
from ansible_collections.community.general.tests.unit.compat import unittest from ansible_collections.community.internal_test_tools.tests.unit.compat import unittest
from ansible_collections.community.general.tests.unit.compat.mock import patch from ansible_collections.community.internal_test_tools.tests.unit.compat.mock import patch
from ansible.errors import AnsibleLookupError from ansible.errors import AnsibleLookupError
from ansible.plugins.loader import lookup_loader from ansible.plugins.loader import lookup_loader

View file

@ -8,8 +8,8 @@ from __future__ import absolute_import, division, print_function
__metaclass__ = type __metaclass__ = type
from ansible_collections.community.general.tests.unit.compat.unittest import TestCase from ansible_collections.community.internal_test_tools.tests.unit.compat.unittest import TestCase
from ansible_collections.community.general.tests.unit.compat.mock import ( from ansible_collections.community.internal_test_tools.tests.unit.compat.mock import (
patch, patch,
MagicMock, MagicMock,
) )

View file

@ -8,8 +8,8 @@ from __future__ import (absolute_import, division, print_function)
__metaclass__ = type __metaclass__ = type
from ansible_collections.community.general.tests.unit.compat import unittest from ansible_collections.community.internal_test_tools.tests.unit.compat import unittest
from ansible_collections.community.general.tests.unit.compat.mock import patch, MagicMock from ansible_collections.community.internal_test_tools.tests.unit.compat.mock import patch, MagicMock
from ansible_collections.community.general.plugins.lookup import etcd3 from ansible_collections.community.general.plugins.lookup import etcd3
from ansible.plugins.loader import lookup_loader from ansible.plugins.loader import lookup_loader

View file

@ -7,8 +7,8 @@ from __future__ import (absolute_import, division, print_function)
__metaclass__ = type __metaclass__ = type
import json import json
from ansible_collections.community.general.tests.unit.compat import unittest from ansible_collections.community.internal_test_tools.tests.unit.compat import unittest
from ansible_collections.community.general.tests.unit.compat.mock import ( from ansible_collections.community.internal_test_tools.tests.unit.compat.mock import (
patch, patch,
MagicMock, MagicMock,
mock_open mock_open

View file

@ -8,8 +8,8 @@ __metaclass__ = type
from argparse import ArgumentParser from argparse import ArgumentParser
from ansible_collections.community.general.tests.unit.compat import unittest from ansible_collections.community.internal_test_tools.tests.unit.compat import unittest
from ansible_collections.community.general.tests.unit.compat.mock import patch from ansible_collections.community.internal_test_tools.tests.unit.compat.mock import patch
from ansible.errors import AnsibleError from ansible.errors import AnsibleError
from ansible.module_utils import six from ansible.module_utils import six

View file

@ -5,8 +5,8 @@
from __future__ import (absolute_import, division, print_function) from __future__ import (absolute_import, division, print_function)
__metaclass__ = type __metaclass__ = type
from ansible_collections.community.general.tests.unit.compat import unittest from ansible_collections.community.internal_test_tools.tests.unit.compat import unittest
from ansible_collections.community.general.tests.unit.compat.mock import patch, call from ansible_collections.community.internal_test_tools.tests.unit.compat.mock import patch, call
from ansible.errors import AnsibleError from ansible.errors import AnsibleError
from ansible.module_utils.urls import ConnectionError, SSLValidationError from ansible.module_utils.urls import ConnectionError, SSLValidationError
from ansible.module_utils.six.moves.urllib.error import HTTPError, URLError from ansible.module_utils.six.moves.urllib.error import HTTPError, URLError

View file

@ -6,8 +6,8 @@
from __future__ import (absolute_import, division, print_function) from __future__ import (absolute_import, division, print_function)
__metaclass__ = type __metaclass__ = type
from ansible_collections.community.general.tests.unit.compat import unittest from ansible_collections.community.internal_test_tools.tests.unit.compat import unittest
from ansible_collections.community.general.tests.unit.compat.mock import patch from ansible_collections.community.internal_test_tools.tests.unit.compat.mock import patch
from ansible_collections.community.internal_test_tools.tests.unit.mock.loader import DictDataLoader from ansible_collections.community.internal_test_tools.tests.unit.mock.loader import DictDataLoader
from ansible.plugins import AnsiblePlugin from ansible.plugins import AnsiblePlugin

View file

@ -6,8 +6,8 @@ from __future__ import absolute_import, division, print_function
__metaclass__ = type __metaclass__ = type
from ansible_collections.community.general.tests.unit.compat.unittest import TestCase from ansible_collections.community.internal_test_tools.tests.unit.compat.unittest import TestCase
from ansible_collections.community.general.tests.unit.compat.mock import ( from ansible_collections.community.internal_test_tools.tests.unit.compat.mock import (
patch, patch,
MagicMock, MagicMock,
) )

View file

@ -8,8 +8,8 @@ from __future__ import absolute_import, division, print_function
__metaclass__ = type __metaclass__ = type
from ansible_collections.community.general.tests.unit.compat.unittest import TestCase from ansible_collections.community.internal_test_tools.tests.unit.compat.unittest import TestCase
from ansible_collections.community.general.tests.unit.compat.mock import ( from ansible_collections.community.internal_test_tools.tests.unit.compat.mock import (
patch, patch,
DEFAULT, DEFAULT,
MagicMock, MagicMock,

View file

@ -7,7 +7,7 @@ __metaclass__ = type
import random import random
from ansible_collections.community.general.tests.unit.compat import unittest from ansible_collections.community.internal_test_tools.tests.unit.compat import unittest
from ansible_collections.community.general.plugins.module_utils.cloud import _exponential_backoff, \ from ansible_collections.community.general.plugins.module_utils.cloud import _exponential_backoff, \
_full_jitter_backoff _full_jitter_backoff

View file

@ -5,7 +5,7 @@
from __future__ import (absolute_import, division, print_function) from __future__ import (absolute_import, division, print_function)
__metaclass__ = type __metaclass__ = type
from ansible_collections.community.general.tests.unit.compat import unittest from ansible_collections.community.internal_test_tools.tests.unit.compat import unittest
from ansible_collections.community.general.plugins.module_utils.scaleway import SecretVariables, argon2 from ansible_collections.community.general.plugins.module_utils.scaleway import SecretVariables, argon2

View file

@ -9,7 +9,7 @@
from __future__ import (absolute_import, division, print_function) from __future__ import (absolute_import, division, print_function)
__metaclass__ = type __metaclass__ = type
from ansible_collections.community.general.tests.unit.compat import unittest from ansible_collections.community.internal_test_tools.tests.unit.compat import unittest
from ansible_collections.community.general.plugins.module_utils.hwc_utils import are_different_dicts from ansible_collections.community.general.plugins.module_utils.hwc_utils import are_different_dicts

View file

@ -8,7 +8,7 @@ __metaclass__ = type
import sys import sys
from ansible_collections.community.general.tests.unit.compat import unittest from ansible_collections.community.internal_test_tools.tests.unit.compat import unittest
from ansible_collections.community.general.plugins.module_utils.hwc_utils import (HwcModuleException, navigate_value) from ansible_collections.community.general.plugins.module_utils.hwc_utils import (HwcModuleException, navigate_value)

View file

@ -11,7 +11,7 @@ from functools import partial
import pytest import pytest
from ansible_collections.community.general.tests.unit.compat.mock import MagicMock, PropertyMock from ansible_collections.community.internal_test_tools.tests.unit.compat.mock import MagicMock, PropertyMock
from ansible_collections.community.general.plugins.module_utils.cmd_runner import CmdRunner, cmd_runner_fmt from ansible_collections.community.general.plugins.module_utils.cmd_runner import CmdRunner, cmd_runner_fmt

View file

@ -11,7 +11,7 @@ import re
import shutil import shutil
import tempfile import tempfile
from ansible_collections.community.general.tests.unit.compat import unittest from ansible_collections.community.internal_test_tools.tests.unit.compat import unittest
from ansible_collections.community.general.plugins.module_utils.ocapi_utils import OcapiUtils from ansible_collections.community.general.plugins.module_utils.ocapi_utils import OcapiUtils

View file

@ -10,7 +10,7 @@ import os
import pytest import pytest
from ansible_collections.community.general.tests.unit.compat.mock import MagicMock, PropertyMock from ansible_collections.community.internal_test_tools.tests.unit.compat.mock import MagicMock, PropertyMock
from ansible_collections.community.general.plugins.module_utils.cmd_runner import cmd_runner_fmt from ansible_collections.community.general.plugins.module_utils.cmd_runner import cmd_runner_fmt
from ansible_collections.community.general.plugins.module_utils.python_runner import PythonRunner from ansible_collections.community.general.plugins.module_utils.python_runner import PythonRunner

View file

@ -12,7 +12,7 @@ import sys
from httmock import response # noqa from httmock import response # noqa
from httmock import urlmatch # noqa from httmock import urlmatch # noqa
from ansible_collections.community.general.tests.unit.compat import unittest from ansible_collections.community.internal_test_tools.tests.unit.compat import unittest
import gitlab import gitlab

View file

@ -8,7 +8,7 @@
from __future__ import (absolute_import, division, print_function) from __future__ import (absolute_import, division, print_function)
__metaclass__ = type __metaclass__ = type
from ansible_collections.community.general.tests.unit.compat import unittest from ansible_collections.community.internal_test_tools.tests.unit.compat import unittest
from ansible_collections.community.general.plugins.modules import interfaces_file from ansible_collections.community.general.plugins.modules import interfaces_file
from shutil import copyfile, move from shutil import copyfile, move
import difflib import difflib

View file

@ -6,7 +6,7 @@ from __future__ import (absolute_import, division, print_function)
__metaclass__ = type __metaclass__ = type
import sys import sys
from ansible_collections.community.general.tests.unit.compat.mock import Mock from ansible_collections.community.internal_test_tools.tests.unit.compat.mock import Mock
# FIXME: These should be done inside of a fixture so that they're only mocked during # FIXME: These should be done inside of a fixture so that they're only mocked during
# these unittests # these unittests

View file

@ -7,7 +7,7 @@ __metaclass__ = type
import json import json
import pytest import pytest
from ansible_collections.community.general.tests.unit.compat.mock import patch from ansible_collections.community.internal_test_tools.tests.unit.compat.mock import patch
from ansible_collections.community.general.plugins.modules import alerta_customer from ansible_collections.community.general.plugins.modules import alerta_customer
from ansible_collections.community.internal_test_tools.tests.unit.plugins.modules.utils import AnsibleExitJson, AnsibleFailJson, ModuleTestCase, set_module_args from ansible_collections.community.internal_test_tools.tests.unit.plugins.modules.utils import AnsibleExitJson, AnsibleFailJson, ModuleTestCase, set_module_args

View file

@ -5,8 +5,8 @@
from __future__ import (absolute_import, division, print_function) from __future__ import (absolute_import, division, print_function)
__metaclass__ = type __metaclass__ = type
from ansible_collections.community.general.tests.unit.compat import mock from ansible_collections.community.internal_test_tools.tests.unit.compat import mock
from ansible_collections.community.general.tests.unit.compat import unittest from ansible_collections.community.internal_test_tools.tests.unit.compat import unittest
from ansible_collections.community.general.plugins.modules import apk from ansible_collections.community.general.plugins.modules import apk

View file

@ -9,7 +9,7 @@ __metaclass__ = type
import pytest import pytest
from ansible.module_utils.basic import AnsibleModule from ansible.module_utils.basic import AnsibleModule
from ansible_collections.community.general.tests.unit.compat.mock import Mock, patch from ansible_collections.community.internal_test_tools.tests.unit.compat.mock import Mock, patch
from ansible_collections.community.internal_test_tools.tests.unit.plugins.modules.utils import ModuleTestCase, set_module_args from ansible_collections.community.internal_test_tools.tests.unit.plugins.modules.utils import ModuleTestCase, set_module_args
from ansible_collections.community.general.plugins.modules.archive import get_archive, common_path from ansible_collections.community.general.plugins.modules.archive import get_archive, common_path

View file

@ -7,8 +7,8 @@ __metaclass__ = type
from ansible_collections.community.general.plugins.module_utils.source_control.bitbucket import BitbucketHelper from ansible_collections.community.general.plugins.module_utils.source_control.bitbucket import BitbucketHelper
from ansible_collections.community.general.plugins.modules import bitbucket_access_key from ansible_collections.community.general.plugins.modules import bitbucket_access_key
from ansible_collections.community.general.tests.unit.compat import unittest from ansible_collections.community.internal_test_tools.tests.unit.compat import unittest
from ansible_collections.community.general.tests.unit.compat.mock import patch from ansible_collections.community.internal_test_tools.tests.unit.compat.mock import patch
from ansible_collections.community.internal_test_tools.tests.unit.plugins.modules.utils import AnsibleFailJson, AnsibleExitJson, ModuleTestCase, set_module_args from ansible_collections.community.internal_test_tools.tests.unit.plugins.modules.utils import AnsibleFailJson, AnsibleExitJson, ModuleTestCase, set_module_args

View file

@ -7,8 +7,8 @@ __metaclass__ = type
from ansible_collections.community.general.plugins.module_utils.source_control.bitbucket import BitbucketHelper from ansible_collections.community.general.plugins.module_utils.source_control.bitbucket import BitbucketHelper
from ansible_collections.community.general.plugins.modules import bitbucket_pipeline_key_pair from ansible_collections.community.general.plugins.modules import bitbucket_pipeline_key_pair
from ansible_collections.community.general.tests.unit.compat import unittest from ansible_collections.community.internal_test_tools.tests.unit.compat import unittest
from ansible_collections.community.general.tests.unit.compat.mock import patch from ansible_collections.community.internal_test_tools.tests.unit.compat.mock import patch
from ansible_collections.community.internal_test_tools.tests.unit.plugins.modules.utils import AnsibleFailJson, AnsibleExitJson, ModuleTestCase, set_module_args from ansible_collections.community.internal_test_tools.tests.unit.plugins.modules.utils import AnsibleFailJson, AnsibleExitJson, ModuleTestCase, set_module_args

View file

@ -10,8 +10,8 @@ import pytest
from ansible_collections.community.general.plugins.module_utils.source_control.bitbucket import BitbucketHelper from ansible_collections.community.general.plugins.module_utils.source_control.bitbucket import BitbucketHelper
from ansible_collections.community.general.plugins.modules import bitbucket_pipeline_known_host from ansible_collections.community.general.plugins.modules import bitbucket_pipeline_known_host
from ansible_collections.community.general.plugins.modules.bitbucket_pipeline_known_host import HAS_PARAMIKO from ansible_collections.community.general.plugins.modules.bitbucket_pipeline_known_host import HAS_PARAMIKO
from ansible_collections.community.general.tests.unit.compat import unittest from ansible_collections.community.internal_test_tools.tests.unit.compat import unittest
from ansible_collections.community.general.tests.unit.compat.mock import patch from ansible_collections.community.internal_test_tools.tests.unit.compat.mock import patch
from ansible_collections.community.internal_test_tools.tests.unit.plugins.modules.utils import AnsibleExitJson, ModuleTestCase, set_module_args from ansible_collections.community.internal_test_tools.tests.unit.plugins.modules.utils import AnsibleExitJson, ModuleTestCase, set_module_args

View file

@ -7,8 +7,8 @@ __metaclass__ = type
from ansible_collections.community.general.plugins.module_utils.source_control.bitbucket import BitbucketHelper from ansible_collections.community.general.plugins.module_utils.source_control.bitbucket import BitbucketHelper
from ansible_collections.community.general.plugins.modules import bitbucket_pipeline_variable from ansible_collections.community.general.plugins.modules import bitbucket_pipeline_variable
from ansible_collections.community.general.tests.unit.compat import unittest from ansible_collections.community.internal_test_tools.tests.unit.compat import unittest
from ansible_collections.community.general.tests.unit.compat.mock import patch from ansible_collections.community.internal_test_tools.tests.unit.compat.mock import patch
from ansible_collections.community.internal_test_tools.tests.unit.plugins.modules.utils import AnsibleFailJson, AnsibleExitJson, ModuleTestCase, set_module_args from ansible_collections.community.internal_test_tools.tests.unit.plugins.modules.utils import AnsibleFailJson, AnsibleExitJson, ModuleTestCase, set_module_args

View file

@ -5,7 +5,7 @@
from __future__ import (absolute_import, division, print_function) from __future__ import (absolute_import, division, print_function)
__metaclass__ = type __metaclass__ = type
from ansible_collections.community.general.tests.unit.compat.mock import patch from ansible_collections.community.internal_test_tools.tests.unit.compat.mock import patch
from ansible_collections.community.general.plugins.modules import bootc_manage from ansible_collections.community.general.plugins.modules import bootc_manage
from ansible_collections.community.internal_test_tools.tests.unit.plugins.modules.utils import AnsibleExitJson, AnsibleFailJson, ModuleTestCase, set_module_args from ansible_collections.community.internal_test_tools.tests.unit.plugins.modules.utils import AnsibleExitJson, AnsibleFailJson, ModuleTestCase, set_module_args

View file

@ -6,7 +6,7 @@ from __future__ import (absolute_import, division, print_function)
__metaclass__ = type __metaclass__ = type
import pytest import pytest
from ansible_collections.community.general.tests.unit.compat.mock import patch from ansible_collections.community.internal_test_tools.tests.unit.compat.mock import patch
from ansible_collections.community.general.plugins.modules import campfire from ansible_collections.community.general.plugins.modules import campfire
from ansible_collections.community.internal_test_tools.tests.unit.plugins.modules.utils import AnsibleExitJson, AnsibleFailJson, ModuleTestCase, set_module_args from ansible_collections.community.internal_test_tools.tests.unit.plugins.modules.utils import AnsibleExitJson, AnsibleFailJson, ModuleTestCase, set_module_args

View file

@ -12,7 +12,7 @@ import re
import uuid import uuid
from urllib3.response import HTTPResponse from urllib3.response import HTTPResponse
from ansible_collections.community.general.tests.unit.compat.mock import patch from ansible_collections.community.internal_test_tools.tests.unit.compat.mock import patch
from ansible.module_utils.common.text.converters import to_bytes from ansible.module_utils.common.text.converters import to_bytes
from ansible_collections.community.general.plugins.modules import circonus_annotation from ansible_collections.community.general.plugins.modules import circonus_annotation
from ansible_collections.community.internal_test_tools.tests.unit.plugins.modules.utils import AnsibleExitJson, AnsibleFailJson, ModuleTestCase, set_module_args from ansible_collections.community.internal_test_tools.tests.unit.plugins.modules.utils import AnsibleExitJson, AnsibleFailJson, ModuleTestCase, set_module_args

View file

@ -8,7 +8,7 @@ from __future__ import (absolute_import, division, print_function)
__metaclass__ = type __metaclass__ = type
from ansible_collections.community.general.plugins.modules import datadog_downtime from ansible_collections.community.general.plugins.modules import datadog_downtime
from ansible_collections.community.general.tests.unit.compat.mock import MagicMock, patch from ansible_collections.community.internal_test_tools.tests.unit.compat.mock import MagicMock, patch
from ansible_collections.community.internal_test_tools.tests.unit.plugins.modules.utils import ( from ansible_collections.community.internal_test_tools.tests.unit.plugins.modules.utils import (
AnsibleExitJson, AnsibleFailJson, ModuleTestCase, set_module_args AnsibleExitJson, AnsibleFailJson, ModuleTestCase, set_module_args
) )

View file

@ -7,7 +7,7 @@ __metaclass__ = type
import json import json
import pytest import pytest
from ansible_collections.community.general.tests.unit.compat.mock import patch from ansible_collections.community.internal_test_tools.tests.unit.compat.mock import patch
from ansible_collections.community.general.plugins.modules import discord from ansible_collections.community.general.plugins.modules import discord
from ansible_collections.community.internal_test_tools.tests.unit.plugins.modules.utils import AnsibleExitJson, AnsibleFailJson, ModuleTestCase, set_module_args from ansible_collections.community.internal_test_tools.tests.unit.plugins.modules.utils import AnsibleExitJson, AnsibleFailJson, ModuleTestCase, set_module_args

View file

@ -7,7 +7,7 @@ from __future__ import (absolute_import, division, print_function)
__metaclass__ = type __metaclass__ = type
from ansible_collections.community.general.tests.unit.compat.mock import patch, call from ansible_collections.community.internal_test_tools.tests.unit.compat.mock import patch, call
from ansible_collections.community.general.plugins.modules import dnf_config_manager as dnf_config_manager_module from ansible_collections.community.general.plugins.modules import dnf_config_manager as dnf_config_manager_module
from ansible_collections.community.internal_test_tools.tests.unit.plugins.modules.utils import AnsibleExitJson, AnsibleFailJson, \ from ansible_collections.community.internal_test_tools.tests.unit.plugins.modules.utils import AnsibleExitJson, AnsibleFailJson, \
ModuleTestCase, set_module_args ModuleTestCase, set_module_args

View file

@ -10,7 +10,7 @@ __metaclass__ = type
from ansible_collections.community.general.plugins.modules import dnsimple as dnsimple_module from ansible_collections.community.general.plugins.modules import dnsimple as dnsimple_module
from ansible_collections.community.internal_test_tools.tests.unit.plugins.modules.utils import AnsibleFailJson, ModuleTestCase, set_module_args from ansible_collections.community.internal_test_tools.tests.unit.plugins.modules.utils import AnsibleFailJson, ModuleTestCase, set_module_args
from ansible_collections.community.general.tests.unit.compat.mock import patch from ansible_collections.community.internal_test_tools.tests.unit.compat.mock import patch
import pytest import pytest
import sys import sys

View file

@ -9,7 +9,7 @@ import re
import json import json
import sys import sys
from httmock import with_httmock, urlmatch, response from httmock import with_httmock, urlmatch, response
from ansible_collections.community.general.tests.unit.compat import unittest from ansible_collections.community.internal_test_tools.tests.unit.compat import unittest
from ansible_collections.community.general.plugins.modules import github_repo from ansible_collections.community.general.plugins.modules import github_repo
GITHUB_MINIMUM_PYTHON_VERSION = (2, 7) GITHUB_MINIMUM_PYTHON_VERSION = (2, 7)

View file

@ -6,7 +6,7 @@ from __future__ import absolute_import, division, print_function
__metaclass__ = type __metaclass__ = type
from ansible_collections.community.general.tests.unit.compat import unittest from ansible_collections.community.internal_test_tools.tests.unit.compat import unittest
from ansible_collections.community.general.plugins.module_utils.homebrew import HomebrewValidate from ansible_collections.community.general.plugins.module_utils.homebrew import HomebrewValidate

View file

@ -11,7 +11,7 @@ __metaclass__ = type
from ansible_collections.community.general.plugins.modules import icinga2_feature from ansible_collections.community.general.plugins.modules import icinga2_feature
from ansible_collections.community.internal_test_tools.tests.unit.plugins.modules.utils import AnsibleExitJson, AnsibleFailJson, ModuleTestCase, set_module_args from ansible_collections.community.internal_test_tools.tests.unit.plugins.modules.utils import AnsibleExitJson, AnsibleFailJson, ModuleTestCase, set_module_args
from ansible_collections.community.general.tests.unit.compat.mock import patch from ansible_collections.community.internal_test_tools.tests.unit.compat.mock import patch
from ansible.module_utils import basic from ansible.module_utils import basic

View file

@ -6,7 +6,7 @@
from __future__ import (absolute_import, division, print_function) from __future__ import (absolute_import, division, print_function)
__metaclass__ = type __metaclass__ = type
from ansible_collections.community.general.tests.unit.compat.mock import call, patch from ansible_collections.community.internal_test_tools.tests.unit.compat.mock import call, patch
from ansible_collections.community.general.plugins.modules import ipa_getkeytab from ansible_collections.community.general.plugins.modules import ipa_getkeytab
from ansible_collections.community.internal_test_tools.tests.unit.plugins.modules.utils import AnsibleExitJson, ModuleTestCase, set_module_args from ansible_collections.community.internal_test_tools.tests.unit.plugins.modules.utils import AnsibleExitJson, ModuleTestCase, set_module_args

View file

@ -9,8 +9,8 @@ __metaclass__ = type
from contextlib import contextmanager from contextlib import contextmanager
from ansible_collections.community.general.tests.unit.compat import unittest from ansible_collections.community.internal_test_tools.tests.unit.compat import unittest
from ansible_collections.community.general.tests.unit.compat.mock import call, patch from ansible_collections.community.internal_test_tools.tests.unit.compat.mock import call, patch
from ansible_collections.community.internal_test_tools.tests.unit.plugins.modules.utils import AnsibleExitJson, AnsibleFailJson, ModuleTestCase, set_module_args from ansible_collections.community.internal_test_tools.tests.unit.plugins.modules.utils import AnsibleExitJson, AnsibleFailJson, ModuleTestCase, set_module_args
from ansible_collections.community.general.plugins.modules import ipa_otpconfig from ansible_collections.community.general.plugins.modules import ipa_otpconfig

View file

@ -9,8 +9,8 @@ __metaclass__ = type
from contextlib import contextmanager from contextlib import contextmanager
from ansible_collections.community.general.tests.unit.compat import unittest from ansible_collections.community.internal_test_tools.tests.unit.compat import unittest
from ansible_collections.community.general.tests.unit.compat.mock import call, patch from ansible_collections.community.internal_test_tools.tests.unit.compat.mock import call, patch
from ansible_collections.community.internal_test_tools.tests.unit.plugins.modules.utils import AnsibleExitJson, AnsibleFailJson, ModuleTestCase, set_module_args from ansible_collections.community.internal_test_tools.tests.unit.plugins.modules.utils import AnsibleExitJson, AnsibleFailJson, ModuleTestCase, set_module_args
from ansible_collections.community.general.plugins.modules import ipa_otptoken from ansible_collections.community.general.plugins.modules import ipa_otptoken

View file

@ -9,8 +9,8 @@ __metaclass__ = type
from contextlib import contextmanager from contextlib import contextmanager
from ansible_collections.community.general.tests.unit.compat import unittest from ansible_collections.community.internal_test_tools.tests.unit.compat import unittest
from ansible_collections.community.general.tests.unit.compat.mock import call, patch from ansible_collections.community.internal_test_tools.tests.unit.compat.mock import call, patch
from ansible_collections.community.internal_test_tools.tests.unit.plugins.modules.utils import AnsibleExitJson, AnsibleFailJson, ModuleTestCase, set_module_args from ansible_collections.community.internal_test_tools.tests.unit.plugins.modules.utils import AnsibleExitJson, AnsibleFailJson, ModuleTestCase, set_module_args
from ansible_collections.community.general.plugins.modules import ipa_pwpolicy from ansible_collections.community.general.plugins.modules import ipa_pwpolicy

View file

@ -9,8 +9,8 @@ __metaclass__ = type
import json import json
from ansible_collections.community.general.plugins.modules.ipbase_info import IpbaseInfo from ansible_collections.community.general.plugins.modules.ipbase_info import IpbaseInfo
from ansible_collections.community.general.tests.unit.compat import unittest from ansible_collections.community.internal_test_tools.tests.unit.compat import unittest
from ansible_collections.community.general.tests.unit.compat.mock import Mock from ansible_collections.community.internal_test_tools.tests.unit.compat.mock import Mock
IPBASE_DATA = { IPBASE_DATA = {

View file

@ -12,8 +12,8 @@ __metaclass__ = type
import os import os
from ansible_collections.community.internal_test_tools.tests.unit.plugins.modules.utils import ModuleTestCase, set_module_args from ansible_collections.community.internal_test_tools.tests.unit.plugins.modules.utils import ModuleTestCase, set_module_args
from ansible_collections.community.general.tests.unit.compat.mock import patch from ansible_collections.community.internal_test_tools.tests.unit.compat.mock import patch
from ansible_collections.community.general.tests.unit.compat.mock import Mock from ansible_collections.community.internal_test_tools.tests.unit.compat.mock import Mock
from ansible.module_utils.basic import AnsibleModule from ansible.module_utils.basic import AnsibleModule
from ansible_collections.community.general.plugins.modules.java_keystore import JavaKeystore from ansible_collections.community.general.plugins.modules.java_keystore import JavaKeystore

View file

@ -5,8 +5,8 @@
from __future__ import (absolute_import, division, print_function) from __future__ import (absolute_import, division, print_function)
__metaclass__ = type __metaclass__ = type
from ansible_collections.community.general.tests.unit.compat import unittest from ansible_collections.community.internal_test_tools.tests.unit.compat import unittest
from ansible_collections.community.general.tests.unit.compat.mock import patch from ansible_collections.community.internal_test_tools.tests.unit.compat.mock import patch
from ansible.module_utils import basic from ansible.module_utils import basic
from ansible_collections.community.general.plugins.modules import jenkins_build from ansible_collections.community.general.plugins.modules import jenkins_build
from ansible_collections.community.internal_test_tools.tests.unit.plugins.modules.utils import ( from ansible_collections.community.internal_test_tools.tests.unit.plugins.modules.utils import (

View file

@ -5,8 +5,8 @@
from __future__ import (absolute_import, division, print_function) from __future__ import (absolute_import, division, print_function)
__metaclass__ = type __metaclass__ = type
from ansible_collections.community.general.tests.unit.compat import unittest from ansible_collections.community.internal_test_tools.tests.unit.compat import unittest
from ansible_collections.community.general.tests.unit.compat.mock import patch from ansible_collections.community.internal_test_tools.tests.unit.compat.mock import patch
from ansible.module_utils import basic from ansible.module_utils import basic
from ansible_collections.community.general.plugins.modules import jenkins_build_info from ansible_collections.community.general.plugins.modules import jenkins_build_info
from ansible_collections.community.internal_test_tools.tests.unit.plugins.modules.utils import ( from ansible_collections.community.internal_test_tools.tests.unit.plugins.modules.utils import (

View file

@ -9,8 +9,8 @@ __metaclass__ = type
from contextlib import contextmanager from contextlib import contextmanager
from ansible_collections.community.general.tests.unit.compat import unittest from ansible_collections.community.internal_test_tools.tests.unit.compat import unittest
from ansible_collections.community.general.tests.unit.compat.mock import patch from ansible_collections.community.internal_test_tools.tests.unit.compat.mock import patch
from ansible_collections.community.internal_test_tools.tests.unit.plugins.modules.utils import AnsibleExitJson, ModuleTestCase, set_module_args from ansible_collections.community.internal_test_tools.tests.unit.plugins.modules.utils import AnsibleExitJson, ModuleTestCase, set_module_args
from ansible_collections.community.general.plugins.modules import keycloak_authentication from ansible_collections.community.general.plugins.modules import keycloak_authentication

View file

@ -9,8 +9,8 @@ __metaclass__ = type
from contextlib import contextmanager from contextlib import contextmanager
from ansible_collections.community.general.tests.unit.compat import unittest from ansible_collections.community.internal_test_tools.tests.unit.compat import unittest
from ansible_collections.community.general.tests.unit.compat.mock import patch from ansible_collections.community.internal_test_tools.tests.unit.compat.mock import patch
from ansible_collections.community.internal_test_tools.tests.unit.plugins.modules.utils import AnsibleExitJson, ModuleTestCase, set_module_args from ansible_collections.community.internal_test_tools.tests.unit.plugins.modules.utils import AnsibleExitJson, ModuleTestCase, set_module_args
from ansible_collections.community.general.plugins.modules import keycloak_authentication_required_actions from ansible_collections.community.general.plugins.modules import keycloak_authentication_required_actions

View file

@ -10,8 +10,8 @@ __metaclass__ = type
from contextlib import contextmanager from contextlib import contextmanager
from ansible_collections.community.general.tests.unit.compat import unittest from ansible_collections.community.internal_test_tools.tests.unit.compat import unittest
from ansible_collections.community.general.tests.unit.compat.mock import patch from ansible_collections.community.internal_test_tools.tests.unit.compat.mock import patch
from ansible_collections.community.internal_test_tools.tests.unit.plugins.modules.utils import AnsibleExitJson, ModuleTestCase, set_module_args from ansible_collections.community.internal_test_tools.tests.unit.plugins.modules.utils import AnsibleExitJson, ModuleTestCase, set_module_args
from ansible_collections.community.general.plugins.modules import keycloak_client from ansible_collections.community.general.plugins.modules import keycloak_client

View file

@ -9,8 +9,8 @@ __metaclass__ = type
from contextlib import contextmanager from contextlib import contextmanager
from ansible_collections.community.general.tests.unit.compat import unittest from ansible_collections.community.internal_test_tools.tests.unit.compat import unittest
from ansible_collections.community.general.tests.unit.compat.mock import patch from ansible_collections.community.internal_test_tools.tests.unit.compat.mock import patch
from ansible_collections.community.internal_test_tools.tests.unit.plugins.modules.utils import AnsibleExitJson, ModuleTestCase, set_module_args from ansible_collections.community.internal_test_tools.tests.unit.plugins.modules.utils import AnsibleExitJson, ModuleTestCase, set_module_args
from ansible_collections.community.general.plugins.modules import keycloak_client_rolemapping from ansible_collections.community.general.plugins.modules import keycloak_client_rolemapping

View file

@ -10,8 +10,8 @@ __metaclass__ = type
from contextlib import contextmanager from contextlib import contextmanager
from ansible_collections.community.general.tests.unit.compat import unittest from ansible_collections.community.internal_test_tools.tests.unit.compat import unittest
from ansible_collections.community.general.tests.unit.compat.mock import patch from ansible_collections.community.internal_test_tools.tests.unit.compat.mock import patch
from ansible_collections.community.internal_test_tools.tests.unit.plugins.modules.utils import AnsibleExitJson, ModuleTestCase, set_module_args from ansible_collections.community.internal_test_tools.tests.unit.plugins.modules.utils import AnsibleExitJson, ModuleTestCase, set_module_args
from ansible_collections.community.general.plugins.modules import keycloak_clientscope from ansible_collections.community.general.plugins.modules import keycloak_clientscope

View file

@ -9,8 +9,8 @@ __metaclass__ = type
from contextlib import contextmanager from contextlib import contextmanager
from ansible_collections.community.general.tests.unit.compat import unittest from ansible_collections.community.internal_test_tools.tests.unit.compat import unittest
from ansible_collections.community.general.tests.unit.compat.mock import patch from ansible_collections.community.internal_test_tools.tests.unit.compat.mock import patch
from ansible_collections.community.internal_test_tools.tests.unit.plugins.modules.utils import AnsibleExitJson, ModuleTestCase, set_module_args from ansible_collections.community.internal_test_tools.tests.unit.plugins.modules.utils import AnsibleExitJson, ModuleTestCase, set_module_args
from ansible_collections.community.general.plugins.modules import keycloak_identity_provider from ansible_collections.community.general.plugins.modules import keycloak_identity_provider

View file

@ -9,8 +9,8 @@ __metaclass__ = type
from contextlib import contextmanager from contextlib import contextmanager
from ansible_collections.community.general.tests.unit.compat import unittest from ansible_collections.community.internal_test_tools.tests.unit.compat import unittest
from ansible_collections.community.general.tests.unit.compat.mock import patch from ansible_collections.community.internal_test_tools.tests.unit.compat.mock import patch
from ansible_collections.community.internal_test_tools.tests.unit.plugins.modules.utils import AnsibleExitJson, ModuleTestCase, set_module_args from ansible_collections.community.internal_test_tools.tests.unit.plugins.modules.utils import AnsibleExitJson, ModuleTestCase, set_module_args
from ansible_collections.community.general.plugins.modules import keycloak_realm from ansible_collections.community.general.plugins.modules import keycloak_realm

View file

@ -9,8 +9,8 @@ __metaclass__ = type
from contextlib import contextmanager from contextlib import contextmanager
from ansible_collections.community.general.tests.unit.compat import unittest from ansible_collections.community.internal_test_tools.tests.unit.compat import unittest
from ansible_collections.community.general.tests.unit.compat.mock import patch from ansible_collections.community.internal_test_tools.tests.unit.compat.mock import patch
from ansible_collections.community.internal_test_tools.tests.unit.plugins.modules.utils import AnsibleExitJson, ModuleTestCase, set_module_args from ansible_collections.community.internal_test_tools.tests.unit.plugins.modules.utils import AnsibleExitJson, ModuleTestCase, set_module_args
from ansible_collections.community.general.plugins.modules import keycloak_realm_info from ansible_collections.community.general.plugins.modules import keycloak_realm_info

View file

@ -9,8 +9,8 @@ __metaclass__ = type
from contextlib import contextmanager from contextlib import contextmanager
from ansible_collections.community.general.tests.unit.compat import unittest from ansible_collections.community.internal_test_tools.tests.unit.compat import unittest
from ansible_collections.community.general.tests.unit.compat.mock import patch from ansible_collections.community.internal_test_tools.tests.unit.compat.mock import patch
from ansible_collections.community.internal_test_tools.tests.unit.plugins.modules.utils import AnsibleExitJson, ModuleTestCase, set_module_args from ansible_collections.community.internal_test_tools.tests.unit.plugins.modules.utils import AnsibleExitJson, ModuleTestCase, set_module_args
from ansible_collections.community.general.plugins.modules import keycloak_realm_key from ansible_collections.community.general.plugins.modules import keycloak_realm_key

View file

@ -14,8 +14,8 @@ from itertools import count
from ansible.module_utils.six import StringIO from ansible.module_utils.six import StringIO
from ansible_collections.community.general.plugins.modules import \ from ansible_collections.community.general.plugins.modules import \
keycloak_realm_keys_metadata_info keycloak_realm_keys_metadata_info
from ansible_collections.community.general.tests.unit.compat import unittest from ansible_collections.community.internal_test_tools.tests.unit.compat import unittest
from ansible_collections.community.general.tests.unit.compat.mock import patch from ansible_collections.community.internal_test_tools.tests.unit.compat.mock import patch
from ansible_collections.community.internal_test_tools.tests.unit.plugins.modules.utils import ( from ansible_collections.community.internal_test_tools.tests.unit.plugins.modules.utils import (
AnsibleExitJson, ModuleTestCase, set_module_args) AnsibleExitJson, ModuleTestCase, set_module_args)

View file

@ -9,8 +9,8 @@ __metaclass__ = type
from contextlib import contextmanager from contextlib import contextmanager
from ansible_collections.community.general.tests.unit.compat import unittest from ansible_collections.community.internal_test_tools.tests.unit.compat import unittest
from ansible_collections.community.general.tests.unit.compat.mock import patch from ansible_collections.community.internal_test_tools.tests.unit.compat.mock import patch
from ansible_collections.community.internal_test_tools.tests.unit.plugins.modules.utils import AnsibleExitJson, ModuleTestCase, set_module_args from ansible_collections.community.internal_test_tools.tests.unit.plugins.modules.utils import AnsibleExitJson, ModuleTestCase, set_module_args
from ansible_collections.community.general.plugins.modules import keycloak_role from ansible_collections.community.general.plugins.modules import keycloak_role

View file

@ -10,8 +10,8 @@ __metaclass__ = type
from contextlib import contextmanager from contextlib import contextmanager
from ansible_collections.community.general.tests.unit.compat import unittest from ansible_collections.community.internal_test_tools.tests.unit.compat import unittest
from ansible_collections.community.general.tests.unit.compat.mock import patch from ansible_collections.community.internal_test_tools.tests.unit.compat.mock import patch
from ansible_collections.community.internal_test_tools.tests.unit.plugins.modules.utils import AnsibleExitJson, ModuleTestCase, set_module_args from ansible_collections.community.internal_test_tools.tests.unit.plugins.modules.utils import AnsibleExitJson, ModuleTestCase, set_module_args
from ansible_collections.community.general.plugins.modules import keycloak_user from ansible_collections.community.general.plugins.modules import keycloak_user

View file

@ -9,8 +9,8 @@ __metaclass__ = type
from contextlib import contextmanager from contextlib import contextmanager
from ansible_collections.community.general.tests.unit.compat import unittest from ansible_collections.community.internal_test_tools.tests.unit.compat import unittest
from ansible_collections.community.general.tests.unit.compat.mock import patch from ansible_collections.community.internal_test_tools.tests.unit.compat.mock import patch
from ansible_collections.community.internal_test_tools.tests.unit.plugins.modules.utils import AnsibleExitJson, ModuleTestCase, set_module_args from ansible_collections.community.internal_test_tools.tests.unit.plugins.modules.utils import AnsibleExitJson, ModuleTestCase, set_module_args
from ansible_collections.community.general.plugins.modules import keycloak_user_federation from ansible_collections.community.general.plugins.modules import keycloak_user_federation

View file

@ -9,8 +9,8 @@ __metaclass__ = type
from contextlib import contextmanager from contextlib import contextmanager
from ansible_collections.community.general.tests.unit.compat import unittest from ansible_collections.community.internal_test_tools.tests.unit.compat import unittest
from ansible_collections.community.general.tests.unit.compat.mock import patch from ansible_collections.community.internal_test_tools.tests.unit.compat.mock import patch
from ansible_collections.community.internal_test_tools.tests.unit.plugins.modules.utils import AnsibleExitJson, ModuleTestCase, set_module_args from ansible_collections.community.internal_test_tools.tests.unit.plugins.modules.utils import AnsibleExitJson, ModuleTestCase, set_module_args
from ansible_collections.community.general.plugins.modules import keycloak_userprofile from ansible_collections.community.general.plugins.modules import keycloak_userprofile

View file

@ -23,7 +23,7 @@ from linode_api4 import LinodeClient
from ansible_collections.community.general.plugins.modules import linode_v4 from ansible_collections.community.general.plugins.modules import linode_v4
from ansible_collections.community.general.plugins.module_utils.linode import get_user_agent from ansible_collections.community.general.plugins.module_utils.linode import get_user_agent
from ansible_collections.community.internal_test_tools.tests.unit.plugins.modules.utils import set_module_args from ansible_collections.community.internal_test_tools.tests.unit.plugins.modules.utils import set_module_args
from ansible_collections.community.general.tests.unit.compat import mock from ansible_collections.community.internal_test_tools.tests.unit.compat import mock
from .linode_conftest import access_token, no_access_token_in_env, default_args, mock_linode # noqa: F401, pylint: disable=unused-import from .linode_conftest import access_token, no_access_token_in_env, default_args, mock_linode # noqa: F401, pylint: disable=unused-import

View file

@ -7,7 +7,7 @@ from __future__ import absolute_import, division, print_function
__metaclass__ = type __metaclass__ = type
from ansible_collections.community.general.plugins.modules import lvg_rename from ansible_collections.community.general.plugins.modules import lvg_rename
from ansible_collections.community.general.tests.unit.compat.mock import patch from ansible_collections.community.internal_test_tools.tests.unit.compat.mock import patch
from ansible_collections.community.internal_test_tools.tests.unit.plugins.modules.utils import ( from ansible_collections.community.internal_test_tools.tests.unit.plugins.modules.utils import (
AnsibleFailJson, AnsibleExitJson, ModuleTestCase, set_module_args) AnsibleFailJson, AnsibleExitJson, ModuleTestCase, set_module_args)

View file

@ -8,7 +8,7 @@ __metaclass__ = type
import json import json
import pytest import pytest
from ansible_collections.community.general.tests.unit.compat import mock from ansible_collections.community.internal_test_tools.tests.unit.compat import mock
from ansible_collections.community.general.plugins.modules import lxca_cmms from ansible_collections.community.general.plugins.modules import lxca_cmms

View file

@ -8,7 +8,7 @@ __metaclass__ = type
import json import json
import pytest import pytest
from ansible_collections.community.general.tests.unit.compat import mock from ansible_collections.community.internal_test_tools.tests.unit.compat import mock
from ansible_collections.community.general.plugins.modules import lxca_nodes from ansible_collections.community.general.plugins.modules import lxca_nodes

View file

@ -8,9 +8,9 @@ __metaclass__ = type
import sys import sys
from ansible_collections.community.internal_test_tools.tests.unit.plugins.modules.utils import ModuleTestCase, set_module_args from ansible_collections.community.internal_test_tools.tests.unit.plugins.modules.utils import ModuleTestCase, set_module_args
from ansible_collections.community.general.tests.unit.compat.mock import patch from ansible_collections.community.internal_test_tools.tests.unit.compat.mock import patch
from ansible_collections.community.general.tests.unit.compat.mock import Mock from ansible_collections.community.internal_test_tools.tests.unit.compat.mock import Mock
from ansible_collections.community.general.tests.unit.compat.mock import mock_open from ansible_collections.community.internal_test_tools.tests.unit.compat.mock import mock_open
from ansible_collections.community.general.plugins.modules.modprobe import Modprobe, build_module from ansible_collections.community.general.plugins.modules.modprobe import Modprobe, build_module

View file

@ -8,7 +8,7 @@ __metaclass__ = type
import mock import mock
import pytest import pytest
from ansible_collections.community.general.tests.unit.compat import unittest from ansible_collections.community.internal_test_tools.tests.unit.compat import unittest
from ansible_collections.community.general.plugins.modules import monit from ansible_collections.community.general.plugins.modules import monit
from ansible_collections.community.internal_test_tools.tests.unit.plugins.modules.utils import AnsibleExitJson, AnsibleFailJson from ansible_collections.community.internal_test_tools.tests.unit.plugins.modules.utils import AnsibleExitJson, AnsibleFailJson

View file

@ -10,7 +10,7 @@ __metaclass__ = type
import nomad import nomad
from ansible_collections.community.general.plugins.modules import nomad_token from ansible_collections.community.general.plugins.modules import nomad_token
from ansible_collections.community.general.tests.unit.compat.mock import patch from ansible_collections.community.internal_test_tools.tests.unit.compat.mock import patch
from ansible_collections.community.internal_test_tools.tests.unit.plugins.modules.utils import AnsibleExitJson, AnsibleFailJson, ModuleTestCase, set_module_args from ansible_collections.community.internal_test_tools.tests.unit.plugins.modules.utils import AnsibleExitJson, AnsibleFailJson, ModuleTestCase, set_module_args

View file

@ -6,7 +6,7 @@
from __future__ import (absolute_import, division, print_function) from __future__ import (absolute_import, division, print_function)
__metaclass__ = type __metaclass__ = type
from ansible_collections.community.general.tests.unit.compat.mock import call, patch from ansible_collections.community.internal_test_tools.tests.unit.compat.mock import call, patch
from ansible_collections.community.general.plugins.modules import npm from ansible_collections.community.general.plugins.modules import npm
from ansible_collections.community.internal_test_tools.tests.unit.plugins.modules.utils import AnsibleExitJson, ModuleTestCase, set_module_args from ansible_collections.community.internal_test_tools.tests.unit.plugins.modules.utils import AnsibleExitJson, ModuleTestCase, set_module_args

View file

@ -10,8 +10,8 @@ import os
import shutil import shutil
import tempfile import tempfile
from ansible_collections.community.general.tests.unit.compat.mock import patch from ansible_collections.community.internal_test_tools.tests.unit.compat.mock import patch
from ansible_collections.community.general.tests.unit.compat import unittest from ansible_collections.community.internal_test_tools.tests.unit.compat import unittest
from ansible.module_utils import basic from ansible.module_utils import basic
import ansible_collections.community.general.plugins.modules.ocapi_command as module import ansible_collections.community.general.plugins.modules.ocapi_command as module
from ansible_collections.community.internal_test_tools.tests.unit.plugins.modules.utils import AnsibleExitJson, AnsibleFailJson from ansible_collections.community.internal_test_tools.tests.unit.plugins.modules.utils import AnsibleExitJson, AnsibleFailJson

View file

@ -6,8 +6,8 @@
from __future__ import (absolute_import, division, print_function) from __future__ import (absolute_import, division, print_function)
__metaclass__ = type __metaclass__ = type
from ansible_collections.community.general.tests.unit.compat.mock import patch from ansible_collections.community.internal_test_tools.tests.unit.compat.mock import patch
from ansible_collections.community.general.tests.unit.compat import unittest from ansible_collections.community.internal_test_tools.tests.unit.compat import unittest
from ansible.module_utils import basic from ansible.module_utils import basic
import ansible_collections.community.general.plugins.modules.ocapi_info as module import ansible_collections.community.general.plugins.modules.ocapi_info as module
from ansible_collections.community.internal_test_tools.tests.unit.plugins.modules.utils import AnsibleExitJson, AnsibleFailJson from ansible_collections.community.internal_test_tools.tests.unit.plugins.modules.utils import AnsibleExitJson, AnsibleFailJson

View file

@ -7,7 +7,7 @@ __metaclass__ = type
from .hpe_test_utils import FactsParamsTestCase from .hpe_test_utils import FactsParamsTestCase
from ansible_collections.community.general.tests.unit.compat import unittest from ansible_collections.community.internal_test_tools.tests.unit.compat import unittest
from ansible_collections.community.general.plugins.modules.oneview_enclosure_info import EnclosureInfoModule from ansible_collections.community.general.plugins.modules.oneview_enclosure_info import EnclosureInfoModule

View file

@ -9,7 +9,7 @@ __metaclass__ = type
import yaml import yaml
from ansible_collections.community.general.tests.unit.compat import unittest, mock from ansible_collections.community.internal_test_tools.tests.unit.compat import unittest, mock
from .oneview_module_loader import EthernetNetworkModule from .oneview_module_loader import EthernetNetworkModule
from .hpe_test_utils import OneViewBaseTestCase from .hpe_test_utils import OneViewBaseTestCase

View file

@ -5,7 +5,7 @@
from __future__ import (absolute_import, division, print_function) from __future__ import (absolute_import, division, print_function)
__metaclass__ = type __metaclass__ = type
from ansible_collections.community.general.tests.unit.compat import unittest from ansible_collections.community.internal_test_tools.tests.unit.compat import unittest
from .oneview_module_loader import EthernetNetworkInfoModule from .oneview_module_loader import EthernetNetworkInfoModule
from .hpe_test_utils import FactsParamsTestCase from .hpe_test_utils import FactsParamsTestCase

View file

@ -7,7 +7,7 @@
from __future__ import (absolute_import, division, print_function) from __future__ import (absolute_import, division, print_function)
__metaclass__ = type __metaclass__ = type
from ansible_collections.community.general.tests.unit.compat import unittest from ansible_collections.community.internal_test_tools.tests.unit.compat import unittest
from .oneview_module_loader import FcNetworkModule from .oneview_module_loader import FcNetworkModule
from .hpe_test_utils import OneViewBaseTestCase from .hpe_test_utils import OneViewBaseTestCase

View file

@ -5,7 +5,7 @@
from __future__ import (absolute_import, division, print_function) from __future__ import (absolute_import, division, print_function)
__metaclass__ = type __metaclass__ = type
from ansible_collections.community.general.tests.unit.compat import unittest from ansible_collections.community.internal_test_tools.tests.unit.compat import unittest
from .oneview_module_loader import FcNetworkInfoModule from .oneview_module_loader import FcNetworkInfoModule
from .hpe_test_utils import FactsParamsTestCase from .hpe_test_utils import FactsParamsTestCase

View file

@ -7,7 +7,7 @@
from __future__ import (absolute_import, division, print_function) from __future__ import (absolute_import, division, print_function)
__metaclass__ = type __metaclass__ = type
from ansible_collections.community.general.tests.unit.compat import unittest from ansible_collections.community.internal_test_tools.tests.unit.compat import unittest
from .oneview_module_loader import FcoeNetworkModule from .oneview_module_loader import FcoeNetworkModule
from .hpe_test_utils import OneViewBaseTestCase from .hpe_test_utils import OneViewBaseTestCase

View file

@ -5,7 +5,7 @@
from __future__ import (absolute_import, division, print_function) from __future__ import (absolute_import, division, print_function)
__metaclass__ = type __metaclass__ = type
from ansible_collections.community.general.tests.unit.compat import unittest from ansible_collections.community.internal_test_tools.tests.unit.compat import unittest
from .oneview_module_loader import FcoeNetworkInfoModule from .oneview_module_loader import FcoeNetworkInfoModule
from .hpe_test_utils import FactsParamsTestCase from .hpe_test_utils import FactsParamsTestCase

View file

@ -7,7 +7,7 @@ __metaclass__ = type
from copy import deepcopy from copy import deepcopy
from ansible_collections.community.general.tests.unit.compat import unittest, mock from ansible_collections.community.internal_test_tools.tests.unit.compat import unittest, mock
from .hpe_test_utils import OneViewBaseTestCase from .hpe_test_utils import OneViewBaseTestCase
from ansible_collections.community.general.plugins.modules.oneview_logical_interconnect_group import LogicalInterconnectGroupModule from ansible_collections.community.general.plugins.modules.oneview_logical_interconnect_group import LogicalInterconnectGroupModule

View file

@ -5,7 +5,7 @@
from __future__ import (absolute_import, division, print_function) from __future__ import (absolute_import, division, print_function)
__metaclass__ = type __metaclass__ = type
from ansible_collections.community.general.tests.unit.compat import unittest from ansible_collections.community.internal_test_tools.tests.unit.compat import unittest
from .hpe_test_utils import FactsParamsTestCase from .hpe_test_utils import FactsParamsTestCase
from ansible_collections.community.general.plugins.modules.oneview_logical_interconnect_group_info import ( from ansible_collections.community.general.plugins.modules.oneview_logical_interconnect_group_info import (
LogicalInterconnectGroupInfoModule LogicalInterconnectGroupInfoModule

View file

@ -5,7 +5,7 @@
from __future__ import (absolute_import, division, print_function) from __future__ import (absolute_import, division, print_function)
__metaclass__ = type __metaclass__ = type
from ansible_collections.community.general.tests.unit.compat import unittest, mock from ansible_collections.community.internal_test_tools.tests.unit.compat import unittest, mock
from .hpe_test_utils import OneViewBaseTestCase from .hpe_test_utils import OneViewBaseTestCase
from .oneview_module_loader import NetworkSetModule from .oneview_module_loader import NetworkSetModule

View file

@ -5,7 +5,7 @@
from __future__ import (absolute_import, division, print_function) from __future__ import (absolute_import, division, print_function)
__metaclass__ = type __metaclass__ = type
from ansible_collections.community.general.tests.unit.compat import unittest from ansible_collections.community.internal_test_tools.tests.unit.compat import unittest
from .oneview_module_loader import NetworkSetInfoModule from .oneview_module_loader import NetworkSetInfoModule
from .hpe_test_utils import FactsParamsTestCase from .hpe_test_utils import FactsParamsTestCase

View file

@ -5,7 +5,7 @@
from __future__ import (absolute_import, division, print_function) from __future__ import (absolute_import, division, print_function)
__metaclass__ = type __metaclass__ = type
from ansible_collections.community.general.tests.unit.compat import unittest, mock from ansible_collections.community.internal_test_tools.tests.unit.compat import unittest, mock
from .oneview_module_loader import SanManagerModule from .oneview_module_loader import SanManagerModule
from .hpe_test_utils import OneViewBaseTestCase from .hpe_test_utils import OneViewBaseTestCase
from copy import deepcopy from copy import deepcopy

View file

@ -5,7 +5,7 @@
from __future__ import (absolute_import, division, print_function) from __future__ import (absolute_import, division, print_function)
__metaclass__ = type __metaclass__ = type
from ansible_collections.community.general.tests.unit.compat import unittest from ansible_collections.community.internal_test_tools.tests.unit.compat import unittest
from .oneview_module_loader import SanManagerInfoModule from .oneview_module_loader import SanManagerInfoModule
from .hpe_test_utils import FactsParamsTestCase from .hpe_test_utils import FactsParamsTestCase

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