mirror of
https://github.com/ansible-collections/community.general.git
synced 2025-08-05 21:54:22 -07:00
error mock module
This commit is contained in:
parent
e97bc68499
commit
096f019aef
1 changed files with 8 additions and 1 deletions
|
@ -2,7 +2,13 @@ from __future__ import absolute_import, division, print_function
|
|||
__metaclass__ = type
|
||||
|
||||
import pytest
|
||||
from unittest.mock import mock_open, patch, MagicMock
|
||||
|
||||
|
||||
try:
|
||||
from unittest.mock import mock_open, patch, MagicMock
|
||||
except ImportError:
|
||||
from mock import mock_open, patch, MagicMock
|
||||
|
||||
from plugins.modules.nfs_exports_info import get_exports
|
||||
|
||||
|
||||
|
@ -57,3 +63,4 @@ def test_get_exports_shares_per_ip(fake_exports_content):
|
|||
|
||||
assert result['exports_info'] == expected
|
||||
assert result['file_digest'] == "fake_sha1_digest"
|
||||
|
Loading…
Add table
Add a link
Reference in a new issue