-
Notifications
You must be signed in to change notification settings - Fork 6
/
Copy pathtox.ini
106 lines (89 loc) · 2.91 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
# Tox (https://tox.readthedocs.io/) is a tool for running tests
# in multiple virtualenvs. This configuration file will run the
# test suite on all supported python versions. To use it, "python -m pip install tox"
# and then run "tox" from this directory.
# Tox is used by the GitHub Actions workflow to run tests on multiple environments.
[tox]
# NOTE: if the string "py39" is in the environment name, then the py39 interpreter is used,
# so we can omit specifying the basepython version below.
envlist = py39, py310, py311, py312, py313
requires = pip >= 24.3.1
[testenv]
download = True
setenv =
PYTHONDONTWRITEBYTECODE = 1
install_command =
python -m pip install -U {opts} {packages}
extras = test
commands =
python -m pip list
python -m pip check
pytest -v
# Env to create coverage report locally
[testenv:localcoverage]
basepython = python3.13
commands =
python -m pip list
python -m pip check
pytest --cov=hdmf_zarr
coverage html -d tests/coverage/htmlcov
# Envs that run tests
[testenv:py{39,310,311,312,313}]
commands = {[testenv]commands}
# Test with python 3.13 and all optional dependencies
[testenv:py313-optional]
extras = {[testenv]extras}, full
commands = {[testenv]commands}
# Test with python 3.13 and all optional dependencies, using pre-release versions
[testenv:py313-prerelease]
install_command =
python -m pip install -U --pre {opts} {packages}
extras = {[testenv]extras}, full
commands = {[testenv]commands}
# Test with python 3.9 and minimum dependencies
[testenv:py39-minimum]
install_command =
python -m pip install {opts} {packages}
deps =
-r requirements-min.txt
commands = {[testenv]commands}
# Envs that builds wheels and source distribution
[testenv:build]
commands =
python -m pip install -U build
python -m pip list
python -m pip check
python -m build
# Envs that will test installation from a wheel
[testenv:wheelinstall]
extras = null
commands =
python -m pip list
python -m pip check
python -c "import hdmf_zarr"
# Envs that will execute gallery tests
[testenv:gallery]
# NOTE: the gallery tests do not require the "docs" extras
commands =
python -m pip list
python -m pip check
python test_gallery.py
[testenv:gallery-{py39,py310,py311,py312,py313}]
commands = {[testenv:gallery]commands}
# Test with python 3.13 and all optional dependencies
[testenv:gallery-py313-optional]
extras = {[testenv:gallery]extras}, full
commands = {[testenv:gallery]commands}
# Test with python 3.13 and all optional dependencies, using pre-release versions
[testenv:gallery-py313-prerelease]
install_command =
python -m pip install -U --pre {opts} {packages}
extras = {[testenv:gallery]extras}, full
commands = {[testenv:gallery]commands}
# Test with python 3.9 and minimum dependencies
[testenv:gallery-py39-minimum]
install_command =
python -m pip install {opts} {packages}
deps =
-r requirements-min.txt
commands = {[testenv:gallery]commands}