Paver: pep8/pylint violations limit switch. Fail if limit is breached.

This adds the -l switch, wherein a violations limit is passed in. For
example:
  paver run_pep8 -l 700

Will fail if more than 700 violations are found.

By default, this limit is not enforced (i.e. if the -l switch
is not passed into the command, then a limit will not be put
into effect for that run)
This commit is contained in:
Ben Patterson
2014-09-09 08:15:45 -04:00
parent cd1a4d1d0b
commit 1f196523f3
4 changed files with 104 additions and 4 deletions

View File

@@ -103,8 +103,8 @@ SHARD=${SHARD:="all"}
case "$TEST_SUITE" in
"quality")
paver run_pep8 > pep8.log || { cat pep8.log ; exit 1; }
paver run_pylint > pylint.log || { cat pylint.log; exit 1; }
paver run_pep8 -l 725 > pep8.log || { cat pep8.log; EXIT=1; }
paver run_pylint -l 4800 > pylint.log || { cat pylint.log; EXIT=1; }
paver run_quality
# Need to create an empty test result so the post-build
@@ -116,6 +116,7 @@ case "$TEST_SUITE" in
<testcase classname="quality" name="quality" time="0.604"></testcase>
</testsuite>
END
exit $EXIT
;;
"unit")