Skip to content

Commit 243a1d4

Browse files
cushonrules_java Copybara
authored andcommitted
Fix a .jar file in java_import.runtime_deps
Wrap it in a separate `java_import` instead. This fixes a java_jars_in_deps_allowlist violation (b/479392897) and doesn't alter the meaning of the test. PiperOrigin-RevId: 863594466 Change-Id: I77bdb2cabdb7394ab95df452df6437a74b202bba
1 parent e910554 commit 243a1d4

1 file changed

Lines changed: 6 additions & 1 deletion

File tree

test/java/common/rules/java_import_tests.bzl

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -658,11 +658,16 @@ def _test_duplicate_jars_through_filegroup_impl(env, target):
658658

659659
def _test_runtime_deps_are_not_on_classpath(name):
660660
target_name = name + "/depends_on_runtimedep"
661+
util.helper_target(
662+
java_import,
663+
name = target_name + "/import_runtime",
664+
jars = ["import_runtime.jar"],
665+
)
661666
util.helper_target(
662667
java_import,
663668
name = target_name + "/import_dep",
664669
jars = ["import_compile.jar"],
665-
runtime_deps = ["import_runtime.jar"],
670+
runtime_deps = [target_name + "/import_runtime"],
666671
)
667672
util.helper_target(
668673
java_library,

0 commit comments

Comments
 (0)