forked from qt-creator/qt-creator
ClangFormat: Reduce dummy text to minimum size
... and tweak continuation dummy text to fix the indentation for the line with existing text inside parenthesis. Change-Id: Iaebd2f58823fcbeed24bb7e47769af53261c18ca Reviewed-by: Marco Bubke <marco.bubke@qt.io>
This commit is contained in:
@@ -478,6 +478,19 @@ TEST_F(ClangFormat, SameIndentAfterSecondNewLineInsideIfWithFunctionCall)
|
||||
" )"));
|
||||
}
|
||||
|
||||
TEST_F(ClangFormat, SameIndentAfterSecondNonEmptyNewLineInsideIfWithFunctionCall)
|
||||
{
|
||||
insertLines({"if (foo()",
|
||||
" ",
|
||||
"bar)"});
|
||||
|
||||
indenter.indentBlock(doc.findBlockByNumber(2), QChar::Null, TextEditor::TabSettings());
|
||||
|
||||
ASSERT_THAT(documentLines(), ElementsAre("if (foo()",
|
||||
" ",
|
||||
" bar)"));
|
||||
}
|
||||
|
||||
TEST_F(ClangFormat, SameIndentsOnNewLinesAfterComments)
|
||||
{
|
||||
insertLines({"namespace {} //comment",
|
||||
|
||||
Reference in New Issue
Block a user