Skip to content

Commit

Permalink
Reformat all gn files in /services/
Browse files Browse the repository at this point in the history
`gn format` recently changed its formatting behavior
for deps, source, and a few other elements when they
are assigned (with =) single-element lists to be consistent
with the formatting of updates (with +=) with single-element.

Now that we've rolled in a GN binary with the change,
reformat all files so that people don't get presubmit
warnings due to this.

This CL was uploaded by me.

Bug: 1041419
Change-Id: Ie111379ff7ac2c7ef371dd354f82c11e3ebe85aa
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/2012641
Auto-Submit: Nico Weber <thakis@chromium.org>
Reviewed-by: Colin Blundell <blundell@chromium.org>
Reviewed-by: Will Harris <wfh@chromium.org>
Commit-Queue: Will Harris <wfh@chromium.org>
Cr-Commit-Position: refs/heads/master@{#733660}
  • Loading branch information
nico authored and Commit Bot committed Jan 21, 2020
1 parent 47743a2 commit 513c02f
Show file tree
Hide file tree
Showing 24 changed files with 50 additions and 145 deletions.
4 changes: 1 addition & 3 deletions services/BUILD.gn
Original file line number Diff line number Diff line change
Expand Up @@ -152,8 +152,6 @@ if (is_android) {
"//third_party/junit",
"//ui/gfx/geometry/mojom:mojom_java",
]
data = [
"test/data/",
]
data = [ "test/data/" ]
}
}
24 changes: 6 additions & 18 deletions services/data_decoder/BUILD.gn
Original file line number Diff line number Diff line change
Expand Up @@ -38,9 +38,7 @@ source_set("lib") {
"//ui/gfx/geometry",
]

public_deps = [
"//services/data_decoder/public/mojom",
]
public_deps = [ "//services/data_decoder/public/mojom" ]

