forked from qt-creator/qt-creator
ClangSupport: Fix CommandLineBuilder
Forgot to add macros. Change-Id: I4a5ab969a6b99c110b3ffd9e8f2b59560ccfc8b9 Reviewed-by: Ivan Donchevskii <ivan.donchevskii@qt.io>
This commit is contained in:
@@ -509,4 +509,20 @@ TYPED_TEST(CommandLineBuilder, IncludePchPath)
|
||||
"/source/file.cpp"));
|
||||
}
|
||||
|
||||
TYPED_TEST(CommandLineBuilder, CompilerMacros)
|
||||
{
|
||||
this->emptyProjectInfo.compilerMacros = {{"YI", "1", 2}, {"ER", "2", 1}};
|
||||
|
||||
Builder<TypeParam> builder{this->emptyProjectInfo};
|
||||
|
||||
ASSERT_THAT(builder.commandLine,
|
||||
ElementsAre("clang++",
|
||||
"-x",
|
||||
"c++-header",
|
||||
"-std=c++98",
|
||||
"-nostdinc",
|
||||
"-nostdlibinc",
|
||||
"-DER=2",
|
||||
"-DYI=1"));
|
||||
}
|
||||
} // namespace
|
||||
|
||||
Reference in New Issue
Block a user