Skip to content

Commit 88934a8

Browse files
committed
[clang-format][NFC] Remove extraneous newlines in some unit test files
1 parent 4ec9cda commit 88934a8

File tree

7 files changed

+160
-160
lines changed

7 files changed

+160
-160
lines changed

clang/unittests/Format/ConfigParseTest.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -849,7 +849,7 @@ TEST(ConfigParseTest, ParsesConfiguration) {
849849
" Priority: 2\n"
850850
" - Regex: .*\n"
851851
" Priority: 1\n"
852-
" CaseSensitive: true\n",
852+
" CaseSensitive: true",
853853
IncludeStyle.IncludeCategories, ExpectedCategories);
854854
CHECK_PARSE("IncludeIsMainRegex: 'abc$'", IncludeStyle.IncludeIsMainRegex,
855855
"abc$");

clang/unittests/Format/DefinitionBlockSeparatorTest.cpp

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -140,7 +140,7 @@ TEST_F(DefinitionBlockSeparatorTest, Basic) {
140140

141141
verifyFormat("enum Foo { FOO, BAR };\n"
142142
"\n"
143-
"enum Bar { FOOBAR, BARFOO };\n",
143+
"enum Bar { FOOBAR, BARFOO };",
144144
Style);
145145

146146
FormatStyle BreakAfterReturnTypeStyle = Style;
@@ -158,7 +158,7 @@ TEST_F(DefinitionBlockSeparatorTest, Basic) {
158158
" int r = t * p;\n"
159159
" return r;\n"
160160
" }\n"
161-
"}\n",
161+
"}",
162162
BreakAfterReturnTypeStyle);
163163
}
164164

clang/unittests/Format/FormatTestCSharp.cpp

Lines changed: 14 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -530,19 +530,19 @@ TEST_F(FormatTestCSharp, AttributesIndentation) {
530530
verifyFormat("[SuppressMessage(\"A\", \"B\", Justification = \"C\")]\n"
531531
"public override X Y()\n"
532532
"{\n"
533-
"}\n",
533+
"}",
534534
Style);
535535

536536
verifyFormat("[SuppressMessage]\n"
537537
"public X Y()\n"
538538
"{\n"
539-
"}\n",
539+
"}",
540540
Style);
541541

542542
verifyFormat("[SuppressMessage]\n"
543543
"public override X Y()\n"
544544
"{\n"
545-
"}\n",
545+
"}",
546546
Style);
547547

548548
verifyFormat("public A(B b) : base(b)\n"
@@ -551,7 +551,7 @@ TEST_F(FormatTestCSharp, AttributesIndentation) {
551551
" public override X Y()\n"
552552
" {\n"
553553
" }\n"
554-
"}\n",
554+
"}",
555555
Style);
556556

557557
verifyFormat("public A : Base\n"
@@ -560,7 +560,7 @@ TEST_F(FormatTestCSharp, AttributesIndentation) {
560560
"[Test]\n"
561561
"public Foo()\n"
562562
"{\n"
563-
"}\n",
563+
"}",
564564
Style);
565565

566566
verifyFormat("namespace\n"
@@ -572,7 +572,7 @@ TEST_F(FormatTestCSharp, AttributesIndentation) {
572572
"public Foo()\n"
573573
"{\n"
574574
"}\n"
575-
"}\n",
575+
"}",
576576
Style);
577577
}
578578

@@ -1561,15 +1561,15 @@ TEST_F(FormatTestCSharp, NamespaceIndentation) {
15611561
"public interface Name1\n"
15621562
"{\n"
15631563
"}\n"
1564-
"}\n",
1564+
"}",
15651565
Style);
15661566

15671567
verifyFormat("namespace A.B\n"
15681568
"{\n"
15691569
"public interface Name1\n"
15701570
"{\n"
15711571
"}\n"
1572-
"}\n",
1572+
"}",
15731573
Style);
15741574

15751575
Style.NamespaceIndentation = FormatStyle::NI_Inner;
@@ -1582,7 +1582,7 @@ TEST_F(FormatTestCSharp, NamespaceIndentation) {
15821582
" {\n"
15831583
" }\n"
15841584
"}\n"
1585-
"}\n",
1585+
"}",
15861586
Style);
15871587

15881588
Style.NamespaceIndentation = FormatStyle::NI_All;
@@ -1592,7 +1592,7 @@ TEST_F(FormatTestCSharp, NamespaceIndentation) {
15921592
" public interface Name1\n"
15931593
" {\n"
15941594
" }\n"
1595-
"}\n",
1595+
"}",
15961596
Style);
15971597

15981598
verifyFormat("namespace A\n"
@@ -1603,7 +1603,7 @@ TEST_F(FormatTestCSharp, NamespaceIndentation) {
16031603
" {\n"
16041604
" }\n"
16051605
" }\n"
1606-
"}\n",
1606+
"}",
16071607
Style);
16081608
}
16091609

@@ -1613,7 +1613,7 @@ TEST_F(FormatTestCSharp, SwitchExpression) {
16131613
" 1 => (0 + 0 + 0 + 0 + 0 + 0 + 0 + 0 + 0 + 0 + 0),\n"
16141614
" 2 => 1,\n"
16151615
" _ => 2\n"
1616-
"};\n",
1616+
"};",
16171617
Style);
16181618
}
16191619

@@ -1625,12 +1625,12 @@ TEST_F(FormatTestCSharp, EmptyShortBlock) {
16251625
" doA();\n"
16261626
"} catch (Exception e) {\n"
16271627
" e.printStackTrace();\n"
1628-
"}\n",
1628+
"}",
16291629
Style);
16301630

16311631
verifyFormat("try {\n"
16321632
" doA();\n"
1633-
"} catch (Exception e) {}\n",
1633+
"} catch (Exception e) {}",
16341634
Style);
16351635
}
16361636

0 commit comments

Comments
 (0)