| 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 Chromium. | 5 """Top-level presubmit script for Chromium. |
| 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 gcl. | 8 for more details about the presubmit API built into gcl. |
| 9 """ | 9 """ |
| 10 | 10 |
| 11 | 11 |
| 12 import re | 12 import re |
| 13 import subprocess | 13 import subprocess |
| 14 import sys | 14 import sys |
| 15 | 15 |
| 16 | 16 |
| 17 _EXCLUDED_PATHS = ( | 17 _EXCLUDED_PATHS = ( |
| 18 r"^breakpad[\\\/].*", | 18 r"^breakpad[\\\/].*", |
| 19 r"^native_client_sdk[\\\/].*", | 19 r"^native_client_sdk[\\\/].*", |
| 20 r"^net[\\\/]tools[\\\/]spdyshark[\\\/].*", | 20 r"^net[\\\/]tools[\\\/]spdyshark[\\\/].*", |
| 21 r"^skia[\\\/].*", | 21 r"^skia[\\\/].*", |
| 22 r"^v8[\\\/].*", | 22 r"^v8[\\\/].*", |
| 23 r".*MakeFile$", | 23 r".*MakeFile$", |
| 24 r".+_autogen\.h$", | 24 r".+_autogen\.h$", |
| 25 r"^cc[\\\/].*", |
| 25 ) | 26 ) |
| 26 | 27 |
| 27 | 28 |
| 28 _TEST_ONLY_WARNING = ( | 29 _TEST_ONLY_WARNING = ( |
| 29 'You might be calling functions intended only for testing from\n' | 30 'You might be calling functions intended only for testing from\n' |
| 30 'production code. It is OK to ignore this warning if you know what\n' | 31 'production code. It is OK to ignore this warning if you know what\n' |
| 31 'you are doing, as the heuristics used to detect the situation are\n' | 32 'you are doing, as the heuristics used to detect the situation are\n' |
| 32 'not perfect. The commit queue will not block on this warning.\n' | 33 'not perfect. The commit queue will not block on this warning.\n' |
| 33 'Email joi@chromium.org if you have questions.') | 34 'Email joi@chromium.org if you have questions.') |
| 34 | 35 |
| (...skipping 564 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 599 | 600 |
| 600 # Match things like path/aura/file.cc and path/file_aura.cc. | 601 # Match things like path/aura/file.cc and path/file_aura.cc. |
| 601 # Same for ash and chromeos. | 602 # Same for ash and chromeos. |
| 602 if any(re.search('[/_](ash|aura)', f) for f in files): | 603 if any(re.search('[/_](ash|aura)', f) for f in files): |
| 603 trybots += ['linux_chromeos', 'linux_chromeos_clang:compile', 'win_aura'] | 604 trybots += ['linux_chromeos', 'linux_chromeos_clang:compile', 'win_aura'] |
| 604 else: | 605 else: |
| 605 if any(re.search('[/_]chromeos', f) for f in files): | 606 if any(re.search('[/_]chromeos', f) for f in files): |
| 606 trybots += ['linux_chromeos', 'linux_chromeos_clang:compile'] | 607 trybots += ['linux_chromeos', 'linux_chromeos_clang:compile'] |
| 607 | 608 |
| 608 return trybots | 609 return trybots |
| OLD | NEW |