tox.ini 1.54 KB
Newer Older
1
[tox]
2
envlist = py{35,36,37}-django{111,20,latest},pep8
3

4 5
[testenv]
usedevelop = True
6
changedir = {toxinidir}/example_project
Florian Fuchs's avatar
Florian Fuchs committed
7
deps =
Aurélien Bompard's avatar
Aurélien Bompard committed
8
    mock
9
    beautifulsoup4
10
    mailman
11
    pytest
12
    pytest-django
Aurélien Bompard's avatar
Aurélien Bompard committed
13 14
    head: git+https://gitlab.com/mailman/mailmanclient.git
    head: git+https://gitlab.com/mailman/django-mailman3.git
15 16 17
    dev: -e../mailmanclient
    dev: -e../django-mailman3
    dev: https://github.com/django/django/archive/master.tar.gz
18
    django111: Django>=1.11,<1.12
Stephen Turnbull's avatar
Stephen Turnbull committed
19
    django20: Django>=2.0,<2.1
20
    django21: Django>=2.1,<2.2
21
    django22: Django>=2.2,<2.3
22
    django-latest: https://github.com/django/django/archive/master.tar.gz
23
commands =
24
  pytest {posargs:../src}
25
setenv =
26 27
    LC_ALL = C.UTF-8
    LANG = C.UTF-8
28

Simon Hanna's avatar
Simon Hanna committed
29
[testenv:coverage]
30
basepython = python3
Simon Hanna's avatar
Simon Hanna committed
31
deps =
32
    {[testenv]deps}
33
    Django>=2.1,<2.2
Simon Hanna's avatar
Simon Hanna committed
34 35
    coverage
commands =
36 37 38 39 40 41
    coverage run -m pytest {posargs:../src/postorius}
    coverage html
    coverage report -m
setenv =
    LC_ALL = C.UTF-8
    LANG = C.UTF-8
Simon Hanna's avatar
Simon Hanna committed
42

43
[testenv:pep8]
44
basepython = python3
45
changedir = {toxinidir}
46 47
deps =
    flake8
48
    Django>1.11,<2.2
49
    isort
50 51
commands =
    flake8 {posargs}
Abhilash Raj's avatar
Abhilash Raj committed
52
    python setup.py isort
53

54

55
[flake8]
56
basepython = python3
57
ignore = E123, E133, W504
58
show-source = True
59
exclude = .git,.tox,dist,*egg,src/postorius/doc,example_project
Abhilash Raj's avatar
Abhilash Raj committed
60 61 62 63 64 65 66 67 68 69 70 71 72


[isort]
line_length=79
multi_line_output=4
balanced_wrapping=True
known_django=django
sections=FUTURE,STDLIB,DJANGO,THIRDPARTY,FIRSTPARTY,LOCALFOLDER
no_lines_before=LOCALFOLDER
lines_after_imports=2
use_paranthesis=True
default_section=THIRDPARTY
known_first_party=postorius