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

Side by Side Diff: scripts/slave/recipes/chromium_trybot_legacy.py

Issue 1241323004: Cross-repo recipe package system. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/tools/build
Patch Set: Moved show_me_the_modules into recipe_engine Created 5 years, 4 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 2015 The Chromium Authors. All rights reserved. 1 # Copyright 2015 The Chromium Authors. All rights reserved.
2 # Use of this source code is governed by a BSD-style license that can be 2 # Use of this source code is governed by a BSD-style license that can be
3 # found in the LICENSE file. 3 # found in the LICENSE file.
4 4
5 import itertools
6
5 from infra.libs.infra_types import freeze 7 from infra.libs.infra_types import freeze
6 8
7 DEPS = [ 9 DEPS = [
8 'bot_update', 10 'bot_update',
9 'chromium', 11 'chromium',
10 'chromium_android', 12 'chromium_android',
11 'chromium_tests', 13 'chromium_tests',
12 'gclient', 14 'gclient',
13 'gpu', 15 'gpu',
14 'isolate', 16 'isolate',
15 'itertools',
16 'json', 17 'json',
17 'path', 18 'path',
18 'platform', 19 'platform',
19 'properties', 20 'properties',
20 'python', 21 'python',
21 'raw_io', 22 'raw_io',
22 'step', 23 'step',
23 'swarming', 24 'swarming',
24 'test_utils', 25 'test_utils',
25 'tryserver', 26 'tryserver',
(...skipping 362 matching lines...) Expand 10 before | Expand all | Expand 10 after
388 try: 389 try:
389 api.chromium.runhooks(name='runhooks (with patch)') 390 api.chromium.runhooks(name='runhooks (with patch)')
390 except api.step.StepFailure: 391 except api.step.StepFailure:
391 # As part of deapplying patch we call runhooks without the patch. 392 # As part of deapplying patch we call runhooks without the patch.
392 api.chromium_tests.deapply_patch(bot_update_step) 393 api.chromium_tests.deapply_patch(bot_update_step)
393 raise 394 raise
394 395
395 if bot_config.get('use_isolate'): 396 if bot_config.get('use_isolate'):
396 api.isolate.clean_isolated_files(api.chromium.output_dir) 397 api.isolate.clean_isolated_files(api.chromium.output_dir)
397 398
398 compile_targets.extend(api.itertools.chain( 399 compile_targets.extend(itertools.chain(
399 *[t.compile_targets(api) for t in tests])) 400 *[t.compile_targets(api) for t in tests]))
400 # Remove duplicate targets. 401 # Remove duplicate targets.
401 compile_targets = sorted(set(compile_targets)) 402 compile_targets = sorted(set(compile_targets))
402 try: 403 try:
403 api.chromium.compile(compile_targets, name='compile (with patch)') 404 api.chromium.compile(compile_targets, name='compile (with patch)')
404 except api.step.StepFailure: 405 except api.step.StepFailure:
405 api.chromium_tests.deapply_patch(bot_update_step) 406 api.chromium_tests.deapply_patch(bot_update_step)
406 try: 407 try:
407 api.chromium.compile( 408 api.chromium.compile(
408 compile_targets, name='compile (without patch)') 409 compile_targets, name='compile (without patch)')
(...skipping 20 matching lines...) Expand all
429 430
430 mastername = api.properties.get('mastername') 431 mastername = api.properties.get('mastername')
431 buildername = api.properties.get('buildername') 432 buildername = api.properties.get('buildername')
432 api.chromium_tests.configure_swarming('chromium', precommit=True) 433 api.chromium_tests.configure_swarming('chromium', precommit=True)
433 434
434 tests, bot_update_step = compile_and_return_tests( 435 tests, bot_update_step = compile_and_return_tests(
435 mastername, buildername) 436 mastername, buildername)
436 437
437 def deapply_patch_fn(failing_tests): 438 def deapply_patch_fn(failing_tests):
438 api.chromium_tests.deapply_patch(bot_update_step) 439 api.chromium_tests.deapply_patch(bot_update_step)
439 compile_targets = sorted(list(set(api.itertools.chain( 440 compile_targets = sorted(list(set(itertools.chain(
440 *[t.compile_targets(api) for t in failing_tests])))) 441 *[t.compile_targets(api) for t in failing_tests]))))
441 if compile_targets: 442 if compile_targets:
442 try: 443 try:
443 api.chromium.compile( 444 api.chromium.compile(
444 compile_targets, name='compile (without patch)') 445 compile_targets, name='compile (without patch)')
445 except api.step.StepFailure: 446 except api.step.StepFailure:
446 api.tryserver.set_transient_failure_tryjob_result() 447 api.tryserver.set_transient_failure_tryjob_result()
447 raise 448 raise
448 449
449 return api.test_utils.determine_new_failures(api, tests, deapply_patch_fn) 450 return api.test_utils.determine_new_failures(api, tests, deapply_patch_fn)
(...skipping 412 matching lines...) Expand 10 before | Expand all | Expand 10 after
862 'test': 'base_tests', 863 'test': 'base_tests',
863 'args': ['--gtest-filter: *NaCl*.*'], 864 'args': ['--gtest-filter: *NaCl*.*'],
864 }, 865 },
865 ], 866 ],
866 }) 867 })
867 ) + 868 ) +
868 api.override_step_data( 869 api.override_step_data(
869 'analyze', 870 'analyze',
870 api.json.output({'invalid_targets': ['invalid target', 'another one']})) 871 api.json.output({'invalid_targets': ['invalid target', 'another one']}))
871 ) 872 )
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698