Skip to content

Commit

Permalink
[bazel] Run buildifier. No logical changes.
Browse files Browse the repository at this point in the history
Command invocation was:

   buildifier -r -lint fix -type auto .
  • Loading branch information
shs96c committed Apr 24, 2021
1 parent 3e5ffdf commit 83e80c2
Show file tree
Hide file tree
Showing 37 changed files with 42 additions and 65 deletions.
8 changes: 3 additions & 5 deletions WORKSPACE
Original file line number Diff line number Diff line change
Expand Up @@ -64,12 +64,12 @@ rbe_autoconfig(name = "rbe_default")

http_archive(
name = "rules_python",
url = "https://github.com/bazelbuild/rules_python/releases/download/0.2.0/rules_python-0.2.0.tar.gz",
sha256 = "778197e26c5fbeb07ac2a2c5ae405b30f6cb7ad1f5510ea6fdac03bded96cc6f",
url = "https://github.com/bazelbuild/rules_python/releases/download/0.2.0/rules_python-0.2.0.tar.gz",
)

# This one is only needed if you're using the packaging rules.
load("@rules_python//python:pip.bzl", "pip_install", "pip_repositories")
load("@rules_python//python:pip.bzl", "pip_install")

pip_install(
name = "dev_requirements",
Expand Down Expand Up @@ -224,7 +224,7 @@ http_archive(
url = "https://github.com/bazelbuild/rules_k8s/archive/v0.6.tar.gz",
)

load("@io_bazel_rules_k8s//k8s:k8s.bzl", "k8s_repositories")
load("@io_bazel_rules_k8s//k8s:k8s.bzl", "k8s_defaults", "k8s_repositories")

k8s_repositories()

Expand All @@ -242,8 +242,6 @@ go_rules_dependencies()

go_register_toolchains()

load("@io_bazel_rules_k8s//k8s:k8s.bzl", "k8s_defaults")

k8s_defaults(
name = "k8s_dev",
cluster = "docker-desktop",
Expand Down
6 changes: 3 additions & 3 deletions common/repositories.bzl
Original file line number Diff line number Diff line change
Expand Up @@ -182,9 +182,9 @@ def _firefox():
url = _versions["firefox"]["mac"]["url"],
sha256 = _versions["firefox"]["mac"]["sha256"],
build_file_content = "exports_files([\"Firefox.app\"])",
# move = {
# "Firefox.tmp1.pkg/Payload/Firefox.app": "Firefox.app",
# }
# move = {
# "Firefox.tmp1.pkg/Payload/Firefox.app": "Firefox.app",
# }
)

# TODO: figure out how to unpack the firefox exe on Windows
Expand Down
7 changes: 2 additions & 5 deletions deploys/docker/BUILD.bazel
Original file line number Diff line number Diff line change
@@ -1,10 +1,8 @@
package(default_visibility = ["//deploys/k8s:__pkg__"])

load("@io_bazel_rules_docker//java:image.bzl", "java_image")
load("@io_bazel_rules_docker//contrib:passwd.bzl", "passwd_entry", "passwd_file")
load("@io_bazel_rules_docker//container:container.bzl", "container_image", "container_layer", "container_push")
load("@rules_pkg//:pkg.bzl", "pkg_tar")
load("//common:defs.bzl", "copy_file")

package(default_visibility = ["//deploys/k8s:__pkg__"])

REGISTRY = "localhost:5000"

Expand Down Expand Up @@ -145,7 +143,6 @@ container_image(
],
)


