Chromium Code Reviews| OLD | NEW |
|---|---|
| 1 # Copyright (c) 2016 The Chromium Authors. All rights reserved. | 1 # Copyright (c) 2016 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 gpu. | 5 """Top-level presubmit script for media/audio/. |
| 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 |
| 11 import re | 11 import re |
| 12 | 12 |
| 13 def PostUploadHook(cl, change, output_api): | 13 def PostUploadHook(cl, change, output_api): |
| 14 """git cl upload will call this hook after the issue is created/modified. | 14 """git cl upload will call this hook after the issue is created/modified. |
| 15 | 15 |
| 16 This hook adds extra try bots list to the CL description in order to run | 16 This hook modifies the CL description in order to run extra GPU |
| 17 Blink tests in addition to CQ try bots. | 17 tests (in particular, the WebGL 2.0 conformance tests) in addition |
| 18 to the regular CQ try bots. This test suite is too large to run | |
| 19 against all Chromium commits, but should be run against changes | |
| 20 likely to affect these tests. | |
| 18 """ | 21 """ |
| 19 rietveld_obj = cl.RpcServer() | 22 rietveld_obj = cl.RpcServer() |
| 20 issue = cl.issue | 23 issue = cl.issue |
| 21 description = rietveld_obj.get_description(issue) | 24 description = rietveld_obj.get_description(issue) |
| 22 if re.search(r'^CQ_INCLUDE_TRYBOTS=.*', description, re.M | re.I): | 25 if re.search(r'^CQ_INCLUDE_TRYBOTS=.*', description, re.M | re.I): |
| 23 return [] | 26 return [] |
| 24 | 27 |
| 25 bots = [ | 28 bots = [ |
|
ynovikov
2016/11/04 23:03:39
Does it make sense to add android_optional_gpu_tes
| |
| 26 'master.tryserver.chromium.linux:linux_optional_gpu_tests_rel', | 29 'master.tryserver.chromium.linux:linux_optional_gpu_tests_rel', |
| 27 'master.tryserver.chromium.mac:mac_optional_gpu_tests_rel', | 30 'master.tryserver.chromium.mac:mac_optional_gpu_tests_rel', |
| 28 'master.tryserver.chromium.win:win_optional_gpu_tests_rel', | 31 'master.tryserver.chromium.win:win_optional_gpu_tests_rel', |
| 29 ] | 32 ] |
| 30 | 33 |
| 31 results = [] | 34 results = [] |
| 32 new_description = description | 35 new_description = description |
| 33 new_description += '\nCQ_INCLUDE_TRYBOTS=%s' % ';'.join(bots) | 36 new_description += '\nCQ_INCLUDE_TRYBOTS=%s' % ';'.join(bots) |
| 34 results.append(output_api.PresubmitNotifyResult( | 37 results.append(output_api.PresubmitNotifyResult( |
| 35 'Automatically added optional GPU tests to run on CQ.')) | 38 'Automatically added optional GPU tests to run on CQ.')) |
| 36 | 39 |
| 37 if new_description != description: | 40 if new_description != description: |
| 38 rietveld_obj.update_description(issue, new_description) | 41 rietveld_obj.update_description(issue, new_description) |
| 39 | 42 |
| 40 return results | 43 return results |
| OLD | NEW |