Skip to content

Commit 22f3d30

Browse files
committed
Add tox -e benchmarks
1 parent 9a53c9c commit 22f3d30

File tree

2 files changed

+15
-3
lines changed

2 files changed

+15
-3
lines changed

docs/sphinx/development.rst

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -79,7 +79,7 @@ for some examples.
7979
Since this takes some time, benchmarks are not run with the default test suite,
8080
but has to be enabled like so::
8181

82-
$ pytest --benchmarks
82+
$ tox -e benchmarks
8383

8484

8585
Code

tox.ini

Lines changed: 14 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -75,8 +75,6 @@ description = Reformat python code using ruff (Black, isort, and pyupgrade)
7575
skip_install = true
7676
deps =
7777
ruff
78-
allowlist_externals =
79-
bash
8078
changedir = {toxinidir}
8179
commands =
8280
ruff check --fix nutree tests setup.py
@@ -99,3 +97,17 @@ deps =
9997
commands =
10098
# http://www.sphinx-doc.org/en/master/man/sphinx-build.html
10199
sphinx-build -b html sphinx sphinx-build
100+
101+
[testenv:benchmarks]
102+
description = Run 'pytest --benchmarks' on all Python versions
103+
; envlist = py38, py39, py310, py311, py312
104+
skip_install = true
105+
changedir = {toxinidir}
106+
basepython = py312
107+
; basepython = py39
108+
; basepython = py{38, 39}
109+
; deps =
110+
; pytest
111+
commands =
112+
python -V
113+
pytest -k test_bench -o addopts="" --benchmarks

0 commit comments

Comments
 (0)