summaryrefslogtreecommitdiffstats
path: root/clang-tools-extra/unittests/clang-doc/HTMLGeneratorTest.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'clang-tools-extra/unittests/clang-doc/HTMLGeneratorTest.cpp')
-rw-r--r--clang-tools-extra/unittests/clang-doc/HTMLGeneratorTest.cpp12
1 files changed, 12 insertions, 0 deletions
diff --git a/clang-tools-extra/unittests/clang-doc/HTMLGeneratorTest.cpp b/clang-tools-extra/unittests/clang-doc/HTMLGeneratorTest.cpp
index eabc6d45fe5..af3a661e6b6 100644
--- a/clang-tools-extra/unittests/clang-doc/HTMLGeneratorTest.cpp
+++ b/clang-tools-extra/unittests/clang-doc/HTMLGeneratorTest.cpp
@@ -258,6 +258,15 @@ TEST(HTMLGeneratorTest, emitCommentHTML) {
Extended->Children.back()->Kind = "TextComment";
Extended->Children.back()->Text = " continues onto the next line.";
+ Top.Children.emplace_back(llvm::make_unique<CommentInfo>());
+ CommentInfo *Entities = Top.Children.back().get();
+ Entities->Kind = "ParagraphComment";
+ Entities->Children.emplace_back(llvm::make_unique<CommentInfo>());
+ Entities->Children.back()->Kind = "TextComment";
+ Entities->Children.back()->Name = "ParagraphComment";
+ Entities->Children.back()->Text =
+ " Comment with html entities: &, <, >, \", \'.";
+
I.Description.emplace_back(std::move(Top));
auto G = getHTMLGenerator();
@@ -285,6 +294,9 @@ TEST(HTMLGeneratorTest, emitCommentHTML) {
<p>
Extended description that continues onto the next line.
</p>
+ <p>
+ Comment with html entities: &amp;, &lt;, &gt;, &quot;, &apos;.
+ </p>
</div>
</div>
</div>
OpenPOWER on IntegriCloud