[flake8]
max-line-length = 180
extend-ignore = E203
extend-exclude = */migrations/*
ban-relative-imports = parents
banned-modules =
  jinja2.Template = Use apply_jinja_template instead
  django.apps.apps = Import models directly instead

[pytest]
# https://pytest-django.readthedocs.io/en/latest/configuring_django.html#order-of-choosing-settings
# https://pytest-django.readthedocs.io/en/latest/database.html
# https://pytest-xdist.readthedocs.io/en/stable/distribution.html#running-tests-across-multiple-cpus
#
# --dist no = temporarily disable xdist as it's leading to flaky tests :(
# https://github.com/grafana/oncall-private/issues/2733
addopts = --dist no --no-migrations --color=yes --showlocals
# https://pytest-django.readthedocs.io/en/latest/faq.html#my-tests-are-not-being-found-why
python_files = tests.py test_*.py *_tests.py

filterwarnings =
  ignore:::django_filters.*
  ignore:::httpretty.*
  ignore:::polymorphic.*
  ignore:::telegram.*
