OLD | NEW |
1 #!/usr/bin/env python | 1 #!/usr/bin/env python |
2 # Copyright (c) 2013 The Chromium Authors. All rights reserved. | 2 # Copyright (c) 2013 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 import collections | 6 import collections |
7 import glob | 7 import glob |
8 import hashlib | 8 import hashlib |
9 import multiprocessing | 9 import multiprocessing |
10 import os | 10 import os |
(...skipping 232 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
243 # TODO(dpranke): Remove this block after | 243 # TODO(dpranke): Remove this block after |
244 # https://codereview.chromium.org/12927002/ lands. | 244 # https://codereview.chromium.org/12927002/ lands. |
245 for f in options.factory_properties.get('additional_expectations_files', []): | 245 for f in options.factory_properties.get('additional_expectations_files', []): |
246 cmd_args.extend( | 246 cmd_args.extend( |
247 ['--additional-expectations=%s' % os.path.join(CHROME_SRC_DIR, *f)]) | 247 ['--additional-expectations=%s' % os.path.join(CHROME_SRC_DIR, *f)]) |
248 | 248 |
249 RunCmd(['webkit/tools/layout_tests/run_webkit_tests.py'] + cmd_args) | 249 RunCmd(['webkit/tools/layout_tests/run_webkit_tests.py'] + cmd_args) |
250 | 250 |
251 if options.factory_properties.get('archive_webkit_results', False): | 251 if options.factory_properties.get('archive_webkit_results', False): |
252 bb_annotations.PrintNamedStep('archive_webkit_results') | 252 bb_annotations.PrintNamedStep('archive_webkit_results') |
| 253 base = 'https://storage.googleapis.com/chromium-layout-test-archives' |
| 254 builder_name = options.build_properties.get('buildername', '') |
| 255 build_number = str(options.build_properties.get('buildnumber', '')) |
| 256 bb_annotations.PrintLink('results', |
| 257 '%s/%s/%s/layout-test-results/results.html' % (base, builder_name, |
| 258 build_number)) |
| 259 bb_annotations.PrintLink('(zip)', |
| 260 '%s/%s/%s/layout-test-results.zip' % (base, builder_name, |
| 261 build_number)) |
253 gs_bucket = 'gs://chromium-layout-test-archives' | 262 gs_bucket = 'gs://chromium-layout-test-archives' |
254 RunCmd([os.path.join(SLAVE_SCRIPTS_DIR, 'chromium', | 263 RunCmd([os.path.join(SLAVE_SCRIPTS_DIR, 'chromium', |
255 'archive_layout_test_results.py'), | 264 'archive_layout_test_results.py'), |
256 '--results-dir', '../../layout-test-results', | 265 '--results-dir', '../../layout-test-results', |
257 '--build-dir', CHROME_OUT_DIR, | 266 '--build-dir', CHROME_OUT_DIR, |
258 '--build-number', str(options.build_properties.get('buildnumber', '')), | 267 '--build-number', build_number, |
259 '--builder-name', options.build_properties.get('buildername', ''), | 268 '--builder-name', builder_name, |
260 '--gs-bucket', gs_bucket]) | 269 '--gs-bucket', gs_bucket]) |
261 | 270 |
262 | 271 |
263 def SpawnLogcatMonitor(): | 272 def SpawnLogcatMonitor(): |
264 shutil.rmtree(LOGCAT_DIR, ignore_errors=True) | 273 shutil.rmtree(LOGCAT_DIR, ignore_errors=True) |
265 bb_utils.SpawnCmd([ | 274 bb_utils.SpawnCmd([ |
266 os.path.join(CHROME_SRC_DIR, 'build', 'android', 'adb_logcat_monitor.py'), | 275 os.path.join(CHROME_SRC_DIR, 'build', 'android', 'adb_logcat_monitor.py'), |
267 LOGCAT_DIR]) | 276 LOGCAT_DIR]) |
268 | 277 |
269 # Wait for logcat_monitor to pull existing logcat | 278 # Wait for logcat_monitor to pull existing logcat |
(...skipping 200 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
470 setattr(options, 'target', options.factory_properties.get('target', 'Debug')) | 479 setattr(options, 'target', options.factory_properties.get('target', 'Debug')) |
471 if options.coverage_bucket: | 480 if options.coverage_bucket: |
472 setattr(options, 'coverage_dir', | 481 setattr(options, 'coverage_dir', |
473 os.path.join(CHROME_OUT_DIR, options.target, 'coverage')) | 482 os.path.join(CHROME_OUT_DIR, options.target, 'coverage')) |
474 | 483 |
475 MainTestWrapper(options) | 484 MainTestWrapper(options) |
476 | 485 |
477 | 486 |
478 if __name__ == '__main__': | 487 if __name__ == '__main__': |
479 sys.exit(main(sys.argv)) | 488 sys.exit(main(sys.argv)) |
OLD | NEW |