Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(54)

Side by Side Diff: tools/perf_expectations/PRESUBMIT.py

Issue 887033002: Cleanup: Presubmit API is built into depot_tools. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 5 years, 10 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
« no previous file with comments | « tools/perf/PRESUBMIT.py ('k') | tools/valgrind/drmemory/PRESUBMIT.py » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 # Copyright (c) 2011 The Chromium Authors. All rights reserved. 1 # Copyright (c) 2011 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 """Presubmit script for perf_expectations. 5 """Presubmit script for perf_expectations.
6 6
7 See http://dev.chromium.org/developers/how-tos/depottools/presubmit-scripts for 7 See http://dev.chromium.org/developers/how-tos/depottools/presubmit-scripts for
8 details on the presubmit API built into gcl. 8 details on the presubmit API built into depot_tools.
9 """ 9 """
10 10
11 PERF_EXPECTATIONS = 'tools/perf_expectations/perf_expectations.json' 11 PERF_EXPECTATIONS = 'tools/perf_expectations/perf_expectations.json'
12 CONFIG_FILE = 'tools/perf_expectations/chromium_perf_expectations.cfg' 12 CONFIG_FILE = 'tools/perf_expectations/chromium_perf_expectations.cfg'
13 13
14 def CheckChangeOnUpload(input_api, output_api): 14 def CheckChangeOnUpload(input_api, output_api):
15 run_tests = False 15 run_tests = False
16 for path in input_api.LocalPaths(): 16 for path in input_api.LocalPaths():
17 if (PERF_EXPECTATIONS == path or CONFIG_FILE == path): 17 if (PERF_EXPECTATIONS == path or CONFIG_FILE == path):
18 run_tests = True 18 run_tests = True
(...skipping 14 matching lines...) Expand all
33 33
34 output = [] 34 output = []
35 if run_tests: 35 if run_tests:
36 whitelist = [r'.+_unittest\.py$'] 36 whitelist = [r'.+_unittest\.py$']
37 output.extend(input_api.canned_checks.RunUnitTestsInDirectory( 37 output.extend(input_api.canned_checks.RunUnitTestsInDirectory(
38 input_api, output_api, 'tests', whitelist)) 38 input_api, output_api, 'tests', whitelist))
39 39
40 output.extend(input_api.canned_checks.CheckDoNotSubmit(input_api, 40 output.extend(input_api.canned_checks.CheckDoNotSubmit(input_api,
41 output_api)) 41 output_api))
42 return output 42 return output
OLDNEW
« no previous file with comments | « tools/perf/PRESUBMIT.py ('k') | tools/valgrind/drmemory/PRESUBMIT.py » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698