| OLD | NEW |
| 1 # Copyright 2013 The Chromium Authors. All rights reserved. | 1 # Copyright 2013-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 contextlib | 5 import contextlib |
| 6 import types | 6 import types |
| 7 | 7 |
| 8 from functools import wraps | 8 from functools import wraps |
| 9 | 9 |
| 10 from .recipe_test_api import DisabledTestData, ModuleTestData | 10 from .recipe_test_api import DisabledTestData, ModuleTestData |
| 11 | 11 |
| 12 from .recipe_util import ModuleInjectionSite | 12 from .util import ModuleInjectionSite |
| 13 | 13 |
| 14 from . import field_composer | 14 from . import field_composer |
| 15 | 15 |
| 16 | 16 |
| 17 class StepFailure(Exception): | 17 class StepFailure(Exception): |
| 18 """ | 18 """ |
| 19 This is the base class for all step failures. | 19 This is the base class for all step failures. |
| 20 | 20 |
| 21 Raising a StepFailure counts as 'running a step' for the purpose of | 21 Raising a StepFailure counts as 'running a step' for the purpose of |
| 22 infer_composite_step's logic. | 22 infer_composite_step's logic. |
| (...skipping 417 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 440 # module.resource('dir').join('subdir', 'file.py') | 440 # module.resource('dir').join('subdir', 'file.py') |
| 441 return self._module.MODULE_DIRECTORY.join('resources', *path) | 441 return self._module.MODULE_DIRECTORY.join('resources', *path) |
| 442 | 442 |
| 443 @property | 443 @property |
| 444 def name(self): | 444 def name(self): |
| 445 return self._module.NAME | 445 return self._module.NAME |
| 446 | 446 |
| 447 | 447 |
| 448 class RecipeApi(RecipeApiPlain): | 448 class RecipeApi(RecipeApiPlain): |
| 449 __metaclass__ = RecipeApiMeta | 449 __metaclass__ = RecipeApiMeta |
| OLD | NEW |