-
Notifications
You must be signed in to change notification settings - Fork 15
/
Copy pathtox.ini
120 lines (97 loc) · 2.26 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
[tox]
skipsdist = True
envlist = coverage,check,doc
[testenv]
basepython = python3.7
passenv=
TOXENV
CI
CI_*
CIRCLECI
CIRCLE_*
TRAVIS
TRAVIS_*
APPVEYOR
APPVEYOR_*
CODECOV_TOKEN
MARIO_TESTING_IGNORE_TIMER
install_command = poetry {packages}
deps = install
whitelist_externals = poetry
[testenv:simple]
# To make sure that dev deps aren't required, we install only mario and try a
# simple command.
deps = install --no-dev
commands =
mario eval 1
[testenv:test]
commands =
poetry run pytest --cov=mario --cov=tests {posargs}
[testenv:coverage]
commands =
poetry run python -m site
poetry run pytest --cov=mario --cov=tests {posargs}
poetry run coverage report -m --fail-under=95
poetry run cuv graph
[testenv:docshtest]
changedir={envtmpdir}
whitelist_externals =
bash
poetry
commands=
poetry run bash {toxinidir}/tests/find_broken_docshtests.bash {toxinidir}/README.rst
poetry run docshtest {toxinidir}/README.rst
[testenv:check]
commands =
poetry build
poetry run mypy src tests
poetry run pylint src tests
poetry run twine check dist/mario-*
poetry run black --check src/ tests/
poetry run tox -e docshtest
poetry run pre-commit run -a
[testenv:codecov]
skip_install=True
install_command = pip install {packages}
deps= codecov
commands=
python -c 'import sys; print(sys.version)'
codecov
[testenv:doc]
commands =
poetry run pip install -r docs/requirements.txt
poetry run sphinx-apidoc -o docs/reference -f src
poetry run sphinx-build -E -b html docs dist/docs
[testenv:bump]
deps =
bump2version
pre-commit
towncrier
poetry
passenv =
GIT_AUTHOR_NAME
GIT_AUTHOR_EMAIL
GIT_COMMITTER_NAME
GIT_COMMITTER_EMAIL
whitelist_externals =
git
bash
poetry
commands =
pre-commit install --install-hooks
pre-commit run -a
bash ci/bump.bash
[testenv:release]
deps =
twine
passenv =
TWINE_USERNAME
TWINE_PASSWORD
whitelist_externals =
rm
python
poetry
commands =
rm -rf dist
python setup.py sdist bdist_wheel
twine upload --skip-existing dist/*