OLD | NEW |
1 # Copyright (c) 2012 The Chromium Authors. All rights reserved. | 1 # Copyright (c) 2012 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 """Top-level presubmit script for cc. | 5 """Top-level presubmit script for cc. |
6 | 6 |
7 See http://dev.chromium.org/developers/how-tos/depottools/presubmit-scripts | 7 See http://dev.chromium.org/developers/how-tos/depottools/presubmit-scripts |
8 for more details about the presubmit API built into depot_tools. | 8 for more details about the presubmit API built into depot_tools. |
9 """ | 9 """ |
10 | 10 |
(...skipping 320 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
331 This hook adds extra try bots list to the CL description in order to run | 331 This hook adds extra try bots list to the CL description in order to run |
332 Blink tests in addition to CQ try bots. | 332 Blink tests in addition to CQ try bots. |
333 """ | 333 """ |
334 rietveld_obj = cl.RpcServer() | 334 rietveld_obj = cl.RpcServer() |
335 issue = cl.issue | 335 issue = cl.issue |
336 description = rietveld_obj.get_description(issue) | 336 description = rietveld_obj.get_description(issue) |
337 if re.search(r'^CQ_INCLUDE_TRYBOTS=.*', description, re.M | re.I): | 337 if re.search(r'^CQ_INCLUDE_TRYBOTS=.*', description, re.M | re.I): |
338 return [] | 338 return [] |
339 | 339 |
340 bots = [ | 340 bots = [ |
341 'master.tryserver.blink:linux_blink_rel', | 341 'master.tryserver.blink:linux_precise_blink_rel', |
342 ] | 342 ] |
343 | 343 |
344 results = [] | 344 results = [] |
345 new_description = description | 345 new_description = description |
346 new_description += '\nCQ_INCLUDE_TRYBOTS=%s' % ';'.join(bots) | 346 new_description += '\nCQ_INCLUDE_TRYBOTS=%s' % ';'.join(bots) |
347 results.append(output_api.PresubmitNotifyResult( | 347 results.append(output_api.PresubmitNotifyResult( |
348 'Automatically added Blink trybots to run Blink tests on CQ.')) | 348 'Automatically added Blink trybots to run Blink tests on CQ.')) |
349 | 349 |
350 if new_description != description: | 350 if new_description != description: |
351 rietveld_obj.update_description(issue, new_description) | 351 rietveld_obj.update_description(issue, new_description) |
352 | 352 |
353 return results | 353 return results |
OLD | NEW |