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

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

Issue 194032: Add more unit tests for perf expectations.... (Closed) Base URL: svn://chrome-svn.corp.google.com/chrome/trunk/tools/buildbot/scripts/master/
Patch Set: Created 11 years, 3 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 | « no previous file | log_parser/perf_expectations/perf_expectations.json » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 #!/usr/bin/python 1 #!/usr/bin/python
2 # Copyright (c) 2009 The Chromium Authors. All rights reserved. 2 # Copyright (c) 2009 The Chromium Authors. All rights reserved.
3 # Use of this source code is governed by a BSD-style license that can be 3 # Use of this source code is governed by a BSD-style license that can be
4 # found in the LICENSE file. 4 # found in the LICENSE file.
5 5
6 """Presubmit script for perf_expectations. 6 """Presubmit script for perf_expectations.
7 7
8 See http://dev.chromium.org/developers/how-tos/depottools/presubmit-scripts for 8 See http://dev.chromium.org/developers/how-tos/depottools/presubmit-scripts for
9 details on the presubmit API built into gcl. 9 details on the presubmit API built into gcl.
10 """ 10 """
11 11
12 UNIT_TESTS = [ 12 UNIT_TESTS = [
13 'tests.simplejson_unittest', 13 'tests.perf_expectations_unittest',
14 ] 14 ]
15 15
16 PERF_EXPECTATIONS = 'perf_expectations.json' 16 PERF_EXPECTATIONS = 'perf_expectations.json'
17 17
18 def CheckChangeOnUpload(input_api, output_api): 18 def CheckChangeOnUpload(input_api, output_api):
19 run_tests = False 19 run_tests = False
20 for path in input_api.LocalPaths(): 20 for path in input_api.LocalPaths():
21 if PERF_EXPECTATIONS == input_api.os_path.basename(path): 21 if PERF_EXPECTATIONS == input_api.os_path.basename(path):
22 run_tests = True 22 run_tests = True
23 23
(...skipping 12 matching lines...) Expand all
36 run_tests = True 36 run_tests = True
37 37
38 output = [] 38 output = []
39 if run_tests: 39 if run_tests:
40 output.extend(input_api.canned_checks.RunPythonUnitTests(input_api, 40 output.extend(input_api.canned_checks.RunPythonUnitTests(input_api,
41 output_api, 41 output_api,
42 UNIT_TESTS)) 42 UNIT_TESTS))
43 output.extend(input_api.canned_checks.CheckDoNotSubmit(input_api, 43 output.extend(input_api.canned_checks.CheckDoNotSubmit(input_api,
44 output_api)) 44 output_api))
45 return output 45 return output
OLDNEW
« no previous file with comments | « no previous file | log_parser/perf_expectations/perf_expectations.json » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698