forked from DKISTDC/dkist
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathtox.ini
69 lines (65 loc) · 2.67 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
[tox]
envlist = py{39,310,311}{,-devdeps,-oldestdeps,-online},build_docs,codestyle
requires =
setuptools >= 30.3.0
pip >= 21.0.1
#tox-pypi-filter >= 0.12
[testenv]
passenv = CC
setenv =
MPLBACKEND = agg
COLUMNS = 180
PYTEST_COMMAND = pytest {tty:--color=yes} --cov=dkist --cov-config={toxinidir}/setup.cfg --verbose
devdeps: PIP_EXTRA_INDEX_URL = https://pypi.anaconda.org/astropy/simple https://pypi.anaconda.org/scipy-wheels-nightly/simple
extras = tests
commands =
!online: {env:PYTEST_COMMAND} {posargs}
online: {env:PYTEST_COMMAND} --remote-data=any {posargs}
description =
run tests
devdeps: with the latest developer version of key dependencies
oldestdeps: with the oldest supported version of all dependencies
online: that require remote data (as well as the offline ones)
deps =
# Devdeps installs our key dependencies from git to ensure we catch future
# breaking changes before they make it to release
devdeps: astropy>=0.0.dev0
devdeps: numpy>=0.0.dev0
devdeps: scipy>=0.0.dev0
devdeps: matplotlib>=0.0.dev0
devdeps: git+https://github.com/sunpy/sunpy
devdeps: git+https://github.com/sunpy/ndcube
devdeps: git+https://github.com/spacetelescope/gwcs
devdeps: git+https://github.com/asdf-format/asdf
devdeps: git+https://github.com/astropy/asdf-astropy
# Autogenerate oldest dependencies from info in setup.cfg
oldestdeps: minimum_dependencies
# The oldest deps build runs all our tests against the oldest supported
# versions
commands_pre =
oldestdeps: minimum_dependencies dkist --filename requirements-min.txt
# Put the other requirements here to not have pip run more than once
#
# Very new versions of jsonschema raise warnings, but we don't want to
# depend on jsonschema as new asdf (3.0+) does not use it any more.
#
# The newest cryptography releases break globus
oldestdeps: pip install -r requirements-min.txt cryptography<42 jsonschema==4.0.1
pip freeze --all --no-input
[testenv:build_docs]
changedir = docs
extras = docs
description = Invoke sphinx-build to build the HTML docs
commands =
pip freeze --all --no-input
# Disable parallel here due to https://github.com/astropy/astropy/issues/14916
sphinx-build -j 1 --color -W --keep-going -b html -d _build/.doctrees . _build/html {posargs}
python -c 'import pathlib; print("Documentation available under file://\{0\}".format(pathlib.Path(r"{toxinidir}") / "docs" / "_build" / "index.html"))'
[testenv:codestyle]
skip_install = true
description = Run all style and file checks with pre-commit
deps =
pre-commit
commands =
pre-commit install --install-hooks
pre-commit run --all-files {posargs}