[pytest] addopts = # `pytest-xdist`: -n auto # `pytest-mon`: # useful for live testing with `pytest-watch` during development: # --testmon --durations=10 -v -ra --showlocals --doctest-modules --junitxml=.test-results/pytest/results.xml # `pytest-cov`: --cov=ansiblelint --cov-report term-missing:skip-covered --cov-report xml:.test-results/pytest/cov.xml --no-cov-on-fail # interpret all the target args as importables: --pyargs # importable packages for test lookup: test ansiblelint.rules doctest_optionflags = ALLOW_UNICODE ELLIPSIS filterwarnings = error # TODO: delete the following ignores once Ansible that we support gets rid of `imp` # Ref: https://github.com/ansible/ansible-lint/pull/734 ignore:the imp module is deprecated in favour of importlib; see the module's documentation for alternative uses:DeprecationWarning:ansible.plugins.loader # TODO: delete the following ignores once Ansible gets rid of direct # imports from `collections` ignore:Using or importing the ABCs from 'collections' instead of from 'collections.abc' is deprecated, and in 3.8 it will stop working:DeprecationWarning ignore:Using or importing the ABCs from 'collections' instead of from 'collections.abc' is deprecated since Python 3.3, and in 3.9 it will stop working:DeprecationWarning ignore:Using or importing the ABCs from 'collections' instead of from 'collections.abc' is deprecated since Python 3.3,and in 3.9 it will stop working:DeprecationWarning junit_duration_report = call # Our github annotation parser from .github/workflows/tox.yml requires xunit1 format. Ref: # https://github.com/shyim/junit-report-annotations-action/issues/3#issuecomment-663241378 junit_family = xunit1 junit_suite_name = ansible_lint_test_suite minversion = 4.6.6 norecursedirs = build dist docs lib/ansible_lint.egg-info .cache .eggs .git .github .tox *.egg python_files = test_*.py # Ref: https://docs.pytest.org/en/latest/reference.html#confval-python_files # Needed to discover legacy nose test modules: Test*.py # Needed to discover embedded Rule tests *Rule.py # Using --pyargs instead of testpath as we embed some tests # See: https://github.com/pytest-dev/pytest/issues/6451#issuecomment-687043537 # testpaths = xfail_strict = true