Chromium Code Reviews| Index: PRESUBMIT.py |
| diff --git a/PRESUBMIT.py b/PRESUBMIT.py |
| index 7d86fde7953bffed55837bcfa3d11131ba085451..809fe166bd36e58033d3ee954df7db3ed3d5a9af 100644 |
| --- a/PRESUBMIT.py |
| +++ b/PRESUBMIT.py |
| @@ -9,7 +9,7 @@ details on the presubmit API built into depot_tools. |
| """ |
| -def CommonChecks(input_api, output_api): |
| +def CommonChecks(input_api, output_api, integration_tests): |
|
Dirk Pranke
2011/09/01 20:38:00
I'd probably just call this blacklist or tests_to_
|
| results = [] |
| import sys |
| if not sys.version.startswith('2.5'): |
| @@ -41,8 +41,8 @@ def CommonChecks(input_api, output_api): |
| input_api, |
| output_api, |
| 'tests', |
| - whitelist=[r'.*test\.py$'])) |
| - results.extend(RunGitClTests(input_api, output_api)) |
| + whitelist=[r'.*tests\.py$'], |
| + blacklist=integration_tests)) |
| return results |
| @@ -95,13 +95,20 @@ def RunGitClTests(input_api, output_api): |
| def CheckChangeOnUpload(input_api, output_api): |
| - return CommonChecks(input_api, output_api) |
| + # Do not run integration tests on upload since they are way too slow. |
| + black_list = [ |
| + r'^checkout_test\.py$', |
| + r'^gclient_smoketest\.py$', |
| + r'^scm_unittest\.py$', |
| + ] |
| + return CommonChecks(input_api, output_api, black_list) |
| def CheckChangeOnCommit(input_api, output_api): |
| output = [] |
| - output.extend(CommonChecks(input_api, output_api)) |
| + output.extend(CommonChecks(input_api, output_api, [])) |
| output.extend(input_api.canned_checks.CheckDoNotSubmit( |
| input_api, |
| output_api)) |
| + output.extend(RunGitClTests(input_api, output_api)) |
| return output |