-
Notifications
You must be signed in to change notification settings - Fork 1
Expand file tree
/
Copy pathtox.ini
More file actions
69 lines (64 loc) · 1.36 KB
/
tox.ini
File metadata and controls
69 lines (64 loc) · 1.36 KB
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
[tox]
requires =
tox>=4.2
tox-gh-actions
tox-uv>=1.20.2
env_list =
lint
mypy
tests
pkg_meta
skip_missing_interpreters = true
[testenv]
base_python = python3.14
skip_install = true
deps =
pip
uv
pass_env =
DATABASE_URL
PYTHONDONTWRITEBYTECODE
PYTHONPATH
USER
set_env =
PYTHONDONTWRITEBYTECODE = true
PYTHONPATH = {toxinidir}/src
commands =
{posargs:pytest tests -rw --headless}
allowlist_externals =
pytest
[testenv:lint]
description = run static analysis and style check using ruff
skip_install = true
deps =
pre-commit-uv
pass_env =
HOMEPATH
commands =
pre-commit run --all-files --show-diff-on-failure
[testenv:mypy]
description = run type check on code base
deps =
django==5.2.*
commands =
mypy --config-file mypy.ini {posargs:}
dependency_groups =
dev
type-check
[testenv:pkg_meta]
skip_install = true
deps =
build
twine
set_env =
TWINE_PASSWORD = {env:TWINE_TEST_PASSWORD}
TWINE_USERNAME = {env:TWINE_TEST_USERNAME:__token__}
commands =
uv build --sdist -q --out-dir {env_tmp_dir} .
uvx twine check {env_tmp_dir}{/}*
uvx check-wheel-contents --ignore W002,W004,W009,W004 {env_tmp_dir}
uv pip install --no-binary hope_country_workspace --find-links {env_tmp_dir} hope_country_workspace
[testenv:report]
commands =
pip install coverage
coverage html