Lines Matching refs:input_api
31 def _CheckCommitMessageFormatting(input_api, output_api): argument
68 git_output = input_api.change.DescriptionText()
180 def _CheckChangeHasBugField(input_api, output_api): argument
182 bugs = input_api.change.BugsFromDescription()
223 def _CheckCodeGeneration(input_api, output_api): argument
239 code_gen_path = input_api.os_path.join(input_api.PresubmitLocalPath(),
242 cmd = [input_api.python_executable, code_gen_path, '--verify-no-dirty']
243 test_cmd = input_api.Command(name=cmd_name, cmd=cmd, kwargs={}, message=Msg)
244 if input_api.verbose:
246 return input_api.RunTests([test_cmd])
250 def _CheckNewHeaderWithoutGnChange(input_api, output_api): argument
257 return input_api.FilterSourceFile(f, files_to_check=(r'.+%s' % _HEADER_EXTENSIONS,))
260 for f in input_api.AffectedSourceFiles(headers):
266 return input_api.FilterSourceFile(f, files_to_check=(r'.+\.gn',))
269 for f in input_api.AffectedSourceFiles(gn_files):
275 basename = input_api.os_path.basename(header)
292 def _CheckExportValidity(input_api, output_api): argument
296 use_shell = input_api.is_windows
305 export_target_script = os.path.join(input_api.PresubmitLocalPath(), 'scripts',
313 if input_api.is_committing:
325 def _CheckTabsInSourceFiles(input_api, output_api): argument
330 return input_api.FilterSourceFile(
333 files_to_skip=[f for f in input_api.DEFAULT_FILES_TO_SKIP if not "third_party" in f])
336 for f in input_api.AffectedSourceFiles(implementation_and_headers_including_third_party):
360 def _CheckNonAsciiInSourceFiles(input_api, output_api): argument
364 return input_api.FilterSourceFile(
368 for f in input_api.AffectedSourceFiles(implementation_and_headers):
385 def CheckChangeOnUpload(input_api, output_api): argument
387 results.extend(_CheckTabsInSourceFiles(input_api, output_api))
388 results.extend(_CheckNonAsciiInSourceFiles(input_api, output_api))
389 results.extend(_CheckCodeGeneration(input_api, output_api))
390 results.extend(_CheckChangeHasBugField(input_api, output_api))
391 results.extend(input_api.canned_checks.CheckChangeHasDescription(input_api, output_api))
392 results.extend(_CheckNewHeaderWithoutGnChange(input_api, output_api))
393 results.extend(_CheckExportValidity(input_api, output_api))
395 input_api.canned_checks.CheckPatchFormatted(
396 input_api, output_api, result_factory=output_api.PresubmitError))
397 results.extend(_CheckCommitMessageFormatting(input_api, output_api))
401 def CheckChangeOnCommit(input_api, output_api): argument
402 return CheckChangeOnUpload(input_api, output_api)