diff --git a/tests/BUILD.bazel b/tests/BUILD.bazel index 331a0691d..e871466d8 100644 --- a/tests/BUILD.bazel +++ b/tests/BUILD.bazel @@ -15,6 +15,7 @@ rust_test( rust_library( name = "cxx_test_suite", + testonly = True, srcs = [ "ffi/cast.rs", "ffi/lib.rs", @@ -25,11 +26,11 @@ rust_library( ":impl", "//:cxx", ], - testonly = True, ) cc_library( name = "impl", + testonly = True, srcs = [ "ffi/tests.cc", ":bridge/source", @@ -41,19 +42,18 @@ cc_library( ":module/include", "//:core", ], - testonly = True, ) rust_cxx_bridge( name = "bridge", + testonly = True, src = "ffi/lib.rs", deps = [":impl"], - testonly = True, ) rust_cxx_bridge( name = "module", + testonly = True, src = "ffi/module.rs", deps = [":impl"], - testonly = True, ) diff --git a/tools/bazel/rust_cxx_bridge.bzl b/tools/bazel/rust_cxx_bridge.bzl index e010e1d40..48aac83c5 100644 --- a/tools/bazel/rust_cxx_bridge.bzl +++ b/tools/bazel/rust_cxx_bridge.bzl @@ -14,13 +14,13 @@ def rust_cxx_bridge(name, src, deps = [], **kwargs): native.alias( name = "%s/header" % name, actual = src + ".h", - **kwargs, + **kwargs ) native.alias( name = "%s/source" % name, actual = src + ".cc", - **kwargs, + **kwargs ) run_binary( @@ -38,18 +38,18 @@ def rust_cxx_bridge(name, src, deps = [], **kwargs): "$(location %s.cc)" % src, ], tool = "@cxx.rs//:codegen", - **kwargs, + **kwargs ) cc_library( name = name, srcs = [src + ".cc"], deps = deps + [":%s/include" % name], - **kwargs, + **kwargs ) cc_library( name = "%s/include" % name, hdrs = [src + ".h"], - **kwargs, + **kwargs )