-
Notifications
You must be signed in to change notification settings - Fork 14
Expand file tree
/
Copy pathtox.ini
More file actions
86 lines (81 loc) · 1.73 KB
/
tox.ini
File metadata and controls
86 lines (81 loc) · 1.73 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
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
[tox]
requires =
tox>=4.2
tox-gh-actions
tox-uv>=1.20.2
env_list =
lint
unit
selenium
mypy
packaging
skip_missing_interpreters = true
[testenv]
base_python = python3.13
pass_env =
CACHE_LOCATION
CELERY_BROKER_URL
CELERY_RESULT_BACKEND
CONSTANCE_REDIS_CONNECTION
DATABASE_URL
ELASTICSEARCH_HOST
GDAL_LIBRARY_PATH
GEOS_LIBRARY_PATH
PYTHONBREAKPOINT
PYTHONDONTWRITEBYTECODE
REP_DATABASE_URL
set_env =
CACHE_ENABLED = false
CELERY_TASK_ALWAYS_EAGER = true
DATA_VOLUME = {toxinidir}/data
DEBUG = true
ELASTICSEARCH_SYNONYMS_FILE = {toxinidir}/src/data/synonyms.txt
ENV = dev
PROJECT_ROOT = {toxinidir}/src/hope
PYTHONUNBUFFERED = 1
SECRET_KEY = secretkey
TESTS_ROOT = {toxinidir}/tests/unit
USE_DUMMY_EXCHANGE_RATES = yes
change_dir = {tox_root}
[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]
runner = uv-venv-lock-runner
description = run mypy type checking
commands =
mypy src
dependency_groups = dev
[testenv:packaging]
description = Check the package builds correctly
skip_install = true
deps =
build
twine
commands =
python -m build --sdist --wheel .
twine check dist/*
[testenv:tests]
runner = uv-venv-lock-runner
description = Run all tests (unit + e2e)
set_env =
{[testenv]set_env}
PYTHONWARNINGS = ignore
commands =
{posargs:pytest \
-q \
-rfE \
--no-header \
--tb=short \
--no-migrations \
--randomly-seed=42 \
--dist=loadgroup \
--create-db \
tests }
dependency_groups = dev