Commit df195fd5 authored by Ben Pastene's avatar Ben Pastene Committed by Commit Bot

Add a yapf style to //build/chromeos/ and auto-format all python files.

Format all the things!

Change-Id: I33f02e6e21c4388f381b35e06394fb916bfddddd
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/1891735
Commit-Queue: Ben Pastene <bpastene@chromium.org>
Reviewed-by: default avatarJohn Budorick <jbudorick@chromium.org>
Cr-Commit-Position: refs/heads/master@{#711845}
parent 1a685434
[style]
based_on_style = chromium
# Copyright (c) 2013 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.
"""Presubmit script for build/chromeos/.
See http://dev.chromium.org/developers/how-tos/depottools/presubmit-scripts for
......@@ -11,9 +10,7 @@ details on the presubmit API built into depot_tools.
def CommonChecks(input_api, output_api):
return input_api.canned_checks.RunPylint(
input_api,
output_api,
pylintrc='pylintrc')
input_api, output_api, pylintrc='pylintrc')
def CheckChangeOnUpload(input_api, output_api):
......
......@@ -3,7 +3,6 @@
# Copyright 2018 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.
"""Creates a script that runs a CrOS VM test by delegating to
build/chromeos/test_runner.py.
"""
......@@ -12,7 +11,6 @@ import argparse
import os
import sys
SCRIPT_TEMPLATE = """\
#!/usr/bin/env python
#
......@@ -90,7 +88,8 @@ def main(args):
vm_test_args.append('--deploy-chrome')
vm_test_args += [
'--board', args.board,
'--board',
args.board,
'-v',
]
if args.use_vm:
......@@ -100,17 +99,18 @@ def main(args):
('--cros-cache', RelativizePathToScript(args.cros_cache)),
]
if args.runtime_deps_path:
vm_test_path_args.append(
('--runtime-deps-path', RelativizePathToScript(args.runtime_deps_path)))
vm_test_path_args.append(('--runtime-deps-path',
RelativizePathToScript(args.runtime_deps_path)))
if args.output_directory:
vm_test_path_args.append(
('--path-to-outdir', RelativizePathToScript(args.output_directory)))
vm_test_path_args.append(('--path-to-outdir',
RelativizePathToScript(args.output_directory)))
with open(args.script_output_path, 'w') as script:
script.write(SCRIPT_TEMPLATE.format(
vm_test_script=run_test_path,
vm_test_args=str(vm_test_args),
vm_test_path_args=str(vm_test_path_args)))
script.write(
SCRIPT_TEMPLATE.format(
vm_test_script=run_test_path,
vm_test_args=str(vm_test_args),
vm_test_path_args=str(vm_test_path_args)))
os.chmod(args.script_output_path, 0750)
......
This diff is collapsed.
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