aboutsummaryrefslogtreecommitdiffhomepage
path: root/src/test/java/com/google/devtools/build/skydoc/testdata/multiple_rules_test
diff options
context:
space:
mode:
Diffstat (limited to 'src/test/java/com/google/devtools/build/skydoc/testdata/multiple_rules_test')
-rw-r--r--src/test/java/com/google/devtools/build/skydoc/testdata/multiple_rules_test/golden.txt12
-rw-r--r--src/test/java/com/google/devtools/build/skydoc/testdata/multiple_rules_test/input.bzl28
2 files changed, 40 insertions, 0 deletions
diff --git a/src/test/java/com/google/devtools/build/skydoc/testdata/multiple_rules_test/golden.txt b/src/test/java/com/google/devtools/build/skydoc/testdata/multiple_rules_test/golden.txt
new file mode 100644
index 0000000000..b1a4a66325
--- /dev/null
+++ b/src/test/java/com/google/devtools/build/skydoc/testdata/multiple_rules_test/golden.txt
@@ -0,0 +1,12 @@
+my_rule
+This is my rule. It does stuff.
+first,second
+
+other_rule
+This is another rule.
+third,fourth
+
+yet_another_rule
+This is yet another rule
+fifth
+
diff --git a/src/test/java/com/google/devtools/build/skydoc/testdata/multiple_rules_test/input.bzl b/src/test/java/com/google/devtools/build/skydoc/testdata/multiple_rules_test/input.bzl
new file mode 100644
index 0000000000..b1c0538231
--- /dev/null
+++ b/src/test/java/com/google/devtools/build/skydoc/testdata/multiple_rules_test/input.bzl
@@ -0,0 +1,28 @@
+def my_rule_impl(ctx):
+ return struct()
+
+my_rule = rule(
+ implementation = my_rule_impl,
+ doc = "This is my rule. It does stuff.",
+ attrs = {
+ "first": attr.label(mandatory = True, allow_files = True, single_file = True),
+ "second": attr.string_dict(mandatory = True),
+ },
+)
+
+other_rule = rule(
+ implementation = my_rule_impl,
+ doc = "This is another rule.",
+ attrs = {
+ "third": attr.label(mandatory = True, allow_files = True, single_file = True),
+ "fourth": attr.string_dict(mandatory = True),
+ },
+)
+
+yet_another_rule = rule(
+ implementation = my_rule_impl,
+ doc = "This is yet another rule",
+ attrs = {
+ "fifth": attr.label(mandatory = True, allow_files = True, single_file = True),
+ },
+)