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

Side by Side Diff: third_party/WebKit/Tools/Scripts/webkitpy/performance_tests/perftest.py

Issue 2469153002: Remove remaining unused imports in webkitpy. (Closed)
Patch Set: Remove unused imports in webkitpy. Created 4 years, 1 month 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 unified diff | Download patch
OLDNEW
1 # Copyright (C) 2012 Google Inc. All rights reserved. 1 # Copyright (C) 2012 Google Inc. All rights reserved.
2 # Copyright (C) 2012 Zoltan Horvath, Adobe Systems Incorporated. All rights rese rved. 2 # Copyright (C) 2012 Zoltan Horvath, Adobe Systems Incorporated. All rights rese rved.
3 # 3 #
4 # Redistribution and use in source and binary forms, with or without 4 # Redistribution and use in source and binary forms, with or without
5 # modification, are permitted provided that the following conditions are 5 # modification, are permitted provided that the following conditions are
6 # met: 6 # met:
7 # 7 #
8 # * Redistributions of source code must retain the above copyright 8 # * Redistributions of source code must retain the above copyright
9 # notice, this list of conditions and the following disclaimer. 9 # notice, this list of conditions and the following disclaimer.
10 # * Redistributions in binary form must reproduce the above 10 # * Redistributions in binary form must reproduce the above
(...skipping 10 matching lines...) Expand all
21 # A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT 21 # A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
22 # OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, 22 # OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
23 # SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT 23 # SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
24 # LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, 24 # LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
25 # DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY 25 # DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
26 # THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT 26 # THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
27 # (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE 27 # (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
28 # OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. 28 # OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
29 29
30 30
31 import errno
32 import logging 31 import logging
33 import math 32 import math
34 import re 33 import re
35 import signal
36 34
37 from webkitpy.layout_tests.controllers.test_result_writer import TestResultWrite r
38 from webkitpy.layout_tests.port.driver import DriverInput 35 from webkitpy.layout_tests.port.driver import DriverInput
39 from webkitpy.layout_tests.port.driver import DriverOutput
40 36
41 DEFAULT_TEST_RUNNER_COUNT = 4 37 DEFAULT_TEST_RUNNER_COUNT = 4
42 38
43 _log = logging.getLogger(__name__) 39 _log = logging.getLogger(__name__)
44 40
45 41
46 class PerfTestMetric(object): 42 class PerfTestMetric(object):
47 43
48 def __init__(self, metric, unit=None, iterations=None): 44 def __init__(self, metric, unit=None, iterations=None):
49 # FIXME: Fix runner.js to report correct metric names 45 # FIXME: Fix runner.js to report correct metric names
(...skipping 263 matching lines...) Expand 10 before | Expand all | Expand 10 after
313 (re.compile(r'^Dromaeo/'), SingleProcessPerfTest), 309 (re.compile(r'^Dromaeo/'), SingleProcessPerfTest),
314 (re.compile(r'^inspector/'), ChromiumStylePerfTest), 310 (re.compile(r'^inspector/'), ChromiumStylePerfTest),
315 ] 311 ]
316 312
317 @classmethod 313 @classmethod
318 def create_perf_test(cls, port, test_name, path, test_runner_count=DEFAULT_T EST_RUNNER_COUNT): 314 def create_perf_test(cls, port, test_name, path, test_runner_count=DEFAULT_T EST_RUNNER_COUNT):
319 for (pattern, test_class) in cls._pattern_map: 315 for (pattern, test_class) in cls._pattern_map:
320 if pattern.match(test_name): 316 if pattern.match(test_name):
321 return test_class(port, test_name, path, test_runner_count) 317 return test_class(port, test_name, path, test_runner_count)
322 return PerfTest(port, test_name, path, test_runner_count) 318 return PerfTest(port, test_name, path, test_runner_count)
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698