| OLD | NEW |
| 1 # Copyright 2016 The Chromium Authors. All rights reserved. | 1 # Copyright 2016 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 collections | 5 import collections |
| 6 import hashlib | 6 import hashlib |
| 7 import json | 7 import json |
| 8 import re | 8 import re |
| 9 | 9 |
| 10 from recipe_engine import recipe_api | 10 from recipe_engine import recipe_api |
| (...skipping 253 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 264 default, but which infra's python has installed.""" | 264 default, but which infra's python has installed.""" |
| 265 return self.m.step(name, [ | 265 return self.m.step(name, [ |
| 266 self.m.path['checkout'].join('ENV', 'bin', 'python'), | 266 self.m.path['checkout'].join('ENV', 'bin', 'python'), |
| 267 '-u', script] + args, **kwargs) | 267 '-u', script] + args, **kwargs) |
| 268 | 268 |
| 269 def run_tryjob(self, patches_raw, rietveld, issue, patchset, patch_project): | 269 def run_tryjob(self, patches_raw, rietveld, issue, patchset, patch_project): |
| 270 patches = parse_patches( | 270 patches = parse_patches( |
| 271 self.m.python.failing_step, patches_raw, rietveld, issue, patchset, | 271 self.m.python.failing_step, patches_raw, rietveld, issue, patchset, |
| 272 patch_project) | 272 patch_project) |
| 273 | 273 |
| 274 root_dir = self.m.infra_paths['slave_build'] | 274 root_dir = self.m.path['slave_build'] |
| 275 | 275 |
| 276 # Needed to set up the infra checkout, for _python | 276 # Needed to set up the infra checkout, for _python |
| 277 self.m.gclient.set_config('infra') | 277 self.m.gclient.set_config('infra') |
| 278 self.m.gclient.c.solutions[0].revision = 'origin/master' | 278 self.m.gclient.c.solutions[0].revision = 'origin/master' |
| 279 self.m.gclient.checkout() | 279 self.m.gclient.checkout() |
| 280 self.m.gclient.runhooks() | 280 self.m.gclient.runhooks() |
| 281 | 281 |
| 282 url_mapping = self.m.luci_config.get_projects() | 282 url_mapping = self.m.luci_config.get_projects() |
| 283 | 283 |
| 284 # TODO(martiniss): use luci-config smarter; get recipes.cfg directly, rather | 284 # TODO(martiniss): use luci-config smarter; get recipes.cfg directly, rather |
| (...skipping 11 matching lines...) Expand all Loading... |
| 296 | 296 |
| 297 projs_to_test, locations = self._checkout_projects( | 297 projs_to_test, locations = self._checkout_projects( |
| 298 all_projects, root_dir, url_mapping, downstream_projects, patches) | 298 all_projects, root_dir, url_mapping, downstream_projects, patches) |
| 299 | 299 |
| 300 with self.m.step.defer_results(): | 300 with self.m.step.defer_results(): |
| 301 for proj in projs_to_test: | 301 for proj in projs_to_test: |
| 302 deps_locs = {dep: locations[dep] for dep in deps[proj]} | 302 deps_locs = {dep: locations[dep] for dep in deps[proj]} |
| 303 | 303 |
| 304 self.simulation_test( | 304 self.simulation_test( |
| 305 proj, recipe_configs[proj], locations[proj], deps_locs) | 305 proj, recipe_configs[proj], locations[proj], deps_locs) |
| OLD | NEW |