Skip to content

Commit 1f44880

Browse files
committed
[clangd] Extract string literals in macro arguments to unbreak gcc buildbots
(cherry picked from commit 041650d)
1 parent a27142b commit 1f44880

File tree

1 file changed

+7
-4
lines changed

1 file changed

+7
-4
lines changed

clang-tools-extra/clangd/unittests/HoverTests.cpp

Lines changed: 7 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1759,20 +1759,23 @@ TEST(Hover, PresentRulers) {
17591759
HI.Value = "val";
17601760
HI.Definition = "def";
17611761

1762-
EXPECT_EQ(HI.present().asMarkdown(), R"md(### variable `foo`
1762+
llvm::StringRef ExpectedMarkdown = R"md(### variable `foo`
17631763
17641764
---
17651765
Value \= `val`
17661766
17671767
---
17681768
```cpp
17691769
def
1770-
```)md");
1771-
EXPECT_EQ(HI.present().asPlainText(), R"pt(variable foo
1770+
```)md";
1771+
EXPECT_EQ(HI.present().asMarkdown(), ExpectedMarkdown);
1772+
1773+
llvm::StringRef ExpectedPlaintext = R"pt(variable foo
17721774
17731775
Value = val
17741776
1775-
def)pt");
1777+
def)pt";
1778+
EXPECT_EQ(HI.present().asPlainText(), ExpectedPlaintext);
17761779
}
17771780

17781781
TEST(Hover, ExprTests) {

0 commit comments

Comments
 (0)