aboutsummaryrefslogtreecommitdiffhomepage
path: root/PRESUBMIT.py
diff options
context:
space:
mode:
authorGravatar rmistry <rmistry@google.com>2015-03-12 08:43:22 -0700
committerGravatar Commit bot <commit-bot@chromium.org>2015-03-12 08:43:22 -0700
commitd1783aefcc0da86c5ff1d124c54704252d817621 (patch)
tree4778a2fa41dc86e3658d759ec6a1bef61a2b8896 /PRESUBMIT.py
parent95553d917c73ef333ede967521560957a5b6a0ad (diff)
Ignore public API checks if COMMIT=false is in the description
Diffstat (limited to 'PRESUBMIT.py')
-rw-r--r--PRESUBMIT.py7
1 files changed, 7 insertions, 0 deletions
diff --git a/PRESUBMIT.py b/PRESUBMIT.py
index d62249a605..b5397042b2 100644
--- a/PRESUBMIT.py
+++ b/PRESUBMIT.py
@@ -143,6 +143,8 @@ def CheckChangeOnUpload(input_api, output_api):
"""
results = []
results.extend(_CommonChecks(input_api, output_api))
+ # TODO(rmistry): Remove the below it is only for testing!!!
+ results.extend(_CheckLGTMsForPublicAPI(input_api, output_api))
return results
@@ -254,6 +256,11 @@ def _CheckLGTMsForPublicAPI(input_api, output_api):
# It is a revert CL, ignore the public api owners check.
return results
+ if re.search(r'^COMMIT=false$', issue_properties['description'], re.M):
+ # Ignore public api owners check for COMMIT=false CLs since they are not
+ # going to be committed.
+ return results
+
match = re.search(r'^TBR=(.*)$', issue_properties['description'], re.M)
if match:
tbr_entries = match.group(1).strip().split(',')