| OLD | NEW |
| 1 # Copyright (c) 2013 The Chromium Authors. All rights reserved. | 1 # Copyright (c) 2013 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 DEPS = [ | 5 DEPS = [ |
| 6 'depot_tools/bot_update', | 6 'depot_tools/bot_update', |
| 7 'depot_tools/gclient', | 7 'depot_tools/gclient', |
| 8 'depot_tools/git', | 8 'depot_tools/git', |
| 9 'depot_tools/presubmit', | 9 'depot_tools/presubmit', |
| 10 'recipe_engine/json', | 10 'recipe_engine/json', |
| 11 'recipe_engine/path', | 11 'recipe_engine/path', |
| 12 'recipe_engine/properties', | 12 'recipe_engine/properties', |
| 13 'recipe_engine/python', | 13 'recipe_engine/python', |
| 14 'recipe_engine/step', | 14 'recipe_engine/step', |
| 15 'depot_tools/tryserver', | 15 'depot_tools/tryserver', |
| 16 'depot_tools/rietveld', | 16 'depot_tools/rietveld', |
| 17 'v8', | 17 'v8', |
| 18 'webrtc', | 18 'webrtc', |
| 19 ] | 19 ] |
| 20 | 20 |
| 21 | 21 |
| 22 def _RunStepsInternal(api): | 22 def _RunStepsInternal(api): |
| 23 repo_name = api.properties['repo_name'] | 23 repo_name = api.properties['repo_name'] |
| 24 codereview_auth = api.properties.get('codereview_auth', False) | 24 codereview_auth = api.properties.get('codereview_auth', False) |
| 25 force_checkout = api.properties.get('force_checkout', False) | |
| 26 patch_storage = api.properties.get('patch_storage', 'rietveld') | 25 patch_storage = api.properties.get('patch_storage', 'rietveld') |
| 27 | 26 |
| 28 api.gclient.set_config(repo_name) | 27 api.gclient.set_config(repo_name) |
| 29 | 28 |
| 30 kwargs = {} | 29 kwargs = {} |
| 31 bot_update_step = api.bot_update.ensure_checkout( | 30 bot_update_step = api.bot_update.ensure_checkout( |
| 32 force=force_checkout, | |
| 33 patch_oauth2=codereview_auth, | 31 patch_oauth2=codereview_auth, |
| 34 **kwargs) | 32 **kwargs) |
| 35 relative_root = api.gclient.calculate_patch_root( | 33 relative_root = api.gclient.calculate_patch_root( |
| 36 api.properties['patch_project']).rstrip('/') | 34 api.properties['patch_project']).rstrip('/') |
| 37 got_revision_property = api.gclient.c.got_revision_mapping[relative_root] | 35 got_revision_property = api.gclient.c.got_revision_mapping[relative_root] |
| 38 upstream = bot_update_step.json.output['properties'].get( | 36 upstream = bot_update_step.json.output['properties'].get( |
| 39 got_revision_property) | 37 got_revision_property) |
| 40 | 38 |
| 41 abs_root = api.path['slave_build'].join(relative_root) | 39 abs_root = api.path['slave_build'].join(relative_root) |
| 42 # TODO(hinoka): Extract email/name from issue? | 40 # TODO(hinoka): Extract email/name from issue? |
| (...skipping 172 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 215 | 213 |
| 216 yield ( | 214 yield ( |
| 217 api.test('presubmit-infra-failure') + | 215 api.test('presubmit-infra-failure') + |
| 218 api.properties.tryserver( | 216 api.properties.tryserver( |
| 219 mastername='tryserver.chromium.linux', | 217 mastername='tryserver.chromium.linux', |
| 220 buildername='chromium_presubmit', | 218 buildername='chromium_presubmit', |
| 221 repo_name='chromium', | 219 repo_name='chromium', |
| 222 patch_project='chromium') + | 220 patch_project='chromium') + |
| 223 api.step_data('presubmit', api.json.output({}, retcode=2)) | 221 api.step_data('presubmit', api.json.output({}, retcode=2)) |
| 224 ) | 222 ) |
| OLD | NEW |