From c756896e904c0ca48236bd4a9c08dff7fa1b4e86 Mon Sep 17 00:00:00 2001 From: Jeremy Liu Date: Thu, 24 Nov 2016 14:25:42 +0800 Subject: Add HACKING.rst and hacking test case. Currently, we have hacking check in kolla, but no place where we can define hacking check rules. This patch adds HACKING.rst file for that. And also add test cases for hacking. Change-Id: I87f8768138d91bf6a5a1db91d37392f794f3f0ba --- kolla/hacking/checks.py | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'kolla/hacking') diff --git a/kolla/hacking/checks.py b/kolla/hacking/checks.py index 9eba06c01..593b8bf83 100644 --- a/kolla/hacking/checks.py +++ b/kolla/hacking/checks.py @@ -21,16 +21,16 @@ def no_log_warn(logical_line): Deprecated LOG.warn(), instead use LOG.warning https://bugs.launchpad.net/senlin/+bug/1508442 - N352 + K302 """ - msg = ("N352: LOG.warn is deprecated, please use LOG.warning!") + msg = ("K302: LOG.warn is deprecated, please use LOG.warning!") if "LOG.warn(" in logical_line: yield (0, msg) def no_mutable_default_args(logical_line): - msg = "N301: Method's default argument shouldn't be mutable!" + msg = "K301: Method's default argument shouldn't be mutable!" if mutable_default_args.match(logical_line): yield (0, msg) -- cgit v1.2.3