| 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 DEPS = [ | 5 DEPS = [ | 
|  | 6   'recipe_engine/raw_io', | 
| 6   'recipe_engine/path', | 7   'recipe_engine/path', | 
| 7   'recipe_engine/platform', | 8   'recipe_engine/platform', | 
| 8   'recipe_engine/properties', | 9   'recipe_engine/properties', | 
| 9   'recipe_engine/python', | 10   'recipe_engine/python', | 
|  | 11   'recipe_engine/step', | 
| 10   'tryserver', | 12   'tryserver', | 
| 11 ] | 13 ] | 
| 12 | 14 | 
| 13 | 15 | 
| 14 def RunSteps(api): | 16 def RunSteps(api): | 
| 15   api.path['checkout'] = api.path['slave_build'] | 17   api.path['checkout'] = api.path['slave_build'] | 
|  | 18   if api.properties.get('patch_text'): | 
|  | 19     api.step('patch_text test', [ | 
|  | 20         'echo', str(api.tryserver.get_footers(api.properties['patch_text']))]) | 
|  | 21     api.step('get_footer test', [ | 
|  | 22         'echo', str(api.tryserver.get_footer( | 
|  | 23             api.properties['footer'], | 
|  | 24             patch_text=api.properties['patch_text']))]) | 
|  | 25     return | 
|  | 26 | 
| 16   api.tryserver.maybe_apply_issue() | 27   api.tryserver.maybe_apply_issue() | 
|  | 28   if api.tryserver.can_apply_issue: | 
|  | 29     api.tryserver.get_footers() | 
| 17   api.tryserver.get_files_affected_by_patch() | 30   api.tryserver.get_files_affected_by_patch() | 
| 18 | 31 | 
| 19   if api.tryserver.is_tryserver: | 32   if api.tryserver.is_tryserver: | 
| 20     api.tryserver.set_subproject_tag('v8') | 33     api.tryserver.set_subproject_tag('v8') | 
| 21 | 34 | 
| 22   api.tryserver.set_patch_failure_tryjob_result() | 35   api.tryserver.set_patch_failure_tryjob_result() | 
| 23   api.tryserver.set_compile_failure_tryjob_result() | 36   api.tryserver.set_compile_failure_tryjob_result() | 
| 24   api.tryserver.set_test_failure_tryjob_result() | 37   api.tryserver.set_test_failure_tryjob_result() | 
| 25   api.tryserver.set_invalid_test_results_tryjob_result() | 38   api.tryserver.set_invalid_test_results_tryjob_result() | 
| 26 | 39 | 
| 27   with api.tryserver.set_failure_hash(): | 40   with api.tryserver.set_failure_hash(): | 
| 28     api.python.failing_step('fail', 'foo') | 41     api.python.failing_step('fail', 'foo') | 
| 29 | 42 | 
| 30 | 43 | 
| 31 def GenTests(api): | 44 def GenTests(api): | 
|  | 45   description_step = api.override_step_data( | 
|  | 46       'git_cl description', stdout=api.raw_io.output("foobar")) | 
| 32   yield (api.test('with_svn_patch') + | 47   yield (api.test('with_svn_patch') + | 
| 33          api.properties(patch_url='svn://checkout.url')) | 48          api.properties(patch_url='svn://checkout.url')) | 
| 34 | 49 | 
| 35   yield (api.test('with_git_patch') + | 50   yield (api.test('with_git_patch') + | 
| 36          api.properties( | 51          api.properties( | 
| 37               patch_storage='git', | 52               patch_storage='git', | 
| 38               patch_project='v8', | 53               patch_project='v8', | 
| 39               patch_repo_url='http://patch.url/', | 54               patch_repo_url='http://patch.url/', | 
| 40               patch_ref='johndoe#123.diff')) | 55               patch_ref='johndoe#123.diff')) | 
| 41 | 56 | 
| 42   yield (api.test('with_rietveld_patch') + | 57   yield (api.test('with_rietveld_patch') + | 
| 43          api.properties.tryserver()) | 58          api.properties.tryserver() + | 
|  | 59          description_step) | 
| 44 | 60 | 
| 45   yield (api.test('with_wrong_patch') + api.platform('win', 32)) | 61   yield (api.test('with_wrong_patch') + api.platform('win', 32)) | 
|  | 62 | 
|  | 63   yield (api.test('basic_tags') + | 
|  | 64          api.properties( | 
|  | 65              patch_text="hihihi\nfoo:bar\nbam:baz", | 
|  | 66              footer="foo" | 
|  | 67          ) | 
|  | 68   ) | 
| OLD | NEW | 
|---|