Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(502)

Unified Diff: third_party/pylint/pylint/reporters/guireporter.py

Issue 1920403002: [content/test/gpu] Run pylint check of gpu tests in unittest instead of PRESUBMIT (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Update path to LICENSE.txt of logilab/README.chromium Created 4 years, 7 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « third_party/pylint/pylint/reporters/__init__.py ('k') | third_party/pylint/pylint/reporters/html.py » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: third_party/pylint/pylint/reporters/guireporter.py
diff --git a/third_party/pylint/pylint/reporters/guireporter.py b/third_party/pylint/pylint/reporters/guireporter.py
new file mode 100644
index 0000000000000000000000000000000000000000..4ad4ebbf166d06528a31e61d7aa44a728af080fb
--- /dev/null
+++ b/third_party/pylint/pylint/reporters/guireporter.py
@@ -0,0 +1,27 @@
+""" reporter used by gui.py """
+
+import sys
+
+from pylint.interfaces import IReporter
+from pylint.reporters import BaseReporter
+from logilab.common.ureports import TextWriter
+
+
+class GUIReporter(BaseReporter):
+ """saves messages"""
+
+ __implements__ = IReporter
+ extension = ''
+
+ def __init__(self, gui, output=sys.stdout):
+ """init"""
+ BaseReporter.__init__(self, output)
+ self.gui = gui
+
+ def handle_message(self, msg):
+ """manage message of different type and in the context of path"""
+ self.gui.msg_queue.put(msg)
+
+ def _display(self, layout):
+ """launch layouts display"""
+ TextWriter().format(layout, self.out)
« no previous file with comments | « third_party/pylint/pylint/reporters/__init__.py ('k') | third_party/pylint/pylint/reporters/html.py » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698