From dae6b82350e0cfb4a8d8003b832b73c1aa063b23 Mon Sep 17 00:00:00 2001 From: cclauss Date: Wed, 12 Jul 2017 07:25:38 +0200 Subject: [PATCH] Add flake8 to testing --- .travis.yml | 10 ++++++++-- 1 file changed, 8 insertions(+), 2 deletions(-) diff --git a/.travis.yml b/.travis.yml index be11cfe..54b6ecd 100644 --- a/.travis.yml +++ b/.travis.yml @@ -13,9 +13,15 @@ matrix: install: # via https://github.com/angr/angr/issues/52 - pip install -I --no-use-wheel capstone - - pip install --upgrade pep8 pytest-cov pytest + - pip install --upgrade pep8 pytest-cov pytest flake8 - pip install -e . +before_script: + # stop the build if there are Python syntax errors or undefined names + - flake8 . --count --select=E901,E999,F821,F822,F823 --show-source --statistics + # exit-zero treats all errors as warnings. The GitHub editor is 127 chars wide + - flake8 . --count --exit-zero --max-complexity=10 --max-line-length=127 --statistics + script: - find . -name \*.py -exec pep8 --ignore=E501 {} \; - - py.test ./tests/ -v --cov=idb \ No newline at end of file + - py.test ./tests/ -v --cov=idb