Bazel: Don't ship test dependencies in plugin artifact
Adding test dependencies to the EXTERNAL_DEPS constant ends up in
shipping all transitive test dependencies: easymock, powermock and
friends in the plugin artifact. To rectify split the constant in
two and only add test dependencies to the test rules.
Change-Id: Ieac92ef9c56cca98e6c91bf69ea60a66ebd0b31b
diff --git a/BUILD b/BUILD
index b52c2c1..548e6a8 100644
--- a/BUILD
+++ b/BUILD
@@ -1,6 +1,6 @@
load("//tools:genrule2.bzl", "genrule2")
load("//tools/bzl:plugin.bzl", "PLUGIN_TEST_DEPS")
-load("//owners-common:common.bzl", "EXTERNAL_DEPS")
+load("//owners-common:common.bzl", "EXTERNAL_DEPS", "EXTERNAL_TEST_DEPS")
genrule2(
name = "all",
@@ -21,7 +21,7 @@
name = "owners_classpath_deps",
testonly = 1,
visibility = ["//visibility:public"],
- exports = EXTERNAL_DEPS + PLUGIN_TEST_DEPS + [
+ exports = EXTERNAL_DEPS + EXTERNAL_TEST_DEPS + PLUGIN_TEST_DEPS + [
"//owners:owners__plugin",
"//owners-autoassign:owners-autoassign__plugin",
"//owners-common:owners-common__plugin",