[clang-tools-extra] [clang-doc] Add Markdown AST node type definitions (PR #205609)
Paul Kirth via cfe-commits
cfe-commits at lists.llvm.org
Wed Jun 24 11:53:54 PDT 2026
================
@@ -0,0 +1,73 @@
+#include "support/Markdown.h"
+#include "llvm/Support/Allocator.h"
+#include "llvm/Support/Casting.h"
+#include "gtest/gtest.h"
+
+using namespace clang::doc::markdown;
+using namespace llvm;
+
+namespace {
+
+TEST(MarkdownNodeTest, TextNode) {
+ BumpPtrAllocator Arena;
+ auto *N = new (Arena) TextNode("hello");
+ EXPECT_EQ(N->Kind, NodeKind::NK_Text);
+ EXPECT_EQ(N->Text, "hello");
+ EXPECT_TRUE(isa<TextNode>(N));
----------------
ilovepi wrote:
I'm not sure this is a property with testing. the llvm casting support is checked in LLVM's tests. I think you can omit this from all the other tests as well.
https://github.com/llvm/llvm-project/pull/205609
More information about the cfe-commits
mailing list