-
Notifications
You must be signed in to change notification settings - Fork 0
/
tox.ini
84 lines (78 loc) · 1.81 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
[tox]
minversion = 4.3.5
env_list =
py310
py311
py312
py313
coverage
codestyle
docs
linkcheck
spelling
isolated_build = True
[testenv]
description = run the tests with pytest
package = wheel
changedir = {envtmpdir}
deps =
pytest>=6
passenv = GEOGRAPHICLIB_DATA
commands =
python3 -m pytest --doctest-modules {tty:--color=yes} -W error --pyargs geomodels {posargs}
[testenv:coverage]
description = run coverage
deps =
pytest>=6
pytest-cov
changedir = {envtmpdir}
commands =
python3 -m pytest {tty:--color=yes} --cov geomodels --cov-report=html --cov-report=term --pyargs geomodels
[testenv:codestyle]
description = run linting
allowlist_externals = ruff
skip_install = true
deps =
flake8
pydocstyle
isort
black
mypy
changedir = {package_root}
commands =
python3 -m flake8 --version
python3 -m flake8 --count --statistics geomodels
python3 -m pydocstyle --count geomodels
python3 -m isort --check geomodels
python3 -m black --check geomodels
# python3 -m mypy --check-untyped-defs --ignore-missing-imports geomodels
ruff check geomodels
[testenv:docs]
description = build docs
allowlist_externals = mkdir
changedir = docs
deps =
-r requirements-docs.txt
commands =
mkdir -p _static
python3 -m sphinx -W -b html . _build/html
python3 -m sphinx -W -b doctest . _build/doctest
[testenv:linkcheck]
description = linkcheck
allowlist_externals = mkdir
changedir = docs
deps =
-r requirements-docs.txt
commands =
mkdir -p _static
python3 -m sphinx -W -b linkcheck . _build/linkcheck
[testenv:spelling]
description = check spelling
allowlist_externals = mkdir
changedir = docs
deps =
-r requirements-docs.txt
sphinxcontrib-spelling
commands =
mkdir -p _static
python3 -m sphinx -W -b spelling . _build/spelling