if (!is_ios) {
sources += [
Expand Down Expand Up @@ -88,9 +86,7 @@ source_set("tests") {
"//gin:gin_test",
"//third_party/blink/public:blink",
]
data_deps = [
"//tools/v8_context_snapshot",
]
data_deps = [ "//tools/v8_context_snapshot" ]
configs += [
"//tools/v8_context_snapshot:use_v8_context_snapshot",
"//v8:external_startup_data",
Expand All @@ -99,9 +95,7 @@ source_set("tests") {
}

fuzzer_test("web_bundle_parser_fuzzer") {
sources = [
"web_bundle_parser_fuzzer.cc",
]
sources = [ "web_bundle_parser_fuzzer.cc" ]
deps = [
":lib",
"//base",
Expand All @@ -111,9 +105,7 @@ fuzzer_test("web_bundle_parser_fuzzer") {
}

fuzzer_test("xml_parser_fuzzer") {
sources = [
"xml_parser_fuzzer.cc",
]
sources = [ "xml_parser_fuzzer.cc" ]
deps = [
":lib",
"//base",
Expand All @@ -126,11 +118,7 @@ fuzzer_test("xml_parser_fuzzer") {

if (is_chromeos) {
fuzzer_test("ble_scan_parser_fuzzer") {
sources = [
"ble_scan_parser_impl_fuzzer.cc",
]
deps = [
":lib",
]
sources = [ "ble_scan_parser_impl_fuzzer.cc" ]
deps = [ ":lib" ]
}
}
21 changes: 6 additions & 15 deletions services/data_decoder/public/cpp/BUILD.gn
Original file line number Diff line number Diff line change
Expand Up @@ -8,13 +8,9 @@ import("//mojo/public/tools/bindings/mojom.gni")
# converted to a component target. A component target is necessary for
# ServiceProvider because it exposes global storage.
component("service_provider") {
public = [
"service_provider.h",
]
public = [ "service_provider.h" ]

sources = [
"service_provider.cc",
]
sources = [ "service_provider.cc" ]

public_deps = [
"//base",
Expand Down Expand Up @@ -51,9 +47,8 @@ source_set("cpp") {
if (is_android) {
sources += [ "json_sanitizer_android.cc" ]

deps = [
"//services/data_decoder/public/cpp/android:safe_json_jni_headers",
]
deps =
[ "//services/data_decoder/public/cpp/android:safe_json_jni_headers" ]
} else {
sources += [ "json_sanitizer_non_android.cc" ]
}
Expand All @@ -62,9 +57,7 @@ source_set("cpp") {
# NOTE: We depend on this target here for iOS only, to support in-process
# use of the service. Non-test targets in this directory should otherwise
# NEVER depend on this target.
deps = [
"//services/data_decoder:lib",
]
deps = [ "//services/data_decoder:lib" ]
} else {
public += [
"decode_image.h",
Expand All @@ -88,9 +81,7 @@ source_set("test_support") {
"test_support/web_bundle_builder.h",
]

deps = [
"//components/cbor",
]
deps = [ "//components/cbor" ]

public_deps = [
":cpp",
Expand Down
8 changes: 2 additions & 6 deletions services/device/bluetooth/BUILD.gn
Original file line number Diff line number Diff line change
Expand Up @@ -17,9 +17,7 @@ source_set("bluetooth_system") {
"bluetooth_system_factory.h",
]

public_deps = [
"//services/device/public/mojom",
]
public_deps = [ "//services/device/public/mojom" ]

deps = [
"//base",
Expand All @@ -31,9 +29,7 @@ source_set("bluetooth_system") {
source_set("bluetooth_system_tests") {
testonly = true

sources = [
"bluetooth_system_unittest.cc",
]
sources = [ "bluetooth_system_unittest.cc" ]

deps = [
":bluetooth_system",
Expand Down
4 changes: 1 addition & 3 deletions services/device/fingerprint/BUILD.gn
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,5 @@ component("fingerprint") {
sources += [ "fingerprint_default.cc" ]
}

public_deps = [
"//services/device/public/mojom",
]
public_deps = [ "//services/device/public/mojom" ]
}
4 changes: 1 addition & 3 deletions services/device/wake_lock/BUILD.gn
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,5 @@ source_set("wake_lock") {
"//ui/gfx",
]

deps = [
"//services/device/wake_lock/power_save_blocker",
]
deps = [ "//services/device/wake_lock/power_save_blocker" ]
}
16 changes: 4 additions & 12 deletions services/device/wake_lock/power_save_blocker/BUILD.gn
Original file line number Diff line number Diff line change
Expand Up @@ -20,17 +20,11 @@ source_set("power_save_blocker") {
"//services/device/wake_lock:*",
]

sources = [
"power_save_blocker.h",
]
sources = [ "power_save_blocker.h" ]

public_deps = [
"//services/device/public/mojom",
]
public_deps = [ "//services/device/public/mojom" ]

deps = [
"//base",
]
deps = [ "//base" ]

if (use_dbus) {
deps += [ "//dbus" ]
Expand Down Expand Up @@ -90,8 +84,6 @@ if (is_android) {
"//services/device:*",
]
sources = java_sources_needing_jni
deps = [
"//base:base_java",
]
deps = [ "//base:base_java" ]
}
}
4 changes: 1 addition & 3 deletions services/image_annotation/BUILD.gn
Original file line number Diff line number Diff line change
Expand Up @@ -45,9 +45,7 @@ source_set("service") {
source_set("tests") {
testonly = true

sources = [
"annotator_unittest.cc",
]
sources = [ "annotator_unittest.cc" ]

deps = [
":lib",
Expand Down
4 changes: 1 addition & 3 deletions services/image_annotation/public/cpp/BUILD.gn
Original file line number Diff line number Diff line change
Expand Up @@ -20,9 +20,7 @@ source_set("cpp") {
source_set("tests") {
testonly = true

sources = [
"image_processor_unittest.cc",
]
sources = [ "image_processor_unittest.cc" ]

deps = [
":cpp",
Expand Down
4 changes: 1 addition & 3 deletions services/image_annotation/public/mojom/BUILD.gn
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,5 @@
import("//mojo/public/tools/bindings/mojom.gni")

mojom("mojom") {
sources = [
"image_annotation.mojom",
]
sources = [ "image_annotation.mojom" ]
}
4 changes: 1 addition & 3 deletions services/metrics/public/cpp/BUILD.gn
Original file line number Diff line number Diff line change
Expand Up @@ -66,9 +66,7 @@ action("gen_ukm_builders") {
"//tools/metrics/ukm/codegen.py",
"//tools/metrics/ukm/gen_builders.py",
]
sources = [
"//tools/metrics/ukm/ukm.xml",
]
sources = [ "//tools/metrics/ukm/ukm.xml" ]

outdir = "$target_gen_dir"

Expand Down
8 changes: 2 additions & 6 deletions services/metrics/public/mojom/BUILD.gn
Original file line number Diff line number Diff line change
Expand Up @@ -5,11 +5,7 @@
import("//mojo/public/tools/bindings/mojom.gni")

mojom("mojom") {
sources = [
"ukm_interface.mojom",
]
sources = [ "ukm_interface.mojom" ]

public_deps = [
"//url/mojom:url_mojom_gurl",
]
public_deps = [ "//url/mojom:url_mojom_gurl" ]
}
8 changes: 2 additions & 6 deletions services/network/BUILD.gn
Original file line number Diff line number Diff line change
Expand Up @@ -245,9 +245,7 @@ jumbo_component("network_service") {
"//url",
]

public_deps = [
"//services/network/public/cpp:buildflags",
]
public_deps = [ "//services/network/public/cpp:buildflags" ]

if (is_ct_supported) {
sources += [
Expand Down Expand Up @@ -473,9 +471,7 @@ jumbo_source_set("test_support") {
}

fuzzer_test("network_content_security_policy_fuzzer") {
sources = [
"content_security_policy_fuzzer.cc",
]
sources = [ "content_security_policy_fuzzer.cc" ]
deps = [
"//base",
"//net",
Expand Down
20 changes: 5 additions & 15 deletions services/network/public/cpp/BUILD.gn
Original file line number Diff line number Diff line change
Expand Up @@ -185,12 +185,8 @@ jumbo_component("cpp_base") {
}

mojom("test_interfaces") {
sources = [
"network_traits_test_service.mojom",
]
public_deps = [
"//services/network/public/mojom",
]
sources = [ "network_traits_test_service.mojom" ]
public_deps = [ "//services/network/public/mojom" ]
}

source_set("tests") {
Expand Down Expand Up @@ -246,16 +242,10 @@ source_set("tests") {
"//testing/gtest",
]

public_deps = [
":buildflags",
]
public_deps = [ ":buildflags" ]
}

fuzzer_test("cors_fuzzer") {
sources = [
"cors/cors_fuzzer.cc",
]
deps = [
":cpp",
]
sources = [ "cors/cors_fuzzer.cc" ]
deps = [ ":cpp" ]
}
12 changes: 3 additions & 9 deletions services/network/public/mojom/BUILD.gn
Original file line number Diff line number Diff line change
Expand Up @@ -18,9 +18,7 @@ mojom("mojom_ip_address") {
"ip_endpoint.mojom",
]

public_deps = [
"//url/mojom:url_mojom_gurl",
]
public_deps = [ "//url/mojom:url_mojom_gurl" ]
}

# As with mojom_ip_address, this is a separate target to avoid a circular
Expand All @@ -30,13 +28,9 @@ mojom("mojom_ip_address") {
# depending on that and don't need this.
mojom("mojom_network_isolation_key") {
generate_java = true
sources = [
"network_isolation_key.mojom",
]
sources = [ "network_isolation_key.mojom" ]

public_deps = [
"//url/mojom:url_mojom_origin",
]
public_deps = [ "//url/mojom:url_mojom_origin" ]

if (!is_ios) {
export_class_attribute_blink = "BLINK_PLATFORM_EXPORT"
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -50,7 +50,5 @@ source_set("browser") {
"browser_metrics.h",
]

deps = [
"//base",
]
deps = [ "//base" ]
}
4 changes: 1 addition & 3 deletions services/service_manager/sandbox/BUILD.gn
Original file line number Diff line number Diff line change
Expand Up @@ -20,9 +20,7 @@ component("sandbox") {
"switches.h",
]
defines = [ "SERVICE_MANAGER_SANDBOX_IMPL" ]
public_deps = [
"//services/service_manager/embedder:embedder_switches",
]
public_deps = [ "//services/service_manager/embedder:embedder_switches" ]
deps = [
":sanitizer_buildflags",
"//base",
Expand Down
14 changes: 4 additions & 10 deletions services/test/BUILD.gn
Original file line number Diff line number Diff line change
Expand Up @@ -11,9 +11,7 @@ source_set("run_all_unittests") {

testonly = true

sources = [
"run_all_unittests.cc",
]
sources = [ "run_all_unittests.cc" ]

deps = [
"//base",
Expand All @@ -25,9 +23,7 @@ source_set("run_all_unittests") {
if (is_ios) {
deps += [ ":tests_bundle_data" ]
} else {
data = [
"data/",
]
data = [ "data/" ]
}

data_deps = [
Expand Down Expand Up @@ -65,8 +61,6 @@ bundle_data("tests_bundle_data") {
"//services/test/data/simple_page.html",
"//services/test/data/title1.html",
]
outputs = [
"{{bundle_resources_dir}}/" +
"{{source_root_relative_dir}}/{{source_file_part}}",
]
outputs = [ "{{bundle_resources_dir}}/" +
"{{source_root_relative_dir}}/{{source_file_part}}" ]
}
4 changes: 1 addition & 3 deletions services/test/echo/public/mojom/BUILD.gn
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,5 @@ import("//mojo/public/tools/bindings/mojom.gni")

mojom("mojom") {
generate_java = true
sources = [
"echo.mojom",
]
sources = [ "echo.mojom" ]
}
Loading

0 comments on commit 513c02f

Please sign in to comment.