-
Notifications
You must be signed in to change notification settings - Fork 4
/
Copy pathtox.ini
56 lines (51 loc) · 1.46 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
[tox]
envlist = py312-{base,stable},py{310,311}-{base,i18n,stable},flake8,i18n,docs
# Note: can't run i18n on py312 due to https://github.com/level12/morphi/issues/8
[testenv]
# Ignore all "not installed in testenv" warnings.
allowlist_externals = *
recreate = true
setenv =
PIP_EXTRA_INDEX_URL=https://package-index.level12.net
passenv = SQLALCHEMY_DATABASE_URI
commands =
stable: pip install --progress-bar off -r ./stable-requirements.txt
pip install --progress-bar off .[tests]
i18n: pip install --progress-bar off .[i18n]
pip freeze
py.test \
# feed a blank file so that a user's default pytest.ini doesn't get used
-c .ci/pytest.ini \
-ra \
--tb native \
--strict-markers \
--cov keg_elements \
--cov-config .coveragerc \
--cov-report xml \
--no-cov-on-fail \
--junit-xml={toxinidir}/.ci/test-reports/{envname}.pytests.xml \
keg_elements
[testenv:flake8]
basepython = python3.12
skip_install = true
usedevelop = false
deps = flake8
commands = flake8 keg_elements
[testenv:i18n]
basepython = python3.11
skip_install = true
commands =
pip install .[tests,i18n]
python kegel_app/cli.py verify-translations
[testenv:docs]
basepython = python3.11
recreate = false
skip_install = true
usedevelop = true
commands =
pip install -r docs/requirements.txt
make -C docs/ html
[flake8]
max-line-length = 100
ignore = E731, W503
exclude=.git,.hg,.tox,dist,doc,*egg,build