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

Unified Diff: Tools/Scripts/webkitpy/common/system/systemhost_mock.py

Issue 546613003: Add a new 'format-webkitpy' command that will reformat code to the style guide. (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: remove hack from test/main.py Created 6 years, 3 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 | « Tools/Scripts/webkitpy/common/system/systemhost.py ('k') | Tools/Scripts/webkitpy/formatter/__init__.py » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: Tools/Scripts/webkitpy/common/system/systemhost_mock.py
diff --git a/Tools/Scripts/webkitpy/common/system/systemhost_mock.py b/Tools/Scripts/webkitpy/common/system/systemhost_mock.py
index 12dce4cc952277e3745641a791926b5e6890d686..ef24804a8db8f6179b9097bab07bd731911ec435 100644
--- a/Tools/Scripts/webkitpy/common/system/systemhost_mock.py
+++ b/Tools/Scripts/webkitpy/common/system/systemhost_mock.py
@@ -51,6 +51,7 @@ class MockSystemHost(object):
# FIXME: Should this take pointers to the filesystem and the executive?
self.workspace = MockWorkspace()
+ self.stdin = StringIO()
self.stdout = StringIO()
self.stderr = StringIO()
@@ -60,8 +61,5 @@ class MockSystemHost(object):
def print_(self, *args, **kwargs):
sep = kwargs.get('sep', ' ')
end = kwargs.get('end', '\n')
- file = kwargs.get('file', None)
- stderr = kwargs.get('stderr', False)
-
- file = file or (self.stderr if stderr else self.stdout)
- file.write(sep.join([str(arg) for arg in args]) + end)
+ stream = kwargs.get('stream', self.stdout)
+ stream.write(sep.join([str(arg) for arg in args]) + end)
« no previous file with comments | « Tools/Scripts/webkitpy/common/system/systemhost.py ('k') | Tools/Scripts/webkitpy/formatter/__init__.py » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698