summaryrefslogtreecommitdiffstats
path: root/clang/unittests/Format/SortIncludesTest.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'clang/unittests/Format/SortIncludesTest.cpp')
-rw-r--r--clang/unittests/Format/SortIncludesTest.cpp8
1 files changed, 8 insertions, 0 deletions
diff --git a/clang/unittests/Format/SortIncludesTest.cpp b/clang/unittests/Format/SortIncludesTest.cpp
index a33e440abfb..0c3a95a1063 100644
--- a/clang/unittests/Format/SortIncludesTest.cpp
+++ b/clang/unittests/Format/SortIncludesTest.cpp
@@ -724,6 +724,14 @@ TEST_F(SortIncludesTest, DoNotOutputReplacementsForSortedBlocksWithRegrouping) {
EXPECT_EQ(Code, sort(Code, "input.h", 0));
}
+TEST_F(SortIncludesTest,
+ DoNotOutputReplacementsForSortedBlocksWithRegroupingWindows) {
+ Style.IncludeBlocks = Style.IBS_Regroup;
+ std::string Code = "#include \"b.h\"\r\n"
+ "\r\n"
+ "#include <a.h>\r\n";
+ EXPECT_EQ(Code, sort(Code, "input.h", 0));
+}
TEST_F(SortIncludesTest, DoNotRegroupGroupsInGoogleObjCStyle) {
FmtStyle = getGoogleStyle(FormatStyle::LK_ObjC);
OpenPOWER on IntegriCloud