Files
edx-platform/common/lib/pytest.ini
Ned Batchelder 66eae81add docs: comments about how pytest finds settings (#29623)
It took a while for me to understand why my setup.cfg setting was only
applying to some tests.  Hopefully these comments will save someone else
some confusion.
2021-12-21 10:47:59 -05:00

23 lines
1.2 KiB
INI

[pytest]
# Note: The first file of settings found is used, there is no combining, so
# this file is used for the tests in the common/lib tree, and setup.cfg is ignored.
# Details at https://docs.pytest.org/en/latest/reference/customize.html
# Use the LMS settings for these tests; should work with CMS just as well though:
DJANGO_SETTINGS_MODULE = lms.envs.test
addopts = --nomigrations --reuse-db --durations=20 --json-report --json-report-omit keywords streams collectors log traceback tests --json-report-file=none
# Enable default handling for all warnings, including those that are ignored by default;
# but hide rate-limit warnings (because we deliberately don't throttle test user logins)
# and field_data deprecation warnings (because fixing them requires a major low-priority refactoring)
filterwarnings =
default
ignore:No request passed to the backend, unable to rate-limit:UserWarning
ignore::xblock.exceptions.FieldDataDeprecationWarning
ignore::django.utils.deprecation.RemovedInDjango40Warning
ignore::django.utils.deprecation.RemovedInDjango41Warning
markers =
mongo
norecursedirs = .cache
python_classes =
python_files = tests.py test_*.py tests_*.py *_tests.py __init__.py