Skip to content

Commit

Permalink
Allow setting visibility for java_test_suite libraries (#44)
Browse files Browse the repository at this point in the history
Currently, there is no way for other packages to depend on the
implicitly generated test library. This allows for a BUILD file author
to opt in to making the generated test library more visible.

This re-uses the visibility attribute which is also currently used for
the visibility of the generated `test_suite`. This feels less fiddly
than introducing a separate attribute.
  • Loading branch information
illicitonion authored Jun 29, 2022
1 parent f0c5bbe commit 26c6f1d
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions java/private/create_jvm_test_suite.bzl
Original file line number Diff line number Diff line change
Expand Up @@ -81,6 +81,7 @@ def create_jvm_test_suite(
deps = deps,
srcs = nontest_srcs,
testonly = True,
visibility = visibility,
**library_attrs
)
deps.append(":%s-test-lib" % name)
Expand Down

0 comments on commit 26c6f1d

Please sign in to comment.