Commit 656326d4 authored by gavinp@chromium.org's avatar gavinp@chromium.org

Permit google app engine to be installed in testing_support.

I recently needed to run presubmit tests in depot_tools, and I was helpfully told:

$ gcl presubmit mychange
... eliding stuff ...
Install google_appengine sdk in /scratch/scratch/chrome/depot_tools_git/testing_support or higher up

This was a lie. If you put google_appengine there, the same presubmit
tools that told you to install it there will fail you for numerous
style violations contained within appengine itself. This change makes
us ignore those by blacklisting google_appengine inside of
testing_support.

Review URL: https://chromiumcodereview.appspot.com/10829293

git-svn-id: svn://svn.chromium.org/chrome/trunk/tools/depot_tools@151210 0039d316-1c4b-4281-b951-d872f2087c98
parent affe7b81
......@@ -195,6 +195,7 @@ class InputApi(object):
# Path regexp that should be excluded from being considered containing source
# files. Don't modify this list from a presubmit script!
DEFAULT_BLACK_LIST = (
r"testing_support[\\\/]google_appengine[\\\/].*",
r".*\bexperimental[\\\/].*",
r".*\bthird_party[\\\/].*",
# Output directories (just in case)
......
......@@ -1026,6 +1026,17 @@ class InputApiUnittest(PresubmitTestsBase):
def f(x):
return presubmit.AffectedFile(x, 'M', self.fake_root_dir)
files = [
(
[
# To be tested.
f('testing_support/google_appengine/b'),
f('testing_support/not_google_appengine/foo.cc'),
],
[
# Expected.
'testing_support/not_google_appengine/foo.cc',
],
),
(
[
# To be tested.
......@@ -1089,7 +1100,7 @@ class InputApiUnittest(PresubmitTestsBase):
self.mox.ReplayAll()
self.assertEqual(len(input_api.DEFAULT_WHITE_LIST), 22)
self.assertEqual(len(input_api.DEFAULT_BLACK_LIST), 11)
self.assertEqual(len(input_api.DEFAULT_BLACK_LIST), 12)
for item in files:
results = filter(input_api.FilterSourceFile, item[0])
for i in range(len(results)):
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment