mirror of
https://github.com/wassname/jupyter_contrib_nbextensions.git
synced 2026-06-26 16:00:43 +08:00
177 lines
4.4 KiB
INI
177 lines
4.4 KiB
INI
# a generative tox configuration, see
|
|
# https://testrun.org/tox/latest/config.html#generative-envlist
|
|
|
|
[tox]
|
|
envlist =
|
|
clean,
|
|
check,
|
|
lint,
|
|
{py27,py34}-notebook{40,41,42,4x},
|
|
report,
|
|
|
|
[testenv]
|
|
basepython =
|
|
pypy: {env:TOXPYTHON:pypy}
|
|
py27: {env:TOXPYTHON:python2.7}
|
|
py33: {env:TOXPYTHON:python3.3}
|
|
py34: {env:TOXPYTHON:python3.4}
|
|
py35: {env:TOXPYTHON:python3.5}
|
|
py36: {env:TOXPYTHON:python3.6}
|
|
{spell}: {env:TOXPYTHON:python2.7}
|
|
{appveyorartifacts,lint,check}: {env:TOXPYTHON:python3}
|
|
{condarecipe}: {env:TOXPYTHON:python3.4}
|
|
{clean,codecov,coveralls,report}: {env:TOXPYTHON:python3}
|
|
{docs,docs_build,docs_linkcheck}: {env:TOXPYTHON:python3}
|
|
{bump,pypi_build,pypi_upload}: {env:TOXPYTHON:python3}
|
|
setenv =
|
|
PYTHONPATH={toxinidir}/tests
|
|
PYTHONUNBUFFERED=yes
|
|
passenv = *
|
|
usedevelop = false
|
|
deps =
|
|
coverage>=4.2
|
|
jupyter_highlight_selected_word>=0.0.5
|
|
jupyter_latex_envs>=1.3.4
|
|
mock
|
|
nose
|
|
notebook40: notebook>=4.0,<4.1
|
|
notebook41: notebook>=4.1,<4.2
|
|
notebook42: notebook>=4.2,<4.3
|
|
notebook43: notebook>=4.3,<4.4
|
|
notebook44: notebook>=4.4,<4.5
|
|
notebook4x: https://github.com/jupyter/notebook/archive/4.x.zip
|
|
notebook50: https://github.com/jupyter/notebook/archive/5.0.0b1.zip
|
|
notebookmaster: https://github.com/jupyter/notebook/archive/master.zip
|
|
notebook: notebook
|
|
commands =
|
|
{posargs:coverage run --source=src -m nose -vv tests}
|
|
|
|
[testenv:check]
|
|
skip_install = true
|
|
deps =
|
|
check-manifest
|
|
docutils
|
|
pygments
|
|
readme-renderer
|
|
commands =
|
|
python setup.py check --strict --metadata --restructuredtext
|
|
check-manifest {toxinidir}
|
|
|
|
[testenv:lint]
|
|
skip_install = true
|
|
deps =
|
|
flake8
|
|
isort
|
|
commands =
|
|
flake8 --max-line-length=120 src tests setup.py
|
|
isort --verbose --check-only --diff --recursive src tests setup.py
|
|
|
|
[testenv:docs]
|
|
deps =
|
|
-r{toxinidir}/docs/requirements.txt
|
|
commands =
|
|
sphinx-build {posargs:-E} -T -b readthedocs docs/source dist/docs
|
|
sphinx-build {posargs:-E} -T -b linkcheck docs/source dist/docs
|
|
|
|
[testenv:docs_build]
|
|
deps =
|
|
-r{toxinidir}/docs/requirements.txt
|
|
commands =
|
|
sphinx-build {posargs:-E} -T -b readthedocs docs/source dist/docs
|
|
|
|
[testenv:docs_linkcheck]
|
|
deps =
|
|
-r{toxinidir}/docs/requirements.txt
|
|
commands =
|
|
sphinx-build {posargs:-E} -T -b linkcheck docs/source dist/docs
|
|
|
|
[testenv:spell]
|
|
skip_install = true
|
|
setenv =
|
|
SPELLCHECK=1
|
|
deps =
|
|
-r{toxinidir}/docs/requirements.txt
|
|
pyenchant
|
|
sphinxcontrib-spelling
|
|
commands =
|
|
sphinx-build -b spelling docs dist/docs
|
|
|
|
[testenv:coveralls]
|
|
skip_install = true
|
|
deps =
|
|
coverage>=4.2
|
|
coveralls
|
|
commands =
|
|
coverage combine --append
|
|
coverage report
|
|
coveralls []
|
|
|
|
[testenv:codecov]
|
|
skip_install = true
|
|
deps =
|
|
coverage>=4.2
|
|
codecov
|
|
commands =
|
|
coverage combine --append
|
|
coverage report
|
|
coverage xml --ignore-errors
|
|
codecov []
|
|
|
|
[testenv:appveyorartifacts]
|
|
skip_install = true
|
|
whitelist_externals = bash
|
|
deps =
|
|
appveyor-artifacts
|
|
coverage>=4.2
|
|
coveralls
|
|
commands =
|
|
appveyor-artifacts --owner-name=jcb91 --repo-name=ipython-notebook-extensions-ynb9f --mangle-coverage download
|
|
; tox doesn't run commands through a shell (makes windows inconsistent)
|
|
; So to get wildcard expansion, run through bash.
|
|
; Travis is the only place this env should be run, so it's ok to use bash.
|
|
bash -c \"coverage combine --append */.coverage\"
|
|
coverage report
|
|
coveralls
|
|
|
|
[testenv:report]
|
|
skip_install = true
|
|
deps = coverage>=4.2
|
|
commands =
|
|
coverage combine --append
|
|
coverage report
|
|
coverage html
|
|
|
|
[testenv:clean]
|
|
skip_install = true
|
|
deps = coverage>=4.2
|
|
commands = coverage erase
|
|
|
|
[testenv:bump]
|
|
skip_install = true
|
|
deps = bumpversion
|
|
whitelist_externals = git
|
|
commands =
|
|
bumpversion {posargs:patch}
|
|
python -c "import configparser as cp, subprocess as sp; b, c = 'bumpversion', cp.ConfigParser(); c.read('.'+b+'.cfg'); v = c[b]['current_version'].strip(); sp.call(['git', 'tag', '-a', v, '-m', v])"
|
|
git describe
|
|
|
|
[testenv:pypi_build]
|
|
skip_install = true
|
|
commands = python setup.py sdist bdist_wheel
|
|
|
|
[testenv:pypi_upload]
|
|
skip_install = true
|
|
whitelist_externals = bash
|
|
deps = twine
|
|
commands = bash -c \"twine upload dist/jupyter_contrib_nbextensions*\"
|
|
|
|
[testenv:condarecipe]
|
|
skip_install = true
|
|
deps =
|
|
; install of conda itself is handled in travis for CI tests
|
|
whitelist_externals =
|
|
conda
|
|
commands =
|
|
conda build conda.recipe
|
|
conda install --use-local jupyter_contrib_nbextensions
|