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

Unified Diff: Tools/Scripts/webkitpy/layout_tests/controllers/layout_test_finder.py

Issue 546133003: Reformat webkitpy.layout_tests w/ format-webkitpy. (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: 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
Index: Tools/Scripts/webkitpy/layout_tests/controllers/layout_test_finder.py
diff --git a/Tools/Scripts/webkitpy/layout_tests/controllers/layout_test_finder.py b/Tools/Scripts/webkitpy/layout_tests/controllers/layout_test_finder.py
index 391b6fa9d335e299025586f45b0675a5b4ffa91a..6440dadf20c3965e22358f39222eae11e65ec831 100644
--- a/Tools/Scripts/webkitpy/layout_tests/controllers/layout_test_finder.py
+++ b/Tools/Scripts/webkitpy/layout_tests/controllers/layout_test_finder.py
@@ -37,6 +37,7 @@ _log = logging.getLogger(__name__)
class LayoutTestFinder(object):
+
def __init__(self, port, options):
self._port = port
self._options = options
@@ -46,7 +47,10 @@ class LayoutTestFinder(object):
def find_tests(self, options, args):
paths = self._strip_test_dir_prefixes(args)
if options.test_list:
- paths += self._strip_test_dir_prefixes(self._read_test_names_from_file(options.test_list, self._port.TEST_PATH_SEPARATOR))
+ paths += self._strip_test_dir_prefixes(
+ self._read_test_names_from_file(
+ options.test_list,
+ self._port.TEST_PATH_SEPARATOR))
test_files = self._port.tests(paths)
return (paths, test_files)
@@ -74,7 +78,7 @@ class LayoutTestFinder(object):
line = self._strip_comments(line)
if line:
tests.append(line)
- except IOError, e:
+ except IOError as e:
if e.errno == errno.ENOENT:
_log.critical('')
_log.critical('--test-list file "%s" not found' % file)
@@ -120,7 +124,7 @@ class LayoutTestFinder(object):
# just grab a subset of the non-skipped tests.
chunk_value = self._options.run_chunk or self._options.run_part
try:
- (chunk_num, chunk_len) = chunk_value.split(":")
+ (chunk_num, chunk_len) = chunk_value.split(':')
chunk_num = int(chunk_num)
assert(chunk_num >= 0)
test_size = int(chunk_len)

Powered by Google App Engine
This is Rietveld 408576698