blob: 05b3cd0f7eaea97ff17b368f58e3975f743184ac [file] [log] [blame]
[tox]
basepython = py36
minversion = 2.5
skipsdist = true
envlist = shellcheck, yamllint, jjbtest, jjbdeploy
install_command = pip install --force-reinstall {opts} {packages}
deps = -r{toxinidir}/jjb/infra/test-requirements.txt
[testenv:jjbtest]
description = invoke jenkins-job-builder to analyse jjb templates
passenv = *
deps = -r{toxinidir}/jjb/infra/test-requirements.txt
whitelist_externals = bash
commands =
bash -c "jenkins-jobs -l debug --conf {toxinidir}/jjb/global/jenkins_jobs.ini \
--user $JJB_USERNAME --password $JJB_USERTOKEN test --config-xml --recursive {toxinidir}/jjb"
[testenv:jjbdeploy]
description = invoke jenkins-job-builder to deploy jobs from jjb templates
passenv = *
deps = -r{toxinidir}/jjb/infra/test-requirements.txt
whitelist_externals = bash
commands =
bash -c "jenkins-jobs --conf {toxinidir}/jjb/global/jenkins_jobs.ini \
--user $JJB_USERNAME --password $JJB_USERTOKEN update --recursive \
--delete-old --workers 4 {toxinidir}/jjb"
[testenv:yamllint]
description = invoke yamllint to analyse YAML files
deps = -r{toxinidir}/jjb/infra/test-requirements.txt
ignore_outcome=true
whitelist_externals = bash
commands =
bash -c "find {toxinidir} -type f -regex '.*.ya?ml' \
! -regex '.*.tox.*\|.*.venv.*' \
-print0 | xargs -t -n1 -0 yamllint --format standard --strict"
[testenv:shellcheck]
description = invoke shellcheck to analyse bash shell scripts
deps = -r{toxinidir}/jjb/infra/test-requirements.txt
ignore_outcome=true
whitelist_externals = bash
commands =
bash -c "find {toxinidir} -type f -regex '.*.sh' \
! -regex '.*.tox.*\|.*.venv.*' \
-print0 | xargs -t -n1 -0 shellcheck --color=never --source-path={toxinidir} \
--external-sources --format=tty"
# vim: set ts=2 sw=2 ft=ini expandtab: