From f04cbe39a07f7c34a742378b16dd47d9a2b6e476 Mon Sep 17 00:00:00 2001 From: Ulf Adams Date: Fri, 28 Oct 2016 13:23:41 +0000 Subject: Small docs updates for the extra action rule. Add the product name to the ConfiguredRuleClassProvider so that the doc generator can generate the proper links to the user manual. -- MOS_MIGRATED_REVID=137505460 --- .../google/devtools/build/docgen/RuleLinkExpanderTest.java | 13 +++++++++++-- 1 file changed, 11 insertions(+), 2 deletions(-) (limited to 'src/test/java/com/google') diff --git a/src/test/java/com/google/devtools/build/docgen/RuleLinkExpanderTest.java b/src/test/java/com/google/devtools/build/docgen/RuleLinkExpanderTest.java index fbacd0c080..cea22dace2 100644 --- a/src/test/java/com/google/devtools/build/docgen/RuleLinkExpanderTest.java +++ b/src/test/java/com/google/devtools/build/docgen/RuleLinkExpanderTest.java @@ -36,8 +36,8 @@ public class RuleLinkExpanderTest { .put("Fileset", "fileset") .put("proto_library", "protocol-buffer") .build(); - multiPageExpander = new RuleLinkExpander(index, false); - singlePageExpander = new RuleLinkExpander(index, true); + multiPageExpander = new RuleLinkExpander("product-name", index, false); + singlePageExpander = new RuleLinkExpander("product-name", index, true); } private void checkExpandSingle(String docs, String expected) { @@ -111,6 +111,15 @@ public class RuleLinkExpanderTest { "Common Definitions"); } + @Test public void testUserManualRefIncludesProductName() { + checkExpandMulti( + "Link", + "Link"); + checkExpandSingle( + "Link", + "Link"); + } + @Test(expected = IllegalArgumentException.class) public void testRefNotFound() { String docs = "bar"; -- cgit v1.2.3