-
Notifications
You must be signed in to change notification settings - Fork 32
Expand file tree
/
Copy pathBUILD.bazel
More file actions
107 lines (92 loc) · 3.1 KB
/
BUILD.bazel
File metadata and controls
107 lines (92 loc) · 3.1 KB
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
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
load("@com_google_protobuf//bazel:java_proto_library.bzl", "java_proto_library")
load("@com_google_protobuf//bazel:proto_library.bzl", "proto_library")
load("//:java_lite_proto_cel_library.bzl", "java_lite_proto_cel_library")
load("//:java_lite_proto_cel_library_impl.bzl", "java_lite_proto_cel_library_impl")
package(
default_applicable_licenses = [
"//:license",
],
default_testonly = True,
default_visibility = [
"//testing/protos:__pkg__",
],
)
proto_library(
name = "single_file_proto",
srcs = ["single_file.proto"],
)
java_proto_library(
name = "single_file_java_proto",
tags = [
],
deps = [":single_file_proto"],
)
proto_library(
name = "multi_file_proto",
srcs = [
"multi_file.proto",
],
deps = [":single_file_proto"],
)
proto_library(
name = "message_with_enum_proto",
srcs = ["message_with_enum.proto"],
)
java_proto_library(
name = "message_with_enum_java_proto",
deps = [":message_with_enum_proto"],
)
# Test only. java_proto_library supports generating a jar with multiple proto deps,
# so we must test this case as well for lite descriptors.
# buildifier: disable=LANG_proto_library-single-deps
java_proto_library(
name = "multi_file_java_proto",
deps = [
":multi_file_proto",
":single_file_proto",
],
)
java_lite_proto_cel_library(
name = "multi_file_cel_java_proto_lite",
deps = [
":multi_file_proto",
":single_file_proto",
],
)
java_lite_proto_cel_library(
name = "test_all_types_cel_java_proto2_lite",
deps = ["@cel_spec//proto/cel/expr/conformance/proto2:test_all_types_proto"],
)
java_lite_proto_cel_library(
name = "test_all_types_cel_java_proto3_lite",
deps = ["@cel_spec//proto/cel/expr/conformance/proto3:test_all_types_proto"],
)
# The below targets exist to exercise lite descriptor tests against the full protobuf runtime (thus the overridden java_proto_library_dep).
# Use cases outside CEL should follow the example above.
java_lite_proto_cel_library_impl(
name = "multi_file_cel_java_proto",
java_descriptor_class_suffix = "CelDescriptor",
java_proto_library_dep = ":multi_file_java_proto",
deps = [
":multi_file_proto",
":single_file_proto",
],
)
java_lite_proto_cel_library_impl(
name = "test_all_types_cel_java_proto2",
java_descriptor_class_suffix = "CelDescriptor",
java_proto_library_dep = "@cel_spec//proto/cel/expr/conformance/proto2:test_all_types_java_proto",
deps = ["@cel_spec//proto/cel/expr/conformance/proto2:test_all_types_proto"],
)
java_lite_proto_cel_library_impl(
name = "test_all_types_cel_java_proto3",
java_descriptor_class_suffix = "CelDescriptor",
java_proto_library_dep = "@cel_spec//proto/cel/expr/conformance/proto3:test_all_types_java_proto",
deps = ["@cel_spec//proto/cel/expr/conformance/proto3:test_all_types_proto"],
)
java_lite_proto_cel_library_impl(
name = "message_with_enum_cel_java_proto",
java_descriptor_class_suffix = "CelDescriptor",
java_proto_library_dep = ":message_with_enum_java_proto",
deps = [":message_with_enum_proto"],
)