Move parseFontFaceDescriptor to CSSPropertyParser.cpp
[chromium-blink-merge.git] / third_party / WebKit / Source / devtools / front_end / cm_modes / PRESUBMIT.py
bloba769412ae9bcb0685308af523837ccc44c209565
1 # Copyright 2015 The Chromium Authors. All rights reserved.
2 # Use of this source code is governed by a BSD-style license that can be
3 # found in the LICENSE file.
6 def _CheckCodeMirrorChanges(input_api, output_api):
7 errorText = ("ERROR: Attempt to modify CodeMirror. The only allowed changes are "
8 "rolls from the upstream (http://codemirror.net). If this is a roll, "
9 "make sure you mention 'roll CodeMirror' (no quotes) in the change description.\n"
10 "CodeMirror rolling instructions:\n"
11 " https://sites.google.com/a/chromium.org/devtools-codemirror-rolling")
12 changeDescription = input_api.change.DescriptionText()
13 errors = []
14 if "roll codemirror" not in changeDescription.lower():
15 errors.append(output_api.PresubmitError(errorText))
16 return errors
19 def CheckChangeOnUpload(input_api, output_api):
20 results = []
21 results.extend(_CheckCodeMirrorChanges(input_api, output_api))
22 return results