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 'bot_update', | 6 'bot_update', |
7 'gclient', | 7 'gclient', |
8 'recipe_engine/path', | 8 'recipe_engine/path', |
9 'recipe_engine/properties', | 9 'recipe_engine/properties', |
10 ] | 10 ] |
(...skipping 16 matching lines...) Expand all Loading... | |
27 clobber = True if api.properties.get('clobber') else False | 27 clobber = True if api.properties.get('clobber') else False |
28 force = True if api.properties.get('force') else False | 28 force = True if api.properties.get('force') else False |
29 no_shallow = True if api.properties.get('no_shallow') else False | 29 no_shallow = True if api.properties.get('no_shallow') else False |
30 output_manifest = api.properties.get('output_manifest', False) | 30 output_manifest = api.properties.get('output_manifest', False) |
31 with_branch_heads = api.properties.get('with_branch_heads', False) | 31 with_branch_heads = api.properties.get('with_branch_heads', False) |
32 refs = api.properties.get('refs', []) | 32 refs = api.properties.get('refs', []) |
33 oauth2 = api.properties.get('oauth2', False) | 33 oauth2 = api.properties.get('oauth2', False) |
34 root_solution_revision = api.properties.get('root_solution_revision') | 34 root_solution_revision = api.properties.get('root_solution_revision') |
35 suffix = api.properties.get('suffix') | 35 suffix = api.properties.get('suffix') |
36 gerrit_no_reset = True if api.properties.get('gerrit_no_reset') else False | 36 gerrit_no_reset = True if api.properties.get('gerrit_no_reset') else False |
37 gerrit_rebase_patch_ref = bool(api.properties.get('gerrit_rebase_patch_ref')) | 37 gerrit_no_rebase_patch_ref = bool(api.properties.get('gerrit_no_rebase_patch_r ef')) |
tandrii(chromium)
2016/08/31 18:31:18
nit: 80 chars
Bons
2016/08/31 18:47:55
Done
| |
38 | 38 |
39 if api.properties.get('test_apply_gerrit_ref'): | 39 if api.properties.get('test_apply_gerrit_ref'): |
40 api.bot_update.apply_gerrit_ref( | 40 api.bot_update.apply_gerrit_ref( |
41 root='/tmp/test/root', | 41 root='/tmp/test/root', |
42 gerrit_no_reset=gerrit_no_reset, | 42 gerrit_no_reset=gerrit_no_reset, |
43 gerrit_rebase_patch_ref=gerrit_rebase_patch_ref) | 43 gerrit_no_rebase_patch_ref=gerrit_no_rebase_patch_ref) |
44 else: | 44 else: |
45 api.bot_update.ensure_checkout( | 45 api.bot_update.ensure_checkout( |
46 force=force, | 46 force=force, |
47 no_shallow=no_shallow, | 47 no_shallow=no_shallow, |
48 patch=patch, | 48 patch=patch, |
49 with_branch_heads=with_branch_heads, | 49 with_branch_heads=with_branch_heads, |
50 output_manifest=output_manifest, | 50 output_manifest=output_manifest, |
51 refs=refs, patch_oauth2=oauth2, | 51 refs=refs, patch_oauth2=oauth2, |
52 clobber=clobber, | 52 clobber=clobber, |
53 root_solution_revision=root_solution_revision, | 53 root_solution_revision=root_solution_revision, |
54 suffix=suffix, | 54 suffix=suffix, |
55 gerrit_no_reset=gerrit_no_reset, | 55 gerrit_no_reset=gerrit_no_reset, |
56 gerrit_rebase_patch_ref=gerrit_rebase_patch_ref) | 56 gerrit_no_rebase_patch_ref=gerrit_no_rebase_patch_ref) |
57 | 57 |
58 | 58 |
59 def GenTests(api): | 59 def GenTests(api): |
60 yield api.test('basic') + api.properties( | 60 yield api.test('basic') + api.properties( |
61 mastername='chromium.linux', | 61 mastername='chromium.linux', |
62 buildername='Linux Builder', | 62 buildername='Linux Builder', |
63 slavename='totallyaslave-m1', | 63 slavename='totallyaslave-m1', |
64 patch=False, | 64 patch=False, |
65 revision='abc' | 65 revision='abc' |
66 ) | 66 ) |
(...skipping 84 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
151 buildername='Experimental Builder', | 151 buildername='Experimental Builder', |
152 slavename='somehost', | 152 slavename='somehost', |
153 root_solution_revision='revision', | 153 root_solution_revision='revision', |
154 ) | 154 ) |
155 yield api.test('gerrit_no_reset') + api.properties( | 155 yield api.test('gerrit_no_reset') + api.properties( |
156 mastername='experimental', | 156 mastername='experimental', |
157 buildername='Experimental Builder', | 157 buildername='Experimental Builder', |
158 slavename='somehost', | 158 slavename='somehost', |
159 gerrit_no_reset=1 | 159 gerrit_no_reset=1 |
160 ) | 160 ) |
161 yield api.test('gerrit_rebase_patch_ref') + api.properties( | 161 yield api.test('gerrit_no_rebase_patch_ref') + api.properties( |
162 mastername='experimental', | 162 mastername='experimental', |
163 buildername='Experimental Builder', | 163 buildername='Experimental Builder', |
164 slavename='somehost', | 164 slavename='somehost', |
165 gerrit_rebase_patch_ref=True | 165 gerrit_no_rebase_patch_ref=True |
166 ) | 166 ) |
167 yield api.test('apply_gerrit_ref') + api.properties( | 167 yield api.test('apply_gerrit_ref') + api.properties( |
168 repository='chromium', | 168 repository='chromium', |
169 gerrit_rebase_patch_ref=True, | 169 gerrit_no_rebase_patch_ref=True, |
170 gerrit_no_reset=1, | 170 gerrit_no_reset=1, |
171 test_apply_gerrit_ref=True, | 171 test_apply_gerrit_ref=True, |
172 ) | 172 ) |
173 yield api.test('tryjob_v8') + api.properties( | 173 yield api.test('tryjob_v8') + api.properties( |
174 mastername='tryserver.chromium.linux', | 174 mastername='tryserver.chromium.linux', |
175 buildername='linux_rel', | 175 buildername='linux_rel', |
176 slavename='totallyaslave-c4', | 176 slavename='totallyaslave-c4', |
177 issue=12345, | 177 issue=12345, |
178 patchset=654321, | 178 patchset=654321, |
179 patch_url='http://src.chromium.org/foo/bar', | 179 patch_url='http://src.chromium.org/foo/bar', |
180 patch_project='v8', | 180 patch_project='v8', |
181 revisions={'src/v8': 'abc'} | 181 revisions={'src/v8': 'abc'} |
182 ) | 182 ) |
183 yield api.test('tryjob_v8_head_by_default') + api.properties.tryserver( | 183 yield api.test('tryjob_v8_head_by_default') + api.properties.tryserver( |
184 patch_project='v8', | 184 patch_project='v8', |
185 ) | 185 ) |
186 yield api.test('tryjob_gerrit_angle') + api.properties.tryserver_gerrit( | 186 yield api.test('tryjob_gerrit_angle') + api.properties.tryserver_gerrit( |
187 full_project_name='angle/angle', | 187 full_project_name='angle/angle', |
188 ) | 188 ) |
OLD | NEW |