Hacking rule to check i18n usage

* Detect neutron.i18n import (neutron._i18n is recommended)
* Check builtins _ usage
* 'builtins = _' in tox.ini is no longer required.
* Introduce hacking rule doctest framework.
  Newly added check_builtins_gettext() hacking check takes
  token as argument. It is not a good idea to pass a tokenized
  line manually. Instead it is reasonable to use docstring based
  tests used in hacking repo.

Change-Id: Ib7464658fc4c8a6f1b03af6ab46f0bd3ee0bfb18
This commit is contained in:
Akihiro Motoki 2016-01-26 10:52:47 +09:00 committed by Henry Gessau
parent f93391a26a
commit 7be47f537d
1 changed files with 1 additions and 0 deletions

View File

@ -25,6 +25,7 @@ from sqlalchemy.orm import exc as sa_exc
from neutron_lib import constants as lib_consts
from neutron._i18n import _
from neutron.api.v2 import attributes as attr
from neutron.common import exceptions as n_exc
from neutron.db import address_scope_db