diff --git a/tests/pytests/functional/utils/yamllint/test_yamllint.py b/tests/pytests/functional/utils/yamllint/test_yamllint.py index 403c6fc610e..3c730523c4d 100644 --- a/tests/pytests/functional/utils/yamllint/test_yamllint.py +++ b/tests/pytests/functional/utils/yamllint/test_yamllint.py @@ -7,7 +7,7 @@ import salt.utils.versions as versions try: import salt.utils.yamllint as yamllint - YAMLLINT_AVAILABLE = True + YAMLLINT_AVAILABLE = yamllint.has_yamllint() except ImportError: YAMLLINT_AVAILABLE = False diff --git a/tests/pytests/unit/modules/test_yaml.py b/tests/pytests/unit/modules/test_yaml.py index 1f00af710c8..75bad8b5cf1 100644 --- a/tests/pytests/unit/modules/test_yaml.py +++ b/tests/pytests/unit/modules/test_yaml.py @@ -13,7 +13,7 @@ try: import salt.modules.yaml import salt.utils.yamllint - YAMLLINT_AVAILABLE = True + YAMLLINT_AVAILABLE = salt.utils.yamllint.has_yamllint() except ImportError: YAMLLINT_AVAILABLE = False