container_layer(
name = "grid-binary",
directory = "/opt/selenium/bin",
Expand Down
1 change: 0 additions & 1 deletion deploys/k8s/BUILD.bazel
Original file line number Diff line number Diff line change
@@ -1,5 +1,4 @@
load("@k8s_dev//:defaults.bzl", "k8s_dev")
load("@io_bazel_rules_k8s//k8s:object.bzl", "k8s_object")
load("@io_bazel_rules_k8s//k8s:objects.bzl", "k8s_objects")

k8s_objects(
Expand Down
2 changes: 1 addition & 1 deletion dotnet/private/executable_assembly.bzl
Original file line number Diff line number Diff line change
Expand Up @@ -100,7 +100,7 @@ def create_executable_assembly(ctx, extra_srcs, extra_deps):

direct_runfiles = [result[0].out, result[0].pdb]
if runtimeconfig != None:
direct_runfiles += [runtimeconfig]
direct_runfiles.append(runtimeconfig)

result.append(DefaultInfo(
executable = shell_file,
Expand Down
2 changes: 1 addition & 1 deletion dotnet/selenium-dotnet-version.bzl
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
# BUILD FILE SYNTAX: SKYLARK
# BUILD FILE SYNTAX: STARLARK

SE_VERSION = "4.0.0-beta2"
ASSEMBLY_VERSION = "4.0.0.0"
Expand Down
1 change: 0 additions & 1 deletion dotnet/src/webdriver/BUILD.bazel
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,6 @@ load(
"ASSEMBLY_PRODUCT",
"ASSEMBLY_VERSION",
"SE_VERSION",
"SUPPORTED_DEVTOOLS_VERSIONS",
"SUPPORTED_NET_FRAMEWORKS",
"SUPPORTED_NET_STANDARD_VERSIONS",
)
Expand Down
8 changes: 4 additions & 4 deletions java/client/src/org/openqa/selenium/BUILD.bazel
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
load("//java:version.bzl", "SE_VERSION")
load("//java:defs.bzl", "java_dist_zip", "java_export", "java_import", "java_library", "javadoc")
load("//java:defs.bzl", "java_dist_zip", "java_export", "java_import", "javadoc")
load("//java/client/src/org/openqa/selenium/devtools:versions.bzl", "CDP_DEPS")

filegroup(
Expand Down Expand Up @@ -41,6 +41,9 @@ java_export(
name = "client-combined",
maven_coordinates = "org.seleniumhq.selenium:selenium-java:" + SE_VERSION,
pom_template = ":template-pom",
visibility = [
"//visibility:public",
],
exports = [
":core",
"//java/client/src/org/openqa/selenium/chrome",
Expand All @@ -53,9 +56,6 @@ java_export(
"//java/client/src/org/openqa/selenium/safari",
"//java/client/src/org/openqa/selenium/support",
] + CDP_DEPS,
visibility = [
"//visibility:public",
],
)

java_dist_zip(
Expand Down
1 change: 0 additions & 1 deletion java/client/src/org/openqa/selenium/edge/BUILD.bazel
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
load("@rules_jvm_external//:defs.bzl", "artifact")
load("//java:defs.bzl", "java_export")
load("//java:version.bzl", "SE_VERSION")

Expand Down
1 change: 0 additions & 1 deletion java/client/src/org/openqa/selenium/ie/BUILD.bazel
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
load("@rules_jvm_external//:defs.bzl", "artifact")
load("//java:defs.bzl", "java_export")
load("//java:version.bzl", "SE_VERSION")

Expand Down
1 change: 0 additions & 1 deletion java/client/src/org/openqa/selenium/opera/BUILD.bazel
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
load("@rules_jvm_external//:defs.bzl", "artifact")
load("//java:defs.bzl", "java_export")
load("//java:version.bzl", "SE_VERSION")

Expand Down
2 changes: 1 addition & 1 deletion java/client/src/org/openqa/selenium/remote/BUILD.bazel
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
load("@rules_jvm_external//:defs.bzl", "artifact")
load("//common:defs.bzl", "copy_file")
load("//java:defs.bzl", "java_dist_zip", "java_export", "java_library")
load("//java:defs.bzl", "java_export")
load("//java:version.bzl", "SE_VERSION")

java_export(
Expand Down
1 change: 0 additions & 1 deletion java/client/src/org/openqa/selenium/safari/BUILD.bazel
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
load("@rules_jvm_external//:defs.bzl", "artifact")
load("//java:defs.bzl", "java_export")
load("//java:version.bzl", "SE_VERSION")

Expand Down
1 change: 0 additions & 1 deletion java/client/src/org/openqa/selenium/support/BUILD.bazel
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
load("@rules_jvm_external//:defs.bzl", "artifact")
load("//java:defs.bzl", "java_export", "java_library")
load("//java:version.bzl", "SE_VERSION")

Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
load("@rules_jvm_external//:defs.bzl", "artifact")
load("//java:defs.bzl", "java_library")

java_library(
Expand Down
11 changes: 5 additions & 6 deletions java/client/test/org/openqa/selenium/firefox/BUILD.bazel
Original file line number Diff line number Diff line change
Expand Up @@ -15,14 +15,14 @@ java_test_suite(
["*.java"],
exclude = LARGE_TESTS,
),
data = [
":firebug_xpi",
"//third_party/firebug:firebug-1.5.0-fx.xpi",
"//third_party/firebug:mooltipass-1.1.87.xpi",
],
tags = [
"requires-network",
],
data = [
"//third_party/firebug:firebug-1.5.0-fx.xpi",
"//third_party/firebug:mooltipass-1.1.87.xpi",
":firebug_xpi"
],
deps = [
"//java/client/src/org/openqa/selenium/firefox",
"//java/client/src/org/openqa/selenium/remote",
Expand Down Expand Up @@ -72,4 +72,3 @@ copy_file(
src = "//third_party/firebug:firebug-1.5.0-fx.xpi",
out = "firebug-1.5.0-fx.xpi",
)

Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
load("@rules_jvm_external//:defs.bzl", "artifact")
load("//java:defs.bzl", "java_selenium_test_suite", "java_test_suite")
load("//java:defs.bzl", "java_test_suite")

java_test_suite(
name = "medium-tests",
Expand Down
2 changes: 1 addition & 1 deletion java/client/test/org/openqa/selenium/html5/BUILD.bazel
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
load("@rules_jvm_external//:defs.bzl", "artifact")
load("//java:defs.bzl", "java_library", "java_selenium_test_suite")
load("//java:defs.bzl", "java_selenium_test_suite")

java_selenium_test_suite(
name = "large-tests",
Expand Down
1 change: 0 additions & 1 deletion java/client/test/org/openqa/selenium/mobile/BUILD.bazel
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
load("@rules_java//java:defs.bzl", "java_test")
load("@rules_jvm_external//:defs.bzl", "artifact")
load("//java:defs.bzl", "java_selenium_test_suite")

Expand Down
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
load("@rules_jvm_external//:defs.bzl", "artifact")
load("//java:defs.bzl", "java_selenium_test_suite", "java_test_suite")
load("//java:defs.bzl", "java_selenium_test_suite")

java_selenium_test_suite(
name = "MediumTests",
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -43,6 +43,7 @@ java_library(
exports = [
":browser",
],
runtime_deps = CDP_DEPS,
deps = [
":browser",
"//java/client/src/org/openqa/selenium:core",
Expand All @@ -61,5 +62,4 @@ java_library(
artifact("junit:junit"),
artifact("org.seleniumhq.selenium:htmlunit-driver"),
],
runtime_deps = CDP_DEPS,
)
Original file line number Diff line number Diff line change
@@ -1,5 +1,3 @@
load("//java:defs.bzl", "java_test_suite")

# Disabled until we actually have a test. Where did it go?

#java_test_suite(
Expand Down
2 changes: 1 addition & 1 deletion java/private/dist_info.bzl
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
load("//java/private:common.bzl", "MavenInfo", "explode_coordinates", "has_maven_deps", "read_coordinates")
load("//java/private:common.bzl", "MavenInfo", "explode_coordinates", "read_coordinates")
load("//java/private:module.bzl", "JavaModuleInfo")

DistInfo = provider(
Expand Down
1 change: 0 additions & 1 deletion java/private/export.bzl
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,6 @@ load(
"@rules_jvm_external//:defs.bzl",
"javadoc",
"pom_file",
_java_export = "java_export",
)
load("@rules_jvm_external//private/rules:maven_project_jar.bzl", "maven_project_jar")
load("@rules_jvm_external//private/rules:maven_publish.bzl", "maven_publish")
Expand Down
1 change: 0 additions & 1 deletion java/private/library.bzl
Original file line number Diff line number Diff line change
@@ -1,7 +1,6 @@
load("@apple_rules_lint//lint:defs.bzl", "get_lint_config")
load(
"@rules_java//java:defs.bzl",
_java_binary = "java_binary",
_java_library = "java_library",
_java_test = "java_test",
)
Expand Down
3 changes: 2 additions & 1 deletion java/private/module.bzl
Original file line number Diff line number Diff line change
Expand Up @@ -153,7 +153,8 @@ def _java_module_impl(ctx):
output_source_jar = ctx.actions.declare_file("lib%s-src.jar" % ctx.attr.name),
source_jars = depset(
items = ctx.attr.target[JavaInfo].source_jars,
transitive = [info.source_jars for info in all_infos if not info.name]).to_list(),
transitive = [info.source_jars for info in all_infos if not info.name],
).to_list(),
java_toolchain = ctx.attr._java_toolchain[java_common.JavaToolchainInfo],
host_javabase = ctx.attr._javabase[java_common.JavaRuntimeInfo],
)
Expand Down
2 changes: 1 addition & 1 deletion java/private/selenium_test.bzl
Original file line number Diff line number Diff line change
Expand Up @@ -56,7 +56,7 @@ BROWSERS = {
},
}

def selenium_test(name, test_class, size = "medium", browsers = BROWSERS.keys() , **kwargs):
def selenium_test(name, test_class, size = "medium", browsers = BROWSERS.keys(), **kwargs):
if len(browsers) == 0:
fail("At least one browser must be specified.")

Expand Down
2 changes: 1 addition & 1 deletion java/private/suite.bzl
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
load(":library.bzl", "java_library", "java_test")
load(":selenium_test.bzl", "BROWSERS", "DEFAULT_BROWSER", "selenium_test")
load(":selenium_test.bzl", "BROWSERS", "selenium_test")
load(":package.bzl", "package_name")

_test_attrs = [
Expand Down
1 change: 0 additions & 1 deletion java/server/src/org/openqa/selenium/cli/BUILD.bazel
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
load("@rules_jvm_external//:defs.bzl", "artifact")
load("//java:defs.bzl", "java_library")

java_library(
Expand Down
1 change: 0 additions & 1 deletion java/server/src/org/openqa/selenium/grid/data/BUILD.bazel
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
load("@rules_jvm_external//:defs.bzl", "artifact")
load("//java:defs.bzl", "java_library")

java_library(
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -11,8 +11,8 @@ java_library(
],
deps = [
"//java/client/src/org/openqa/selenium/remote",
"//java/server/src/org/openqa/selenium/events",
"//java/server/src/org/openqa/selenium/concurrent",
"//java/server/src/org/openqa/selenium/events",
"//java/server/src/org/openqa/selenium/grid/config",
"//java/server/src/org/openqa/selenium/grid/data",
"//java/server/src/org/openqa/selenium/grid/jmx",
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
load("//java:defs.bzl", "java_library", "artifact")
load("//java:defs.bzl", "artifact", "java_library")

java_library(
name = "testing",
Expand Down
6 changes: 3 additions & 3 deletions javascript/webdriver/atoms/inject/BUILD.bazel
Original file line number Diff line number Diff line change
@@ -1,12 +1,12 @@
load("@io_bazel_rules_closure//closure:defs.bzl", "closure_js_deps", "closure_js_library")
load("//javascript:defs.bzl", "closure_fragment")

package(
default_visibility = [
"//javascript/android-atoms:__pkg__",
],
)

load("@io_bazel_rules_closure//closure:defs.bzl", "closure_js_deps", "closure_js_library")
load("//javascript:defs.bzl", "closure_fragment")

closure_js_deps(
name = "deps",
visibility = [
Expand Down
8 changes: 4 additions & 4 deletions py/BUILD.bazel
Original file line number Diff line number Diff line change
@@ -1,16 +1,16 @@
load("@rules_python//python:defs.bzl", "py_binary", "py_library", "py_test")
load("@rules_python//python:defs.bzl", "py_binary", "py_library")
load("@rules_python//python:packaging.bzl", "py_package", "py_wheel")
load("@dev_requirements//:requirements.bzl", "requirement")
load("//common:defs.bzl", "copy_file")
load("//py:defs.bzl", "py_test_suite", "pytest_test")
load("//py:defs.bzl", "py_test_suite")
load("//py/private:browsers.bzl", "BROWSERS")

BROWSER_VERSIONS = [
"v85",
"v88",
"v89",
"v90",
"v91"
"v91",
]

TEST_DEPS = [
Expand All @@ -31,7 +31,7 @@ TEST_DEPS = [
requirement("pytest-mock"),
requirement("sortedcontainers"),
requirement("sniffio"),
requirement("zipp")
requirement("zipp"),
]

copy_file(
Expand Down
6 changes: 3 additions & 3 deletions py/private/browsers.bzl
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@ chrome_args = select({
"@selenium//common:use_local_chromedriver": [
"--driver-binary=$(location @selenium//common:chromedriver)",
],
"//conditions:default": []
"//conditions:default": [],
}) + headless_args

edge_args = select({
Expand All @@ -36,7 +36,7 @@ edge_args = select({
"@selenium//common:use_local_msedgedriver": [
"--driver-binary=$(location @selenium//common:msedgedriver)",
],
"//conditions:default": []
"//conditions:default": [],
}) + headless_args

firefox_args = select({
Expand Down Expand Up @@ -79,5 +79,5 @@ BROWSERS = {
"args": ["--driver=safari"],
"data": [],
"tags": COMMON_TAGS + ["safari"],
}
},
}
3 changes: 0 additions & 3 deletions third_party/dotnet/devtools/src/generator/BUILD.bazel
Original file line number Diff line number Diff line change
Expand Up @@ -6,9 +6,6 @@ load(
"ASSEMBLY_INFORMATIONAL_VERSION",
"ASSEMBLY_PRODUCT",
"ASSEMBLY_VERSION",
"SE_VERSION",
"SUPPORTED_NET_FRAMEWORKS",
"SUPPORTED_NET_STANDARD_VERSIONS",
)

generated_assembly_info(
Expand Down
2 changes: 1 addition & 1 deletion third_party/dotnet/ilmerge/BUILD.bazel
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
load(":toolchain.bzl", "configure_toolchain", "merge_toolchain")
load(":toolchain.bzl", "merge_toolchain")

licenses(["notice"])

Expand Down

0 comments on commit 83e80c2

Please sign in to comment.