authentic2-cut/tox.ini

84 lines
2.1 KiB
INI
Raw Normal View History

2018-09-27 15:53:28 +02:00
# Tox (http://tox.testrun.org/) is a tool for running tests
# in multiple virtualenvs. This configuration file will run the
# test suite on all supported python versions. To use it, "pip install tox"
# and then run "tox" from this directory.
[tox]
toxworkdir = {env:TMPDIR:/tmp}/tox-{env:USER}/authentic2-cut/{env:BRANCH_NAME:}
2020-05-15 16:01:06 +02:00
envlist =
py2-dj111-drf34
py3-dj111-drf34
py3-dj22-drf39
[tox:jenkins]
envlist =
pylint
py2-dj111-drf34
py3-dj111-drf34
py3-dj22-drf39
2018-09-27 15:53:28 +02:00
[testenv]
setenv =
AUTHENTIC2_SETTINGS_FILE=tests/settings.py
DJANGO_SETTINGS_MODULE=authentic2.settings
2020-05-15 16:01:06 +02:00
JUNIT={tty::-o junit_suite_name={envname} --junit-xml=junit-{envname}.xml}
COVERAGE={tty::--junitxml=test_{envname}_results.xml --cov-report xml --cov-report html --cov=src/ --cov-config .coveragerc}
passenv=
BRANCH_NAME
# support for pg_virtualenv
PGPORT
PGHOST
PGUSER
PGPASSWORD
usedevelop = true
2018-09-27 15:53:28 +02:00
deps =
2020-05-15 16:01:06 +02:00
http://git.entrouvert.org/authentic.git/snapshot/authentic-master.tar.gz
# dependency constraints for authentic
py2: django-appconf<1.0.4
py2: django-filter<2
drf34: djangorestframework>=3.4,<3.4.1
drf39: djangorestframework>=3.9.2,<3.10
dj111: django<2.0
dj22: django<2.3
django-tables<2.0
psycopg2-binary
oldldap: python-ldap<3
ldaptools
# pytest requirements
2018-09-27 15:53:28 +02:00
pytest
2020-05-15 16:01:06 +02:00
pytest-cov
pytest-django
pytest-freezegun
2020-05-15 16:01:06 +02:00
pytest-random
django-webtest
pyquery
2018-09-27 15:53:28 +02:00
commands =
2020-05-15 16:01:06 +02:00
py2: ./getlasso.sh
py3: ./getlasso3.sh
2020-05-15 16:01:06 +02:00
py.test {env:COVERAGE:} {env:JUNIT:} {tty:--sw:} {posargs:tests/}
[testenv:pylint]
skip_install = True
deps =
http://git.entrouvert.org/authentic.git/snapshot/authentic-master.tar.gz
Django<2.3
pylint
pylint-django
commands =
/bin/bash -c "./pylint.sh src/*/"
[pytest]
junit_family=xunit2
filterwarnings =
error
# there is nothing we can do about that
ignore:defusedxml.lxml is no longer supported:DeprecationWarning:openpyxl.xml.functions
ignore:Using or importing the ABCs from 'collections':DeprecationWarning:django.*
ignore:Using user.is_authenticated\(\) and user.is_anonymous\(\) as a method is deprecated.::rest_framework\.*
# remind us later
once:.*staticfiles.*::django\..*