diff options
author | Simon Glass <sjg@chromium.org> | 2020-06-14 10:54:06 -0600 |
---|---|---|
committer | Simon Glass <sjg@chromium.org> | 2020-07-09 18:57:22 -0600 |
commit | 89fb8b75bce61c53867f80392cdef9cfc5dbc9cd (patch) | |
tree | 07bc1082015c019f5f0b8ce9059c4082dde2c97a /tools/patman/test_checkpatch.py | |
parent | 4148c20f533d908a4255c134601b335322a0d38f (diff) |
patman: Decode output from the '--show-types' option
Collect the 'checkpatch type' from each error, warning and check. Provide
this to patman and update the uclass test to use it.
Signed-off-by: Simon Glass <sjg@chromium.org>
Diffstat (limited to 'tools/patman/test_checkpatch.py')
-rw-r--r-- | tools/patman/test_checkpatch.py | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/tools/patman/test_checkpatch.py b/tools/patman/test_checkpatch.py index e841b9abcab..7f40133b33c 100644 --- a/tools/patman/test_checkpatch.py +++ b/tools/patman/test_checkpatch.py @@ -82,7 +82,7 @@ Signed-off-by: Simon Glass <sjg@chromium.org> return inname def run_checkpatch(self): - return checkpatch.CheckPatch(self.get_patch()) + return checkpatch.CheckPatch(self.get_patch(), show_types=True) class TestPatch(unittest.TestCase): @@ -355,7 +355,7 @@ index 0000000..2234c87 result = pm.run_checkpatch() self.assertEqual(result.warnings, 1) self.assertEqual(len(result.problems), 1) - self.assertIn('Possible new uclass', result.problems[0]['msg']) + self.assertIn('NEW_UCLASS', result.problems[0]['cptype']) if __name__ == "__main__": |