-
Notifications
You must be signed in to change notification settings - Fork 2
/
tox.ini
183 lines (168 loc) · 5.43 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
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
[tox]
envlist = py{38,39,310,311,312}
toxworkdir=.tox
download=true
isolated_build = true
[pytest]
testpaths = tests
python_files = tests.py test_*.py *_tests.py
[testingenv]
deps =
coverage
pytest
pytest-cov
[checkerenv]
deps =
bandit[toml]
black
flake8
mypy
pycodestyle
[pycodestyle]
max-line-length = 88
exclude =
.coverage,
.eggs,
.git,
.tox,
.pytest_cache,
build,
coverage,
dist,
venv,
__pycache__,
[flake8]
max-line-length = 88
exclude =
.eggs,
.git,
.tox,
build,
coverage,
dist,
venv,
__pycache__,
[testenv:py{38,39,310,311,312}-mypy]
description = Runs mypy type checker. See: https://github.com/python/mypy
envdir =
py38: {toxworkdir}/.py38-checkers
py39: {toxworkdir}/.py39-checkers
py310: {toxworkdir}/.py310-checkers
py311: {toxworkdir}/.py311-checkers
py312: {toxworkdir}/.py312-checkers
skip_install = true
deps = {[checkerenv]deps}
commands = mypy {toxinidir} --install-types --non-interactive
[testenv:py{38,39,310,311,312}-pycodestyle]
description = Runs pycodestyle style checker. See: https://github.com/pycqa/pycodestyle
envdir =
py38: {toxworkdir}/.py38-checkers
py39: {toxworkdir}/.py39-checkers
py310: {toxworkdir}/.py310-checkers
py311: {toxworkdir}/.py311-checkers
py312: {toxworkdir}/.py312-checkers
skip_install = true
deps = {[checkerenv]deps}
commands = pycodestyle {toxinidir}
[testenv:py{38,39,310,311,312}-flake8]
description = Runs flake8 style checker. See: https://github.com/pycqa/flake8
envdir =
py38: {toxworkdir}/.py38-checkers
py39: {toxworkdir}/.py39-checkers
py310: {toxworkdir}/.py310-checkers
py311: {toxworkdir}/.py311-checkers
py312: {toxworkdir}/.py312-checkers
skip_install = true
deps = {[checkerenv]deps}
commands = flake8 {toxinidir}
[testenv:py{38,39,310,311,312}-black-check]
description = Runs black to check the code style. See: https://github.com/psf/black
envdir =
py38: {toxworkdir}/.py38-checkers
py39: {toxworkdir}/.py39-checkers
py310: {toxworkdir}/.py310-checkers
py311: {toxworkdir}/.py311-checkers
py312: {toxworkdir}/.py312-checkers
skip_install = true
deps = {[checkerenv]deps}
commands = black {toxinidir} --check --diff
[testenv:py{38,39,310,311,312}-black-format]
description = Runs black to reformat code to style guide. See: https://github.com/psf/black
envdir =
py38: {toxworkdir}/.py38-checkers
py39: {toxworkdir}/.py39-checkers
py310: {toxworkdir}/.py310-checkers
py311: {toxworkdir}/.py311-checkers
py312: {toxworkdir}/.py312-checkers
skip_install = true
deps = {[checkerenv]deps}
commands = black {toxinidir}
[testenv:py{38,39,310,311,312}-bandit]
description = Runs bandit security linter. See: https://github.com/pycqa/bandit
envdir =
py38: {toxworkdir}/.py38-checkers
py39: {toxworkdir}/.py39-checkers
py310: {toxworkdir}/.py310-checkers
py311: {toxworkdir}/.py311-checkers
py312: {toxworkdir}/.py312-checkers
skip_install = true
deps = {[checkerenv]deps}
commands = bandit -x ./.eggs,./.git,./.tox,./build,./coverage,./dist,./venv,./__pycache__,*tests* -r {toxinidir}
[testenv:py{38,39,310,311,312}-pytest]
description = Runs pytest. See: https://docs.pytest.org/en/6.2.x/
envdir =
py38: {toxworkdir}/.py38-testing
py39: {toxworkdir}/.py39-testing
py310: {toxworkdir}/.py310-testing
py311: {toxworkdir}/.py311-testing
py312: {toxworkdir}/.py312-testing
skip_install = true
deps =
.[all]
{[testingenv]deps}
commands = pytest
[testenv:py{38,39,310,311,312}-pytest-cov]
description = Runs coverage. See: https://coverage.readthedocs.io/en/6.0.2/
envdir =
py38: {toxworkdir}/.py38-testing
py39: {toxworkdir}/.py39-testing
py310: {toxworkdir}/.py310-testing
py311: {toxworkdir}/.py311-testing
py312: {toxworkdir}/.py312-testing
skip_install = true
deps =
-e.[all]
{[testingenv]deps}
commands = pytest --cov-report=html --cov-report=term --cov-report=term-missing --cov=src/table2xsv tests/
[testenv:py{38,39,310,311,312}-build]
description = Build wheels. https://wheel.readthedocs.io/en/stable/
envdir =
py38: {toxworkdir}/.py38-build
py39: {toxworkdir}/.py39-build
py310: {toxworkdir}/.py310-build
py311: {toxworkdir}/.py311-build
py312: {toxworkdir}/.py312-build
skip_install = true
deps =
-e.[all]
build
commands =
py38: python -m build -w -C="--build-option=--python-tag" -C="--build-option=py38"
py39: python -m build -w -C="--build-option=--python-tag" -C="--build-option=py39"
py310: python -m build -w -C="--build-option=--python-tag" -C="--build-option=py310"
py311: python -m build -w -C="--build-option=--python-tag" -C="--build-option=py311"
py312: python -m build -w -C="--build-option=--python-tag" -C="--build-option=py312"
python -m build -s
[testenv:py{38,39,310,311,312}-build-exe]
description = Build executable with PyInstaller. https://pyinstaller.readthedocs.io/en/stable/
envdir =
py38: {toxworkdir}/.py38-build-exe
py39: {toxworkdir}/.py39-build-exe
py310: {toxworkdir}/.py310-build-exe
py311: {toxworkdir}/.py311-build-exe
py312: {toxworkdir}/.py312-build-exe
skip_install = true
deps =
-e.[all]
pyinstaller
commands = pyinstaller src/main.py -n Table2XSV -F --collect-all='table2xsv' --hidden-import='pandas' --hidden-import='neo4j' --hidden-import='neobolt.packstream.packer' --hidden-import='neobolt.packstream.unpacker' --hidden-import='neobolt.bolt' --hidden-import='neobolt.bolt.io'