-
Notifications
You must be signed in to change notification settings - Fork 2
/
tox.ini
85 lines (76 loc) · 1.83 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
[tox]
minversion = 4.4.3
envlist = py{39,310,311,312}{,-notebook}, lint, coverage, docs
isolated_build = True
[testenv]
package = wheel
wheel_build_env = .pkg
parallel_show_output = True
extras =
test
aer
quimb-all
commands =
pytest {posargs}
[testenv:{,py-,py3-,py39-,py310-,py311-,py312-}aer-only]
extras =
test
aer
[testenv:{,py-,py3-,py39-,py310-,py311-,py312-}quimb-only]
extras =
test
quimb-all
[testenv:style]
extras =
style
commands =
ruff check --fix qiskit_addon_aqc_tensor docs/ test/
nbqa ruff --fix docs/
autoflake --in-place --recursive qiskit_addon_aqc_tensor docs/ test/
black qiskit_addon_aqc_tensor docs/ test/
[testenv:lint]
extras =
lint
commands =
ruff check qiskit_addon_aqc_tensor docs/ test/
nbqa ruff docs/
autoflake --check --quiet --recursive qiskit_addon_aqc_tensor docs/ test/
black --check qiskit_addon_aqc_tensor docs/ test/
mypy qiskit_addon_aqc_tensor --disable-error-code no-redef
reno lint
pylint -rn qiskit_addon_aqc_tensor test/
nbqa pylint -rn --disable=wrong-import-order,wrong-import-position docs/
[testenv:{,py-,py3-,py39-,py310-,py311-,py312-}notebook]
extras =
nbtest
notebook-dependencies
commands =
pytest --nbmake --nbmake-timeout=300 {posargs} docs/ --ignore=docs/_build
[testenv:coverage]
deps =
coverage>=5.5
extras =
test
aer
quimb-all
commands =
coverage3 run --source qiskit_addon_aqc_tensor --parallel-mode -m pytest test/ {posargs}
coverage3 combine
coverage3 html
coverage3 report --fail-under=80 --show-missing
[testenv:docs]
extras =
docs
notebook-dependencies
commands =
sphinx-build -j auto -W -T --keep-going {posargs} docs/ docs/_build/html
passenv =
CI
GITHUB_BASE_REF
GITHUB_REF_NAME
[testenv:docs-clean]
skip_install = true
allowlist_externals =
rm
commands =
rm -rf {toxinidir}/docs/stubs/ {toxinidir}/docs/_build/