From 8979414153d89e0f67236aedbf5fffb128b1629b Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Mois=C3=A9s=20Guimar=C3=A3es=20de=20Medeiros?= Date: Wed, 22 Jul 2020 15:49:58 +0200 Subject: [PATCH] Add pre-commit to pep8 gate MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Flake8 is covered in the pre-commit hooks Change-Id: I0fc88f0dd641b82c5a3456d687c5958d94667eb0 Signed-off-by: Moisés Guimarães de Medeiros --- test-requirements.txt | 1 + tox.ini | 8 +------- 2 files changed, 2 insertions(+), 7 deletions(-) diff --git a/test-requirements.txt b/test-requirements.txt index 36132d52..307f53c6 100644 --- a/test-requirements.txt +++ b/test-requirements.txt @@ -7,6 +7,7 @@ pifpaf>=0.10.0 # Apache-2.0 # Bandit security code scanner bandit>=1.6.0,<1.7.0 # Apache-2.0 stestr>=2.0.0 # Apache-2.0 +pre-commit>=2.6.0 # MIT python-memcached>=1.56 # PSF pymongo!=3.1,>=3.0.2 # Apache-2.0 etcd3gw>=0.2.0 # Apache-2.0 diff --git a/tox.ini b/tox.ini index 278f4315..d3be70c0 100644 --- a/tox.ini +++ b/tox.ini @@ -24,16 +24,10 @@ commands = [testenv:pep8] deps = {[testenv]deps} commands = - flake8 + pre-commit run -a # Run security linter bandit -r oslo_cache -x tests -n5 -[testenv:pre-commit] -deps = - pre-commit -commands = - pre-commit run --from-ref HEAD^ --to-ref HEAD - [testenv:venv] commands = {posargs}