Add hacking checks

Checking specific mistakes can be automated via hacking rules.

This patch:
 * adds HACKING.rst - list of rules;
 * adds rally.hacking - module for implementation of rules;
 * edits tox.ini, so hacking rules will be checked during pep8 test;
 * adds 3 rules related to mistakes in  `assert_*` methods from `mock`
   library. Also tests, which are failed due to these rules, are fixed.

Closes-Bug: #1305991
Change-Id: I605dd5cfba4eb83d0735e4f9f3ab4e44e149d041
This commit is contained in:
Andrey Kurilin 2014-09-16 23:46:32 +03:00
parent c38e760cd6
commit fa714377e6

View File

@ -45,3 +45,4 @@ exclude=.venv,.git,.tox,dist,doc,*lib/python*,*egg,tools,*rally/verification/ver
[hacking]
import_exceptions = rally.openstack.common.gettextutils._
local-check-factory = rally.hacking.checks.factory