From 0bf7bacb4ff36fa0c213c8fbb69ce8f389d4f55c Mon Sep 17 00:00:00 2001 From: Nikolai Kosjar Date: Fri, 22 May 2020 10:18:48 +0200 Subject: [PATCH] Clang: Disable a clangformat test for vanilla clang ...that requires a custom patch to work. Change-Id: I954286f47112b660dc6ee681dac2250a9e8da0df Reviewed-by: Christian Kandeler --- tests/unit/unittest/clangformat-test.cpp | 9 ++++++++- 1 file changed, 8 insertions(+), 1 deletion(-) diff --git a/tests/unit/unittest/clangformat-test.cpp b/tests/unit/unittest/clangformat-test.cpp index 172afb64c8b..822f4b76d25 100644 --- a/tests/unit/unittest/clangformat-test.cpp +++ b/tests/unit/unittest/clangformat-test.cpp @@ -198,7 +198,14 @@ TEST_F(ClangFormat, IndentLambdaWithReturnType) "}")); } -TEST_F(ClangFormat, IndentFunctionArgumentLambdaWithNextLineScope) +#ifndef KEEP_LINE_BREAKS_FOR_NON_EMPTY_LINES_BACKPORTED +# define DISABLED_FOR_VANILLA_CLANG(x) DISABLED_##x +#else +# define DISABLED_FOR_VANILLA_CLANG(x) x +#endif + +// This test requires the custom clang patch https://code.qt.io/cgit/clang/llvm-project.git/commit/?h=release_100-based&id=9b992a0f7f160dd6c75f20a4dcfcf7c60a4894df +TEST_F(ClangFormat, DISABLED_FOR_VANILLA_CLANG(IndentFunctionArgumentLambdaWithNextLineScope)) { insertLines({"foo([]()", "{",