| OLD | NEW |
| 1 # Copyright 2014 The Chromium Authors. All rights reserved. | 1 # Copyright 2014 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 | 5 |
| 6 """Recipe module to ensure a checkout is consistant on a bot.""" | 6 """Recipe module to ensure a checkout is consistant on a bot.""" |
| 7 | 7 |
| 8 from recipe_engine import recipe_api | 8 from recipe_engine import recipe_api |
| 9 | 9 |
| 10 | 10 |
| (...skipping 54 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 65 Args: | 65 Args: |
| 66 gclient_config: The gclient configuration to use when running bot_update. | 66 gclient_config: The gclient configuration to use when running bot_update. |
| 67 If omitted, the current gclient configuration is used. | 67 If omitted, the current gclient configuration is used. |
| 68 rietveld: The rietveld server to use. If omitted, will infer from | 68 rietveld: The rietveld server to use. If omitted, will infer from |
| 69 the 'rietveld' property. | 69 the 'rietveld' property. |
| 70 issue: The rietveld issue number to use. If omitted, will infer from | 70 issue: The rietveld issue number to use. If omitted, will infer from |
| 71 the 'issue' property. | 71 the 'issue' property. |
| 72 patchset: The rietveld issue patchset to use. If omitted, will infer from | 72 patchset: The rietveld issue patchset to use. If omitted, will infer from |
| 73 the 'patchset' property. | 73 the 'patchset' property. |
| 74 """ | 74 """ |
| 75 if self._mastername and 'skia' in self._mastername: #pragma: no cover |
| 76 self.m.step('foo', ['echo', 'foo']) |
| 77 |
| 75 refs = refs or [] | 78 refs = refs or [] |
| 76 # We can re-use the gclient spec from the gclient module, since all the | 79 # We can re-use the gclient spec from the gclient module, since all the |
| 77 # data bot_update needs is already configured into the gclient spec. | 80 # data bot_update needs is already configured into the gclient spec. |
| 78 cfg = gclient_config or self.m.gclient.c | 81 cfg = gclient_config or self.m.gclient.c |
| 79 | 82 |
| 80 # Used by bot_update to determine if we want to run or not. | 83 # Used by bot_update to determine if we want to run or not. |
| 81 master = self._mastername | 84 master = self._mastername |
| 82 builder = self._buildername | 85 builder = self._buildername |
| 83 slave = self._slavename | 86 slave = self._slavename |
| 84 | 87 |
| (...skipping 189 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 274 | 277 |
| 275 # bot_update actually just sets root to be the folder name of the | 278 # bot_update actually just sets root to be the folder name of the |
| 276 # first solution. | 279 # first solution. |
| 277 if step_result.json.output['did_run']: | 280 if step_result.json.output['did_run']: |
| 278 co_root = step_result.json.output['root'] | 281 co_root = step_result.json.output['root'] |
| 279 cwd = kwargs.get('cwd', self.m.path['slave_build']) | 282 cwd = kwargs.get('cwd', self.m.path['slave_build']) |
| 280 if 'checkout' not in self.m.path: | 283 if 'checkout' not in self.m.path: |
| 281 self.m.path['checkout'] = cwd.join(*co_root.split(self.m.path.sep)) | 284 self.m.path['checkout'] = cwd.join(*co_root.split(self.m.path.sep)) |
| 282 | 285 |
| 283 return step_result | 286 return step_result |
| 287 |
| 288 |
| OLD | NEW |