aboutsummaryrefslogtreecommitdiff
path: root/clang/unittests/libclang/LibclangTest.cpp
diff options
context:
space:
mode:
authorBen Langmuir <blangmuir@apple.com>2014-07-07 17:34:37 +0000
committerBen Langmuir <blangmuir@apple.com>2014-07-07 17:34:37 +0000
commite218cd77b4d49da5ebf9e978d510a4a612eab8fd (patch)
tree3da1e8b30dee33e9e9fad027b5f9f3ed7ed16a5a /clang/unittests/libclang/LibclangTest.cpp
parent1f6f6e60adf754fa57c31f7bdeede46aec1f7dc9 (diff)
downloadllvm-e218cd77b4d49da5ebf9e978d510a4a612eab8fd.zip
llvm-e218cd77b4d49da5ebf9e978d510a4a612eab8fd.tar.gz
llvm-e218cd77b4d49da5ebf9e978d510a4a612eab8fd.tar.bz2
Use temporary module cache in test
llvm-svn: 212467
Diffstat (limited to 'clang/unittests/libclang/LibclangTest.cpp')
-rw-r--r--clang/unittests/libclang/LibclangTest.cpp4
1 files changed, 3 insertions, 1 deletions
diff --git a/clang/unittests/libclang/LibclangTest.cpp b/clang/unittests/libclang/LibclangTest.cpp
index 8f2694f..ef162bc 100644
--- a/clang/unittests/libclang/LibclangTest.cpp
+++ b/clang/unittests/libclang/LibclangTest.cpp
@@ -434,7 +434,9 @@ TEST_F(LibclangReparseTest, ReparseWithModule) {
WriteFile(HeaderName, std::string(HeaderTop) + HeaderBottom);
WriteFile(ModName, ModFile);
- const char *Args[] = { "-fmodules", "-I", TestDir.c_str() };
+ std::string ModulesCache = std::string("-fmodules-cache-path=") + TestDir;
+ const char *Args[] = { "-fmodules", ModulesCache.c_str(),
+ "-I", TestDir.c_str() };
int NumArgs = sizeof(Args) / sizeof(Args[0]);
ClangTU = clang_parseTranslationUnit(Index, MName.c_str(), Args, NumArgs,
nullptr, 0, TUFlags);