-
Notifications
You must be signed in to change notification settings - Fork 26
/
Copy pathtox.ini
58 lines (52 loc) · 2.25 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
# 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, "pip install tox"
# and then run "tox -e [envname]" from this directory.
[tox]
requires = pip >= 24.3.1
[testenv]
download = True
setenv =
PYTHONDONTWRITEBYTECODE = 1
recreate =
minimum, upgraded, prerelease: False
build, wheelinstall: True # good practice to recreate the environment
skip_install =
minimum, upgraded, prerelease, wheelinstall: False
build: True # no need to install anything when building
install_command =
# when using [testenv:wheelinstall] and --installpkg, the wheel and its dependencies
# are installed, instead of the package in the current directory
minimum, wheelinstall: python -I -m pip install {opts} {packages}
upgraded: python -I -m pip install -U {opts} {packages}
prerelease: python -I -m pip install -U --pre {opts} {packages}
deps =
# which requirements files to use (default: none)
minimum: -r requirements-min.txt
extras =
# which optional dependency set(s) to use (default: none)
pytest: test
gallery: doc
optional: tqdm,sparse,zarr,termset
commands =
# commands to run for every environment
python --version # print python version for debugging
python -m pip check # check for conflicting packages
python -m pip list # list installed packages for debugging
# commands to run for select environments
pytest: pytest -v
gallery: python test_gallery.py
build: python -m pip install -U build
build: python -m build
wheelinstall: python -c "import hdmf; import hdmf.common"
# list of pre-defined environments
[testenv:pytest-py{39,310,311,312,313}-upgraded]
[testenv:pytest-py313-upgraded-optional]
[testenv:pytest-py313-prerelease-optional]
[testenv:pytest-py39-minimum]
# TODO: Update to 3.13 when linkml and its deps support 3.13
[testenv:gallery-py312-upgraded-optional]
[testenv:gallery-py312-prerelease-optional]
[testenv:gallery-py39-minimum]
[testenv:build] # using tox for this so that we can have a clean build environment
[testenv:wheelinstall] # use with `--installpkg dist/*-none-any.whl`