forked from OSchip/llvm-project
[Frontend] Fix broken createInvocation test due to bad merge
This commit is contained in:
parent
687ccba198
commit
f44552ab38
|
@ -49,14 +49,16 @@ TEST(BuildCompilerInvocationTest, ProbePrecompiled) {
|
|||
clang::CompilerInstance::createDiagnostics(new DiagnosticOptions, &D,
|
||||
false);
|
||||
// Default: ProbePrecompiled is true.
|
||||
std::unique_ptr<CompilerInvocation> CI = createInvocationFromCommandLine(
|
||||
Args, CommandLineDiagsEngine, FS, false, nullptr);
|
||||
CreateInvocationOptions CIOpts;
|
||||
CIOpts.Diags = CommandLineDiagsEngine;
|
||||
CIOpts.VFS = FS;
|
||||
std::unique_ptr<CompilerInvocation> CI = createInvocation(Args, CIOpts);
|
||||
ASSERT_TRUE(CI);
|
||||
EXPECT_THAT(CI->getPreprocessorOpts().Includes, ElementsAre());
|
||||
EXPECT_EQ(CI->getPreprocessorOpts().ImplicitPCHInclude, "foo.h.pch");
|
||||
|
||||
CI = createInvocationFromCommandLine(Args, CommandLineDiagsEngine, FS, false,
|
||||
nullptr, /*ProbePrecompiled=*/false);
|
||||
CIOpts.ProbePrecompiled = false;
|
||||
CI = createInvocation(Args, CIOpts);
|
||||
ASSERT_TRUE(CI);
|
||||
EXPECT_THAT(CI->getPreprocessorOpts().Includes, ElementsAre("foo.h"));
|
||||
EXPECT_EQ(CI->getPreprocessorOpts().ImplicitPCHInclude, "");
|
||||
|
|
Loading…
Reference in New Issue