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

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

Issue 18418010: Check in the thirdparty libs needed for webkitpy. (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: Created 7 years, 5 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 unified diff | Download patch | Annotate | Revision Log
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 24 matching lines...) Expand all
35 import os 35 import os
36 import signal 36 import signal
37 import socket 37 import socket
38 import subprocess 38 import subprocess
39 import sys 39 import sys
40 import time 40 import time
41 41
42 # Import for auto-install 42 # Import for auto-install
43 if sys.platform not in ('cygwin', 'win32'): 43 if sys.platform not in ('cygwin', 'win32'):
44 # FIXME: webpagereplay doesn't work on win32. See https://bugs.webkit.org/sh ow_bug.cgi?id=88279. 44 # FIXME: webpagereplay doesn't work on win32. See https://bugs.webkit.org/sh ow_bug.cgi?id=88279.
45 import webkitpy.thirdparty.autoinstalled.webpagereplay.replay 45 import webkitpy.thirdparty.webpagereplay.replay
46 46
47 from webkitpy.layout_tests.controllers.test_result_writer import TestResultWrite r 47 from webkitpy.layout_tests.controllers.test_result_writer import TestResultWrite r
48 from webkitpy.layout_tests.port.driver import DriverInput 48 from webkitpy.layout_tests.port.driver import DriverInput
49 from webkitpy.layout_tests.port.driver import DriverOutput 49 from webkitpy.layout_tests.port.driver import DriverOutput
50 50
51 DEFAULT_TEST_RUNNER_COUNT = 4 51 DEFAULT_TEST_RUNNER_COUNT = 4
52 52
53 _log = logging.getLogger(__name__) 53 _log = logging.getLogger(__name__)
54 54
55 55
(...skipping 245 matching lines...) Expand 10 before | Expand all | Expand 10 after
301 _log.error(line) 301 _log.error(line)
302 return results if results and not test_failed else None 302 return results if results and not test_failed else None
303 303
304 304
305 class ReplayServer(object): 305 class ReplayServer(object):
306 def __init__(self, archive, record): 306 def __init__(self, archive, record):
307 self._process = None 307 self._process = None
308 308
309 # FIXME: Should error if local proxy isn't set to forward requests to lo calhost:8080 and localhost:8443 309 # FIXME: Should error if local proxy isn't set to forward requests to lo calhost:8080 and localhost:8443
310 310
311 replay_path = webkitpy.thirdparty.autoinstalled.webpagereplay.replay.__f ile__ 311 replay_path = webkitpy.thirdparty.webpagereplay.replay.__file__
312 args = ['python', replay_path, '--no-dns_forwarding', '--port', '8080', '--ssl_port', '8443', '--use_closest_match', '--log_level', 'warning'] 312 args = ['python', replay_path, '--no-dns_forwarding', '--port', '8080', '--ssl_port', '8443', '--use_closest_match', '--log_level', 'warning']
313 if record: 313 if record:
314 args.append('--record') 314 args.append('--record')
315 args.append(archive) 315 args.append(archive)
316 316
317 self._process = subprocess.Popen(args) 317 self._process = subprocess.Popen(args)
318 318
319 def wait_until_ready(self): 319 def wait_until_ready(self):
320 for i in range(0, 3): 320 for i in range(0, 3):
321 try: 321 try:
(...skipping 137 matching lines...) Expand 10 before | Expand all | Expand 10 after
459 (re.compile(r'^inspector/'), ChromiumStylePerfTest), 459 (re.compile(r'^inspector/'), ChromiumStylePerfTest),
460 (re.compile(r'(.+)\.replay$'), ReplayPerfTest), 460 (re.compile(r'(.+)\.replay$'), ReplayPerfTest),
461 ] 461 ]
462 462
463 @classmethod 463 @classmethod
464 def create_perf_test(cls, port, test_name, path, test_runner_count=DEFAULT_T EST_RUNNER_COUNT): 464 def create_perf_test(cls, port, test_name, path, test_runner_count=DEFAULT_T EST_RUNNER_COUNT):
465 for (pattern, test_class) in cls._pattern_map: 465 for (pattern, test_class) in cls._pattern_map:
466 if pattern.match(test_name): 466 if pattern.match(test_name):
467 return test_class(port, test_name, path, test_runner_count) 467 return test_class(port, test_name, path, test_runner_count)
468 return PerfTest(port, test_name, path, test_runner_count) 468 return PerfTest(port, test_name, path, test_runner_count)
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698