| 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 import imp | 5 import imp |
| 6 import os | 6 import os |
| 7 import sys | 7 import sys |
| 8 import urllib | 8 import urllib |
| 9 | 9 |
| 10 # Directory path in which to save bootstrap files. | 10 # Directory path in which to save bootstrap files. |
| (...skipping 60 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 71 "loading_measurement": "loading", | 71 "loading_measurement": "loading", |
| 72 "media_measurement": "media", | 72 "media_measurement": "media", |
| 73 "memory_benchmark": "memory", | 73 "memory_benchmark": "memory", |
| 74 "memory_measurement": "memory", | 74 "memory_measurement": "memory", |
| 75 "rasterize_and_record_benchmark": "rasterize_and_record", | 75 "rasterize_and_record_benchmark": "rasterize_and_record", |
| 76 "rasterize_and_record_measurement": "rasterize_and_record", | 76 "rasterize_and_record_measurement": "rasterize_and_record", |
| 77 "robohornetpro": "robohornet_pro", | 77 "robohornetpro": "robohornet_pro", |
| 78 "scrolling_benchmark": "smoothness", | 78 "scrolling_benchmark": "smoothness", |
| 79 "smoothness_benchmark": "smoothness", | 79 "smoothness_benchmark": "smoothness", |
| 80 "smoothness_measurement": "smoothness", | 80 "smoothness_measurement": "smoothness", |
| 81 "startup_benchmark": "startup_warm", | 81 "startup_benchmark": "startup_warm_blank_page", |
| 82 "startup_measurement": "startup_warm", | 82 "startup_measurement": "startup", |
| 83 "tab_switching_measurement": "tab_switching", | 83 "tab_switching_measurement": "tab_switching", |
| 84 } | 84 } |
| 85 | 85 |
| 86 # There are bots that are hard-coded to run some specific named tests. | 86 # There are bots that are hard-coded to run some specific named tests. |
| 87 # Convert these to the current naming conventions by overriding them in the ru
nner. | 87 # Convert these to the current naming conventions by overriding them in the ru
nner. |
| 88 class MeasurementRunner(page_measurement_runner.PageMeasurementRunner): | 88 class MeasurementRunner(page_measurement_runner.PageMeasurementRunner): |
| 89 def GetModernizedTestName(self, arg): | 89 def GetModernizedTestName(self, arg): |
| 90 if arg not in old_benchmark_names: | 90 if arg not in old_benchmark_names: |
| 91 return arg | 91 return arg |
| 92 sys.stderr.write( | 92 sys.stderr.write( |
| 93 'An old name %s was given. Please use %s in the future.\n' % ( | 93 'An old name %s was given. Please use %s in the future.\n' % ( |
| 94 arg, | 94 arg, |
| 95 old_benchmark_names.get(arg))) | 95 old_benchmark_names.get(arg))) |
| 96 return old_benchmark_names[arg] | 96 return old_benchmark_names[arg] |
| 97 | 97 |
| 98 runner = MeasurementRunner() | 98 runner = MeasurementRunner() |
| 99 sys.exit(runner.Run(BASE_DIR, page_set_filenames)) | 99 sys.exit(runner.Run(BASE_DIR, page_set_filenames)) |
| 100 | 100 |
| 101 if __name__ == '__main__': | 101 if __name__ == '__main__': |
| 102 sys.exit(main()) | 102 sys.exit(main()) |
| OLD | NEW |