From 019c7d574487db82271906651a69dfefec4ff45b Mon Sep 17 00:00:00 2001 From: "ChangBo Guo(gcb)" Date: Thu, 7 Dec 2017 13:55:56 +0800 Subject: [PATCH] Add bandit to pep8 job Add the bandit security scanner to the pep8 job. Change-Id: I1bd306757a04e6c81b2717c656f71a9e6c9d0d32 --- test-requirements.txt | 3 +++ tox.ini | 7 ++++++- 2 files changed, 9 insertions(+), 1 deletion(-) diff --git a/test-requirements.txt b/test-requirements.txt index fbbc1c4..7cf5e3d 100644 --- a/test-requirements.txt +++ b/test-requirements.txt @@ -14,3 +14,6 @@ oslotest>=1.10.0 # Apache-2.0 oslo.i18n>=3.15.3 # Apache-2.0 coverage!=4.4,>=4.0 # Apache-2.0 reno>=2.5.0 # Apache-2.0 + +# Bandit security code scanner +bandit>=1.1.0 # Apache-2.0 diff --git a/tox.ini b/tox.ini index 33fb067..d4d99f7 100644 --- a/tox.ini +++ b/tox.ini @@ -11,7 +11,12 @@ deps = commands = python setup.py testr --slowest --testr-args='{posargs}' [testenv:pep8] -commands = flake8 +deps = + -r{toxinidir}/test-requirements.txt +commands = + flake8 + # Run security linter + bandit -r oslo_serialization tests -n5 [testenv:venv] commands = {posargs}