mirror of
https://github.com/jazzband/django-auditlog.git
synced 2026-03-16 22:20:26 +00:00
* Add CustomLogEntry model support and update tests: - Added support for CustomLogEntry data model to extend django-auditlog capabilities - Updated existing test cases to align with new model structure and data handling logic - Added new test cases to validate CustomLogEntry behavior, model registration, and signal handling - Ensured backward compatibility with existing LogEntry model where applicable * Update auditlog/__init__.py Co-authored-by: Youngkwang Yang <me@youngkwang.dev> * run only one custom model test matrix (#761) --------- Co-authored-by: Youngkwang Yang <me@youngkwang.dev>
81 lines
1.7 KiB
INI
81 lines
1.7 KiB
INI
[tox]
|
|
envlist =
|
|
{py312}-customlogmodel-django52
|
|
{py310,py311}-django42
|
|
{py310,py311,py312}-django50
|
|
{py310,py311,py312,py313}-django51
|
|
{py310,py311,py312,py313}-django52
|
|
{py312,py313}-djangomain
|
|
py310-docs
|
|
py310-lint
|
|
py310-checkmigrations
|
|
|
|
|
|
[testenv]
|
|
setenv =
|
|
COVERAGE_FILE={toxworkdir}/.coverage.{envname}.{env:TEST_DB_BACKEND}
|
|
customlogmodel: AUDITLOG_LOGENTRY_MODEL = custom_logentry_app.CustomLogEntryModel
|
|
changedir = auditlog_tests
|
|
commands =
|
|
coverage run --source auditlog ./manage.py test
|
|
coverage xml
|
|
deps =
|
|
django42: Django>=4.2,<4.3
|
|
django50: Django>=5.0,<5.1
|
|
django51: Django>=5.1,<5.2
|
|
django52: Django>=5.2,<5.3
|
|
djangomain: https://github.com/django/django/archive/main.tar.gz
|
|
# Test requirements
|
|
coverage
|
|
codecov
|
|
freezegun
|
|
psycopg2-binary
|
|
mysqlclient
|
|
|
|
passenv=
|
|
TEST_DB_BACKEND
|
|
TEST_DB_HOST
|
|
TEST_DB_USER
|
|
TEST_DB_PASS
|
|
TEST_DB_NAME
|
|
TEST_DB_PORT
|
|
|
|
basepython =
|
|
py313: python3.13
|
|
py312: python3.12
|
|
py311: python3.11
|
|
py310: python3.10
|
|
|
|
[testenv:py310-docs]
|
|
changedir = docs/source
|
|
deps = -rdocs/requirements.txt
|
|
commands = sphinx-build -W -b html -d {envtmpdir}/doctrees . {envtmpdir}/html
|
|
|
|
[testenv:py310-lint]
|
|
deps = pre-commit
|
|
commands =
|
|
pre-commit run --all-files
|
|
|
|
[testenv:py310-checkmigrations]
|
|
description = Check for missing migrations
|
|
changedir = auditlog_tests
|
|
deps =
|
|
Django>=4.2
|
|
psycopg2-binary
|
|
mysqlclient
|
|
passenv=
|
|
TEST_DB_BACKEND
|
|
TEST_DB_HOST
|
|
TEST_DB_USER
|
|
TEST_DB_PASS
|
|
TEST_DB_NAME
|
|
TEST_DB_PORT
|
|
commands =
|
|
python manage.py makemigrations --check --dry-run
|
|
|
|
[gh-actions]
|
|
python =
|
|
3.10: py310
|
|
3.11: py311
|
|
3.12: py312
|
|
3.13: py313
|