2021-07-29 14:00:20 -04:00
|
|
|
[tox]
|
|
|
|
# required because we use pyproject.toml
|
|
|
|
isolated_build = true
|
2021-09-22 13:47:37 -04:00
|
|
|
envlist = py37, py38, py39, lint, checkdeps, pytest
|
2021-07-29 14:00:20 -04:00
|
|
|
# only checks python versions installed locally
|
|
|
|
skip_missing_interpreters = true
|
2021-08-02 12:16:38 -04:00
|
|
|
|
|
|
|
[testenv:lint]
|
|
|
|
# lints python code in src and tests
|
|
|
|
deps = -rrequirements.txt
|
2022-01-05 15:58:24 -05:00
|
|
|
# These are "external" because they are dev dependencies that not in
|
|
|
|
# "requirements.txt" and therefore not installed in this env, but they will be
|
|
|
|
# available where this is being run. See:
|
|
|
|
# https://stackoverflow.com/questions/47642747/tox-warningtest-command-found-but-not-installed-in-testenv
|
|
|
|
allowlist_externals = black
|
|
|
|
flake8
|
|
|
|
pylint
|
2021-08-05 15:35:54 -04:00
|
|
|
commands = black data_pipeline
|
|
|
|
flake8 data_pipeline
|
2022-01-05 15:58:24 -05:00
|
|
|
# Ignore tests this lint check because test dependencies are not installed here.
|
|
|
|
pylint data_pipeline --ignore tests
|
2021-08-02 12:16:38 -04:00
|
|
|
|
|
|
|
[testenv:checkdeps]
|
|
|
|
# checks the dependencies for security vulnerabilities and open source licenses
|
|
|
|
deps = -rrequirements.txt
|
2022-01-05 15:58:24 -05:00
|
|
|
# These are "external" because they are dev dependencies that not in
|
|
|
|
# "requirements.txt" and therefore not installed in this env, but they will be
|
|
|
|
# available where this is being run. See:
|
|
|
|
# https://stackoverflow.com/questions/47642747/tox-warningtest-command-found-but-not-installed-in-testenv
|
|
|
|
allowlist_externals = safety
|
|
|
|
liccheck
|
2021-08-02 12:16:38 -04:00
|
|
|
commands = safety check
|
|
|
|
liccheck
|
2021-09-22 13:47:37 -04:00
|
|
|
|
|
|
|
[testenv:pytest]
|
|
|
|
# Run tests
|
|
|
|
deps = pytest
|
2022-01-05 15:58:24 -05:00
|
|
|
commands = pytest
|