Codebase list drms / HEAD tox.ini
HEAD

Tree @HEAD (Download .tar.gz)

tox.ini @HEADraw · history · blame

[tox]
envlist =
    py{38,39,310}{,-online,-sunpy}
    build_docs
    codestyle
isolated_build = true
requires =
    setuptools >=56, !=61.0.0
    pip >= 19.3.1
    tox-pypi-filter >= 0.12

[testenv]
pypi_filter = https://raw.githubusercontent.com/sunpy/sunpy/main/.test_package_pins.txt
# Run the tests in a temporary directory to make sure that we don't import
# drms from the source tree
changedir = .tmp/{envname}
description =
    run tests
    online: that require remote data
    sunpy: run the sunpy jsoc tests to ensure we dont break them
setenv =
    MPLBACKEND = agg
    COLUMNS = 180
    PYTEST_COMMAND = pytest -vvv -s -ra --pyargs drms --cov-report=xml --cov=drms --cov-config={toxinidir}/setup.cfg {toxinidir}/docs
    build_docs,online: HOME = {envtmpdir}
    JSOC_EMAIL = jsoc@sunpy.org
passenv =
    HTTP_PROXY
    HTTPS_PROXY
    NO_PROXY
    CIRCLECI
deps =
    pytest-timeout
    # These are specific extras we use to run the sunpy tests.
    sunpy: git+https://github.com/sunpy/sunpy
    sunpy: beautifulsoup4
    sunpy: pytest-mock
    sunpy: python-dateutil
    sunpy: scipy
    sunpy: tqdm
    sunpy: zeep
extras =
    dev
commands =
    sunpy: pytest -vvv -s -ra --pyargs sunpy.net.jsoc --timeout=120 --remote-data=any {posargs}
    !online: {env:PYTEST_COMMAND} {posargs}
    online: {env:PYTEST_COMMAND} --timeout=120 --remote-data=any --email jsoc@sunpy.org {posargs}

[testenv:build_docs]
changedir = docs
description = Invoke sphinx-build to build the HTML docs
extras = dev
commands =
    sphinx-build -j auto --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]
pypi_filter =
skip_install = true
description = Run all style and file checks with pre-commit
deps =
    pre-commit
commands =
    pre-commit install-hooks
    pre-commit run --verbose --all-files --show-diff-on-failure