mirror of
https://github.com/ansible-collections/community.general.git
synced 2026-05-06 13:22:48 +00:00
Replace nose with pytest
This commit is contained in:
@@ -23,13 +23,13 @@ try:
|
||||
except:
|
||||
HAS_BOTO3 = False
|
||||
|
||||
from nose.plugins.skip import SkipTest
|
||||
import pytest
|
||||
|
||||
from units.compat import unittest
|
||||
from ansible.module_utils.ec2 import AWSRetry
|
||||
|
||||
if not HAS_BOTO3:
|
||||
raise SkipTest("test_aws.py requires the python modules 'boto3' and 'botocore'")
|
||||
pytestmark = pytest.mark.skip("test_aws.py requires the python modules 'boto3' and 'botocore'")
|
||||
|
||||
|
||||
class RetryTestCase(unittest.TestCase):
|
||||
|
||||
@@ -25,7 +25,7 @@ from ansible.module_utils.network.aci.aci import ACIModule
|
||||
from ansible.module_utils.six import PY2, PY3
|
||||
from ansible.module_utils._text import to_native
|
||||
|
||||
from nose.plugins.skip import SkipTest
|
||||
import pytest
|
||||
|
||||
|
||||
class AltModule():
|
||||
@@ -52,7 +52,7 @@ try:
|
||||
if sys.version_info >= (2, 7):
|
||||
from xmljson import cobra
|
||||
except ImportError:
|
||||
raise SkipTest("ACI Ansible modules require the lxml and xmljson Python libraries")
|
||||
pytestmark = pytest.mark.skip("ACI Ansible modules require the lxml and xmljson Python libraries")
|
||||
|
||||
|
||||
class AciRest(unittest.TestCase):
|
||||
|
||||
Reference in New Issue
Block a user