robertpeteuil/aws-shortcuts

View on GitHub
tox.ini

Summary

Maintainability
Test Coverage
# tox testing configuration

[tox]
envlist = py27,py34,py35,py36,flake8,bandit,readme
skip_missing_interpreters=true

[testenv]
deps =
    mock
    pytest
    coverage
commands =
    coverage run --source awss -m py.test

# Linters
[testenv:flake8]
basepython = python3.5
skip_install = true
deps =
    radon <= 1.4.2
    flake8 <= 3.0.4
commands =
    flake8 awss/ test/ setup.py
    flake8 awss --radon-max-cc=5

[testenv:pylint]
basepython = python3.5
skip_install = true
deps =
    pyflakes <= 0.8.1
    pylint <= 1.71
commands =
    pylint awss

# Security Linter
[testenv:bandit]
basepython = python2.7
skip_install = true
deps =
    bandit <= 1.4.0
commands =
    bandit awss -r --ini tox.ini

[testenv:linters]
basepython = python3.5
skip_install = true
deps =
    {[testenv:flake8]deps}
    {[testenv:pylint]deps}
    {[testenv:bandit]deps}
commands =
    {[testenv:flake8]commands}
    {[testenv:pylint]commands}
    {[testenv:bandit]commands}

# DOC TESTS
[testenv:readme]
basepython = python2.7
skip_install = true
deps =
    readme_renderer
    doc8 <= 0.8.0
commands =
    python setup.py check -m -r -s
    doc8 README.rst

# RELEASE tooling
[testenv:build]
basepython = python2.7
skip_install = true
deps =
    wheel
    setuptools
commands =
    python setup.py -q sdist bdist_wheel

[testenv:release]
basepython = python2.7
skip_install = true
deps =
    {[testenv:build]deps}
    twine >= 1.5.0
commands =
    {[testenv:build]commands}
    twine upload --skip-existing dist/*

[flake8]
ignore = D203,H301,H306
exclude = .tox,.git,*.pyc,.cache,.eggs,*.egg,build,dist,test.py,zref,__pycache__

[pytest]
python_files = test_*.py
norecursedirs = .**tox** .git .* *.egg* old docs dist build

[doc8]
ignore=D001

[pydocstyle]
ignore = D400

[bandit]
exclude: /test
tests: B101,B102,B103,B104,B105,B106,B107,B108,B109,B110,B111,B112,B201,B301,B302,B303,B304,B305,B306,B308,B309,B310,B311,B312,B313,B314,B315,B316,B317,B318,B319,B320,B321,B322,B401,B402,B403,B405,B406,B407,B408,B409,B410,B411,B412,B501,B502,B503,B504,B505,B506,B601,B603,B604,B605,B606,B607,B608,B609,B701,B702