-
Notifications
You must be signed in to change notification settings - Fork 1
Expand file tree
/
Copy pathtox.ini
More file actions
71 lines (66 loc) · 1.6 KB
/
Copy pathtox.ini
File metadata and controls
71 lines (66 loc) · 1.6 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
70
71
[tox]
requires =
tox>=4.2
tox-uv>=1.25
env_list =
lint
tests
docs
mypy
pkg_meta
[testenv:lint]
description = run static analysis and style check using ruff
skip_install = true
deps =
pre-commit-uv>=4.1.1
commands =
pre-commit run --all-files --show-diff-on-failure
dependency_groups = dev
[testenv:tests]
runner = uv-venv-lock-runner
description = run tests
pass_env =
BROKER_URL
CI
CONSTANCE_REDIS_URL
DATABASE_URL
GDAL_LIBRARY_PATH
GEOS_LIBRARY_PATH
REDIS_URL
set_env =
PYTHONDONTWRITEBYTECODE = 1
PYTHONWARNINGS = ignore::DeprecationWarning
SECRET_KEY = super_secret_but_really_insecure_key_just_for_testing
commands =
{posargs:pytest tests -rw --headless --cov-report=xml --junit-xml=junit.xml -o junit_family=legacy}
dependency_groups = dev
[testenv:docs]
description = build mkdocs documentation
skip_install = false
deps =
commands =
mkdocs build {posargs: -q}
dependency_groups = docs
[testenv:mypy]
description = run type check on code base
pass_env =
GDAL_LIBRARY_PATH
GEOS_LIBRARY_PATH
commands =
mypy --config-file mypy.ini {posargs:}
dependency_groups =
dev
type-check
[testenv:pkg_meta]
runner = uv-venv-lock-runner
description = check that python package
skip_install = true
deps =
check-wheel-contents>=0.6
twine>=5.1.1
uv>=0.5
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_beneficiary_portal --find-links {env_tmp_dir} hope_beneficiary_portal