diff options
author | dtu@chromium.org <dtu@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2012-11-08 08:17:22 +0000 |
---|---|---|
committer | dtu@chromium.org <dtu@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2012-11-08 08:17:22 +0000 |
commit | eea2e67034a223c74ce0e8c0517f6066cc1ee143 (patch) | |
tree | 64c4082a9d8e3c0df8fa64f689c7fe7a09b0edbb /tools/telemetry/PRESUBMIT.py | |
parent | 5971ec68da0d265e7d87352dfc4cec23e65c4a2f (diff) | |
download | chromium_src-eea2e67034a223c74ce0e8c0517f6066cc1ee143.zip chromium_src-eea2e67034a223c74ce0e8c0517f6066cc1ee143.tar.gz chromium_src-eea2e67034a223c74ce0e8c0517f6066cc1ee143.tar.bz2 |
[chrome_remote_control] Rename chrome_remote_control to telemetry.
TBR=nduca@chromium.org
TBR=torne@chromium.org
BUG=159613
TEST=./run_tests in tools/telemetry and tools/perf show no regressions. (They're not passing right now.) greps for "crc", "chrome_remote_control", and related terms return no results.
Review URL: https://codereview.chromium.org/11361165
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@166638 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'tools/telemetry/PRESUBMIT.py')
-rw-r--r-- | tools/telemetry/PRESUBMIT.py | 34 |
1 files changed, 34 insertions, 0 deletions
diff --git a/tools/telemetry/PRESUBMIT.py b/tools/telemetry/PRESUBMIT.py new file mode 100644 index 0000000..6866cc2 --- /dev/null +++ b/tools/telemetry/PRESUBMIT.py @@ -0,0 +1,34 @@ +# Copyright (c) 2012 The Chromium Authors. All rights reserved. +# Use of this source code is governed by a BSD-style license that can be +# found in the LICENSE file. +import os +import sys + +PYLINT_BLACKLIST = [] +PYLINT_DISABLED_WARNINGS = ['R0923', 'R0201', 'E1101'] + +def _CommonChecks(input_api, output_api): + results = [] + old_sys_path = sys.path + try: + sys.path = [os.path.join('..', 'telemetry')] + sys.path + results.extend(input_api.canned_checks.RunPylint( + input_api, output_api, + black_list=PYLINT_BLACKLIST, + disabled_warnings=PYLINT_DISABLED_WARNINGS)) + finally: + sys.path = old_sys_path + + + + return results + +def CheckChangeOnUpload(input_api, output_api): + report = [] + report.extend(_CommonChecks(input_api, output_api)) + return report + +def CheckChangeOnCommit(input_api, output_api): + report = [] + report.extend(_CommonChecks(input_api, output_api)) + return report |