| OLD | NEW |
| 1 #!/usr/bin/env python | 1 #!/usr/bin/env python |
| 2 # Copyright (c) 2012 The Chromium Authors. All rights reserved. | 2 # Copyright (c) 2012 The Chromium Authors. All rights reserved. |
| 3 # Use of this source code is governed by a BSD-style license that can be | 3 # Use of this source code is governed by a BSD-style license that can be |
| 4 # found in the LICENSE file. | 4 # found in the LICENSE file. |
| 5 | 5 |
| 6 """Basic pyauto performance tests. | 6 """Basic pyauto performance tests. |
| 7 | 7 |
| 8 For tests that need to be run for multiple iterations (e.g., so that average | 8 For tests that need to be run for multiple iterations (e.g., so that average |
| 9 and standard deviation values can be reported), the default number of iterations | 9 and standard deviation values can be reported), the default number of iterations |
| 10 run for each of these tests is specified by |_DEFAULT_NUM_ITERATIONS|. | 10 run for each of these tests is specified by |_DEFAULT_NUM_ITERATIONS|. |
| (...skipping 2284 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 2295 WEBPAGEREPLAY_HTTP_PORT, | 2295 WEBPAGEREPLAY_HTTP_PORT, |
| 2296 WEBPAGEREPLAY_HTTPS_PORT) + [ | 2296 WEBPAGEREPLAY_HTTPS_PORT) + [ |
| 2297 '--log-level=0', | 2297 '--log-level=0', |
| 2298 '--disable-background-networking', | 2298 '--disable-background-networking', |
| 2299 '--enable-experimental-extension-apis', | 2299 '--enable-experimental-extension-apis', |
| 2300 '--enable-logging', | 2300 '--enable-logging', |
| 2301 '--enable-benchmarking', | 2301 '--enable-benchmarking', |
| 2302 '--enable-net-benchmarking', | 2302 '--enable-net-benchmarking', |
| 2303 '--metrics-recording-only', | 2303 '--metrics-recording-only', |
| 2304 '--activate-on-launch', | 2304 '--activate-on-launch', |
| 2305 '--no-first-run', | 2305 '--skip-first-run', |
| 2306 '--no-proxy-server', | 2306 '--no-proxy-server', |
| 2307 ] | 2307 ] |
| 2308 | 2308 |
| 2309 @classmethod | 2309 @classmethod |
| 2310 def Path(cls, key, **kwargs): | 2310 def Path(cls, key, **kwargs): |
| 2311 return FormatChromePath(cls._PATHS[key], **kwargs) | 2311 return FormatChromePath(cls._PATHS[key], **kwargs) |
| 2312 | 2312 |
| 2313 @classmethod | 2313 @classmethod |
| 2314 def ReplayServer(cls, test_name, replay_options=None): | 2314 def ReplayServer(cls, test_name, replay_options=None): |
| 2315 archive_path = cls.Path('archive', test_name=test_name) | 2315 archive_path = cls.Path('archive', test_name=test_name) |
| (...skipping 378 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 2694 """Identifies the port number to which the server is currently bound. | 2694 """Identifies the port number to which the server is currently bound. |
| 2695 | 2695 |
| 2696 Returns: | 2696 Returns: |
| 2697 The numeric port number to which the server is currently bound. | 2697 The numeric port number to which the server is currently bound. |
| 2698 """ | 2698 """ |
| 2699 return self._server.server_address[1] | 2699 return self._server.server_address[1] |
| 2700 | 2700 |
| 2701 | 2701 |
| 2702 if __name__ == '__main__': | 2702 if __name__ == '__main__': |
| 2703 pyauto_functional.Main() | 2703 pyauto_functional.Main() |
| OLD | NEW |