django-defender/tox.ini
Yurii Parfinenko 289af19ce9
Some checks failed
Test / build (3.10, 5) (push) Has been cancelled
Test / build (3.10, 6) (push) Has been cancelled
Test / build (3.10, 7) (push) Has been cancelled
Test / build (3.11, 5) (push) Has been cancelled
Test / build (3.11, 6) (push) Has been cancelled
Test / build (3.11, 7) (push) Has been cancelled
Test / build (3.12, 5) (push) Has been cancelled
Test / build (3.12, 6) (push) Has been cancelled
Test / build (3.12, 7) (push) Has been cancelled
Test / build (3.13, 5) (push) Has been cancelled
Test / build (3.13, 6) (push) Has been cancelled
Test / build (3.13, 7) (push) Has been cancelled
Test / build (3.9, 5) (push) Has been cancelled
Test / build (3.9, 6) (push) Has been cancelled
Test / build (3.9, 7) (push) Has been cancelled
Use redis cache in get_approx_account_lockouts_from_login_attempts (#250)
* Use redis cache in `get_approx_account_lockouts_from_login_attempts`

* use django_redis in ci

* Add `django_redis` and `redis` to requirements.txt

* Fix an issue detected by tests: clear redis cache upon block reset

* Remove the unnecessary `if`
2026-01-29 12:53:21 -05:00

52 lines
1.1 KiB
INI

[tox]
envlist =
# list of supported Django/Python versions:
py{37,38,39,py3}-dj{32}
py{38,39,310,311}-dj{40,41,42}
py{311}-dj{main}
py38-{lint,docs}
[gh-actions]
python =
3.7: py37
3.8: py38
3.9: py39
3.10: py310
3.11: py311
pypy3: pypy3
[testenv]
deps =
-rrequirements.txt
dj32: django>=3.2,<4.0
dj40: django>=4.0,<4.1
dj41: django>=4.1,<4.2
dj42: django>=4.2,<4.3
djmain: https://github.com/django/django/archive/main.tar.gz
usedevelop = True
commands =
{envbindir}/coverage run --source=defender {envbindir}/django-admin test defender --settings=defender.ci_settings
{envbindir}/coverage report -m
{envbindir}/coverage xml
ignore_outcome =
djmain: True
ignore_errors =
djmain: True
[testenv:py38-docs]
basepython = python3.8
deps =
-rrequirements.txt
Sphinx
sphinx_rtd_theme
commands = sphinx-build -b html -d {envtmpdir}/doctrees docs {envtmpdir}/html
[testenv:py38-lint]
basepython = python3.8
deps =
twine
check-manifest
commands =
check-manifest -v
python setup.py sdist
twine check dist/*