| 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 depot_tools. | 8 for more details about the presubmit API built into depot_tools. |
| 9 """ | 9 """ |
| 10 | 10 |
| (...skipping 129 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 140 ), | 140 ), |
| 141 ( | 141 ( |
| 142 'convertSizeToBase:', | 142 'convertSizeToBase:', |
| 143 ( | 143 ( |
| 144 'The use of -[NSView convertSizeToBase:] is almost certainly wrong.', | 144 'The use of -[NSView convertSizeToBase:] is almost certainly wrong.', |
| 145 'Please use |convertSize:(point) toView:nil| instead.', | 145 'Please use |convertSize:(point) toView:nil| instead.', |
| 146 'http://dev.chromium.org/developers/coding-style/cocoa-dos-and-donts', | 146 'http://dev.chromium.org/developers/coding-style/cocoa-dos-and-donts', |
| 147 ), | 147 ), |
| 148 True, | 148 True, |
| 149 ), | 149 ), |
| 150 ( |
| 151 r"/\s+UTF8String\s*]", |
| 152 ( |
| 153 'The use of -[NSString UTF8String] is dangerous as it can return null', |
| 154 'even if |canBeConvertedToEncoding:NSUTF8StringEncoding| returns YES.', |
| 155 'Please use |SysNSStringToUTF8| instead.', |
| 156 ), |
| 157 True, |
| 158 ), |
| 150 ) | 159 ) |
| 151 | 160 |
| 152 | 161 |
| 153 _BANNED_CPP_FUNCTIONS = ( | 162 _BANNED_CPP_FUNCTIONS = ( |
| 154 # Make sure that gtest's FRIEND_TEST() macro is not used; the | 163 # Make sure that gtest's FRIEND_TEST() macro is not used; the |
| 155 # FRIEND_TEST_ALL_PREFIXES() macro from base/gtest_prod_util.h should be | 164 # FRIEND_TEST_ALL_PREFIXES() macro from base/gtest_prod_util.h should be |
| 156 # used instead since that allows for FLAKY_ and DISABLED_ prefixes. | 165 # used instead since that allows for FLAKY_ and DISABLED_ prefixes. |
| 157 ( | 166 ( |
| 158 'FRIEND_TEST(', | 167 'FRIEND_TEST(', |
| 159 ( | 168 ( |
| (...skipping 2140 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 2300 results.extend(input_api.canned_checks.CheckTreeIsOpen( | 2309 results.extend(input_api.canned_checks.CheckTreeIsOpen( |
| 2301 input_api, | 2310 input_api, |
| 2302 output_api, | 2311 output_api, |
| 2303 json_url='http://chromium-status.appspot.com/current?format=json')) | 2312 json_url='http://chromium-status.appspot.com/current?format=json')) |
| 2304 | 2313 |
| 2305 results.extend(input_api.canned_checks.CheckChangeHasBugField( | 2314 results.extend(input_api.canned_checks.CheckChangeHasBugField( |
| 2306 input_api, output_api)) | 2315 input_api, output_api)) |
| 2307 results.extend(input_api.canned_checks.CheckChangeHasDescription( | 2316 results.extend(input_api.canned_checks.CheckChangeHasDescription( |
| 2308 input_api, output_api)) | 2317 input_api, output_api)) |
| 2309 return results | 2318 return results |
| OLD | NEW |