...
1load("@io_bazel_rules_go//go:def.bzl", "go_library", "go_test")
2load("//:def.bzl", "gazelle_binary")
3
4gazelle_binary(
5 name = "gazelle_go_x",
6 # keep
7 languages = [
8 "//language/go",
9 ":gazellebinarytest",
10 ],
11)
12
13go_library(
14 name = "gazellebinarytest",
15 srcs = ["xlang.go"],
16 importpath = "github.com/bazelbuild/bazel-gazelle/internal/gazellebinarytest",
17 visibility = ["//:__subpackages__"],
18 deps = [
19 "//config",
20 "//label",
21 "//language",
22 "//repo",
23 "//resolve",
24 "//rule",
25 ],
26)
27
28go_test(
29 name = "gazellebinarytest_test",
30 srcs = ["gazellebinary_test.go"],
31 data = [":gazelle_go_x"],
32 embed = [":gazellebinarytest"],
33 rundir = ".",
34 deps = [
35 "//testtools",
36 "@io_bazel_rules_go//go/tools/bazel:go_default_library",
37 ],
38)
39
40filegroup(
41 name = "all_files",
42 testonly = True,
43 srcs = [
44 "BUILD.bazel",
45 "gazellebinary_test.go",
46 "xlang.go",
47 ],
48 visibility = ["//visibility:public"],
49)
50
51alias(
52 name = "go_default_library",
53 actual = ":gazellebinarytest",
54 visibility = ["//:__subpackages__"],
55)
View as plain text