forked from jquast/wcwidth
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathtox.ini
160 lines (137 loc) · 4.36 KB
/
tox.ini
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
[tox]
envlist = update, compile, autopep8, docformatter, isort, pylint, flake8, flake8_tests, pydocstyle, docs, py26, py27, py34, py35, py36
skip_missing_interpreters = true
[testenv]
deps = pytest==4.6.10
pytest-cov==2.8.1
commands = {envpython} -m pytest --cov-config={toxinidir}/tox.ini {posargs:\
--strict --verbose \
--junit-xml=.tox/results.{envname}.xml \
--durations=3 \
} \
--log-format='%(levelname)s %(relativeCreated)2.2f %(filename)s:%(lineno)d %(message)s' \
tests
passenv = TEST_QUICK TEST_KEYBOARD TEST_RAW
[isort]
line_length = 100
indent = ' '
multi_line_output = 1
length_sort = 1
import_heading_stdlib = std imports
import_heading_thirdparty = 3rd party
import_heading_firstparty = local
import_heading_localfolder = local
sections=FUTURE,STDLIB,THIRDPARTY,FIRSTPARTY,LOCALFOLDER
no_lines_before=LOCALFOLDER
known_first_party = wcwidth
known_third_party = codecov,docopt,blessed
atomic = true
[pytest]
looponfailroots = wcwidth
norecursedirs = .git .tox build
addopts = --disable-pytest-warnings
--cov-append --cov-report=html --color=yes --ignore=setup.py --ignore=.tox
--cov=wcwidth
filterwarnings =
error
junit_family = xunit1
[flake8]
max-line-length = 100
exclude = .tox,build
deps = flake8==3.8.2
[coverage:run]
branch = True
source = wcwidth
parallel = True
[coverage:report]
omit = tests/*
exclude_lines = pragma: no cover
precision = 1
[coverage:paths]
source = wcwidth/
[testenv:compile]
basepython = python3.8
commands = python -m compileall {toxinidir}/wcwidth
[testenv:update]
usedevelop = true
basepython = python3.8
deps =
commands = python {toxinidir}/bin/update-tables.py
python -mcompileall {toxinidir}/wcwidth/table_zero.py \
{toxinidir}/wcwidth/table_wide.py
[testenv:autopep8]
basepython = python3.8
deps = autopep8==1.4.4
commands =
{envbindir}/autopep8 \
--in-place \
--recursive \
--aggressive \
--aggressive \
wcwidth/ bin/ tests/ setup.py
[testenv:docformatter]
deps =
docformatter==1.3.1
untokenize==0.1.1
commands =
{envbindir}/docformatter \
--in-place \
--recursive \
--pre-summary-newline \
--wrap-summaries=100 \
--wrap-descriptions=100 \
{toxinidir}/wcwidth \
{toxinidir}/bin \
{toxinidir}/setup.py \
{toxinidir}/docs/conf.py
basepython = python3.8
[testenv:isort]
deps = {[testenv]deps}
-r docs/requirements.txt
isort==4.3.21
commands = {envbindir}/isort --quiet --apply --recursive
basepython = python3.8
[testenv:pylint]
deps = pylint==2.5.2
commands = {envbindir}/pylint --rcfile={toxinidir}/.pylintrc \
--ignore=tests,docs,setup.py,conf.py,build,distutils,.pyenv,.git,.tox \
{posargs:{toxinidir}}/wcwidth
[testenv:flake8]
deps = {[flake8]deps}
commands = {envbindir}/flake8 --ignore=F401,W503,W504 --exclude=tests setup.py docs/ wcwidth/ bin/
[testenv:flake8_tests]
deps = {[flake8]deps}
commands = {envbindir}/flake8 --ignore=W503,W504,F811,F401 tests/ bin/
[testenv:pydocstyle]
deps = pydocstyle==5.0.2
restructuredtext_lint==1.3.0
doc8==0.8.0
pygments
commands = {envbindir}/pydocstyle --source --explain {toxinidir}/blessed
{envbindir}/rst-lint README.rst
{envbindir}/doc8 --ignore-path docs/_build --ignore D000 docs
[testenv:check]
deps = -rrequirements-develop.txt
usedevelop = true
commands = prospector {posargs:--no-autodetect --die-on-tool-error}
basepython = python3.8
[testenv:docs]
deps = sphinx
commands = sphinx-build docs/ build/sphinx
[testenv:sphinx]
deps = -r {toxinidir}/docs/requirements.txt
commands = {envbindir}/sphinx-build {posargs:-v -W -d {toxinidir}/docs/_build/doctrees -b html docs {toxinidir}/docs/_build/html}
[testenv:linkcheck]
deps = -r {toxinidir}/docs/requirements.txt
commands = {envbindir}/sphinx-build -v -W -d {toxinidir}/docs/_build/doctrees -b linkcheck docs docs/_build/linkcheck
[testenv:codecov]
basepython = python{env:TOXPYTHON:{env:TRAVIS_PYTHON_VERSION:3.8}}
passenv = TOXENV CI TRAVIS TRAVIS_* CODECOV_*
deps = codecov>=1.4.0
tenacity==6.1.0
# commands = codecov -e TOXENV
# Workaround for https://github.com/codecov/codecov-python/issues/158
commands = {envpython} bin/run_codecov.py -e TOXENV
[testenv:develop]
deps = -rrequirements-develop.txt
commands = {posargs}