# Tox (http://tox.testrun.org/) 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" from this directory. [tox] skip_missing_interpreters = True envlist = py36, py37, py38, py39, pypy3, defusedxml, {py37}-nolxml, {py37}-lxml, {py37}-keep_vba, nopillow, xfail, pandas, numpy doc, doctest, [testenv] passenv = LANG setenv = PIP_PREFER_BINARY = True commands = {envbindir}/pytest {posargs} deps = pytest lxml pillow pandas: pandas [testenv:pypy] setenv = OPENPYXL_LXML = False [testenv:pypy3] setenv = basepython = pypy37 OPENPYXL_LXML = False [testenv:doc] changedir = doc setenv = APIDOC=True deps = lxml sphinx pandas commands = sphinx-build -qb html -d {envtmpdir}/doctrees . {envtmpdir}/html [testenv:doctest] depends = doc changedir = doc deps = lxml sphinx pillow pandas commands = sphinx-build -qb doctest -d {envtmpdir}/doctrees . {envtmpdir}/doctest [testenv:lxml] commands = pytest {posargs} openpyxl/tests/test_backend.py [testenv:nolxml] setenv = OPENPYXL_LXML = False commands = py.test {posargs} [testenv:defusedxml] deps = {[testenv]deps} defusedxml setenv = OPENPYXL_LXML = False commands = pytest -xrf openpyxl/xml [testenv:keep_vba] setenv = OPENPYXL_KEEP_VBA = True commands = py.test {posargs} [testenv:nopillow] commands = pytest {posargs} openpyxl/drawing/tests/test_image.py::TestImage::test_import [testenv:xfail] commands = pytest {posargs} -rx -m xfail openpyxl [testenv:pandas] deps = {[testenv]deps} pandas commands = pytest {posargs} -m pandas_required openpyxl [testenv:numpy] deps = {[testenv]deps} numpy commands = pytest {posargs} -m numpy_required openpyxl [testenv:flakes] deps = {[testenv]deps} pytest-flakes commands = pytest --flakes [testenv:memory] deps = pytest psutil memory_profiler commands = pytest -s openpyxl/benchmarks/memory.py [testenv:cov] passenv = COVERALLS_REPO_TOKEN GIT_* deps = {[testenv]deps} pillow pandas pytest-cov coveralls commands = pytest -qq --cov=openpyxl --cov-report=term-missing coveralls