aboutsummaryrefslogtreecommitdiffhomepage
path: root/src/tools/runfiles/java/com/google/devtools/build/runfiles/BUILD
blob: c988e82658080837988135fc73f2fee9c14abf13 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
package(default_visibility = ["//visibility:private"])

filegroup(
    name = "srcs",
    srcs = glob(
        ["**"],
        exclude = [".*"],  # .swp files and such
    ),
    visibility = ["//src/tools/runfiles:__pkg__"],
)

filegroup(
    name = "java-srcs",
    srcs = [
        "Runfiles.java",
        "Util.java",
    ],
)

filegroup(
    name = "embedded_tools",
    srcs = [
        "BUILD.tools",
        ":java-srcs",
    ],
    visibility = ["//src/tools/runfiles:__pkg__"],
)

java_library(
    name = "runfiles",
    srcs = [":java-srcs"],
)

java_test(
    name = "RunfilesTest",
    srcs = ["RunfilesTest.java"],
    deps = [":test_deps"],
)

java_test(
    name = "UtilTest",
    srcs = ["UtilTest.java"],
    deps = [":test_deps"],
)

java_library(
    name = "test_deps",
    testonly = 1,
    exports = [
        ":mock-file",
        ":runfiles",
        "//third_party:guava",
        "//third_party:guava-testlib",
        "//third_party:junit4",
        "//third_party:truth",
    ],
)

java_library(
    name = "mock-file",
    testonly = 1,
    srcs = ["MockFile.java"],
    exports = ["//third_party:guava"],
    deps = ["//third_party:guava"],
)

test_suite(
    name = "windows_tests",
    tags = [
        "-no_windows",
        "-slow",
    ],
)

test_suite(
    name = "all_windows_tests",
    tests = [
        ":windows_tests",
    ],
    visibility = ["//src/tools/runfiles:__pkg__"],
)