Merge "Cap bashate and fix linters tests"
This commit is contained in:
commit
f60bd1061d
@ -857,7 +857,7 @@ def _extra_config(user_defined_config, base_dir):
|
|||||||
|
|
||||||
|
|
||||||
def _check_config_settings(cidr_networks, config, container_skel):
|
def _check_config_settings(cidr_networks, config, container_skel):
|
||||||
""" check preciseness of config settings
|
"""check preciseness of config settings
|
||||||
|
|
||||||
:param cidr_networks: ``dict`` cidr_networks from config
|
:param cidr_networks: ``dict`` cidr_networks from config
|
||||||
:param config: ``dict`` User defined information
|
:param config: ``dict`` User defined information
|
||||||
|
@ -1,10 +1,11 @@
|
|||||||
ansible-lint>=2.0.3
|
ansible>1.9,<2.0
|
||||||
|
ansible-lint>=2.0.3,<=2.3.6
|
||||||
|
bashate==0.5.0 # Apache-2.0
|
||||||
flake8==2.2.4
|
flake8==2.2.4
|
||||||
hacking>=0.10.0,<0.11
|
hacking>=0.10.0,<0.11
|
||||||
|
mccabe==0.2.1 # capped for flake8
|
||||||
pep8==1.5.7
|
pep8==1.5.7
|
||||||
pyflakes==0.8.1
|
pyflakes==0.8.1
|
||||||
mccabe==0.2.1 # capped for flake8
|
|
||||||
bashate>=0.2 # Apache-2.0
|
|
||||||
|
|
||||||
# this is required for the docs build jobs
|
# this is required for the docs build jobs
|
||||||
sphinx!=1.2.0,!=1.3b1,<1.3,>=1.1.2
|
sphinx!=1.2.0,!=1.3b1,<1.3,>=1.1.2
|
||||||
|
20
tox.ini
20
tox.ini
@ -8,6 +8,7 @@ usedevelop = True
|
|||||||
install_command = pip install -U {opts} {packages}
|
install_command = pip install -U {opts} {packages}
|
||||||
setenv = VIRTUAL_ENV={envdir}
|
setenv = VIRTUAL_ENV={envdir}
|
||||||
deps = -r{toxinidir}/test-requirements.txt
|
deps = -r{toxinidir}/test-requirements.txt
|
||||||
|
whitelist_externals = bash
|
||||||
|
|
||||||
[testenv:releasenotes]
|
[testenv:releasenotes]
|
||||||
commands = sphinx-build -a -E -W -d releasenotes/build/doctrees -b html releasenotes/source releasenotes/build/html
|
commands = sphinx-build -a -E -W -d releasenotes/build/doctrees -b html releasenotes/source releasenotes/build/html
|
||||||
@ -23,8 +24,6 @@ commands = {posargs}
|
|||||||
|
|
||||||
# Run hacking/flake8 check for all python files
|
# Run hacking/flake8 check for all python files
|
||||||
[testenv:pep8]
|
[testenv:pep8]
|
||||||
deps = flake8
|
|
||||||
whitelist_externals = bash
|
|
||||||
commands =
|
commands =
|
||||||
bash -c "grep -Irl \
|
bash -c "grep -Irl \
|
||||||
-e '!/usr/bin/env python' \
|
-e '!/usr/bin/env python' \
|
||||||
@ -48,9 +47,6 @@ commands =
|
|||||||
ignore=F403,H303
|
ignore=F403,H303
|
||||||
|
|
||||||
[testenv:bashate]
|
[testenv:bashate]
|
||||||
deps =
|
|
||||||
bashate
|
|
||||||
whitelist_externals = bash
|
|
||||||
commands =
|
commands =
|
||||||
# Run bashate check for all bash scripts
|
# Run bashate check for all bash scripts
|
||||||
# Ignores the following rules:
|
# Ignores the following rules:
|
||||||
@ -67,18 +63,11 @@ commands =
|
|||||||
{toxinidir} | xargs bashate --error . --verbose --ignore=E003,E006,E040"
|
{toxinidir} | xargs bashate --error . --verbose --ignore=E003,E006,E040"
|
||||||
|
|
||||||
[testenv:ansible-lint]
|
[testenv:ansible-lint]
|
||||||
deps =
|
|
||||||
ansible>1.9,<2.0
|
|
||||||
ansible-lint
|
|
||||||
whitelist_externals = bash
|
|
||||||
commands =
|
commands =
|
||||||
# Perform an Ansible lint check
|
# Perform an Ansible lint check
|
||||||
bash -c "ansible-lint {toxinidir}/playbooks/*.yml"
|
bash -c "ansible-lint {toxinidir}/playbooks/*.yml"
|
||||||
|
|
||||||
[testenv:ansible-syntax]
|
[testenv:ansible-syntax]
|
||||||
deps =
|
|
||||||
ansible>1.9,<2.0
|
|
||||||
whitelist_externals = bash
|
|
||||||
commands =
|
commands =
|
||||||
# Perform an Ansible syntax check
|
# Perform an Ansible syntax check
|
||||||
bash -c "mkdir -p {envtmpdir}/ansible; \
|
bash -c "mkdir -p {envtmpdir}/ansible; \
|
||||||
@ -101,13 +90,6 @@ commands =
|
|||||||
{toxinidir}/playbooks/*.yml"
|
{toxinidir}/playbooks/*.yml"
|
||||||
|
|
||||||
[testenv:linters]
|
[testenv:linters]
|
||||||
deps =
|
|
||||||
{[testenv:pep8]deps}
|
|
||||||
{[testenv:bashate]deps}
|
|
||||||
{[testenv:ansible-lint]deps}
|
|
||||||
# note that the ansible-syntax deps are omitted on purpose as the
|
|
||||||
# ansible-lint env contains duplicate items in its dep list
|
|
||||||
whitelist_externals = bash
|
|
||||||
commands =
|
commands =
|
||||||
{[testenv:pep8]commands}
|
{[testenv:pep8]commands}
|
||||||
{[testenv:bashate]commands}
|
{[testenv:bashate]commands}
|
||||||
|
Loading…
x
Reference in New Issue
Block a user