aboutsummaryrefslogtreecommitdiff
path: root/clang/unittests/Tooling/CompilationDatabaseTest.cpp
diff options
context:
space:
mode:
authorRussell Gallop <russell.gallop@gmail.com>2019-07-12 15:15:56 +0000
committerRussell Gallop <russell.gallop@gmail.com>2019-07-12 15:15:56 +0000
commit614a78c15a05aff5919edc43e79bace43d583ad0 (patch)
tree5e090d2dd30b6ed66ec75c2ed8301e3673bf084e /clang/unittests/Tooling/CompilationDatabaseTest.cpp
parent1d062dae158c5ba7d1f27010d5e4178e10820ee2 (diff)
downloadllvm-614a78c15a05aff5919edc43e79bace43d583ad0.zip
llvm-614a78c15a05aff5919edc43e79bace43d583ad0.tar.gz
llvm-614a78c15a05aff5919edc43e79bace43d583ad0.tar.bz2
Revert "[JSONCompilationDatabase] Strip distcc/ccache/gomacc wrappers from parsed commands."
New test is failing on Windows bot This reverts commit 9c0391b36a76f8e3949588de3f44b7314c2318bf. llvm-svn: 365906
Diffstat (limited to 'clang/unittests/Tooling/CompilationDatabaseTest.cpp')
-rw-r--r--clang/unittests/Tooling/CompilationDatabaseTest.cpp24
1 files changed, 0 insertions, 24 deletions
diff --git a/clang/unittests/Tooling/CompilationDatabaseTest.cpp b/clang/unittests/Tooling/CompilationDatabaseTest.cpp
index 6794029..da7ae09 100644
--- a/clang/unittests/Tooling/CompilationDatabaseTest.cpp
+++ b/clang/unittests/Tooling/CompilationDatabaseTest.cpp
@@ -370,30 +370,6 @@ TEST(findCompileArgsInJsonDatabase, FindsEntry) {
EXPECT_EQ("command4", FoundCommand.CommandLine[0]) << ErrorMessage;
}
-TEST(findCompileArgsInJsonDatabase, ParsesCompilerWrappers) {
- std::vector<std::pair<std::string, std::string>> Cases = {
- {"distcc gcc foo.c", "gcc foo.c"},
- {"gomacc clang++ foo.c", "clang++ foo.c"},
- {"ccache gcc foo.c", "gcc foo.c"},
- {"ccache.exe gcc foo.c", "gcc foo.c"},
- {"ccache g++.exe foo.c", "g++.exe foo.c"},
- {"ccache distcc gcc foo.c", "gcc foo.c"},
-
- {"distcc foo.c", "distcc foo.c"},
- {"distcc -I/foo/bar foo.c", "distcc -I/foo/bar foo.c"},
- };
- std::string ErrorMessage;
-
- for (const auto &Case : Cases) {
- std::string DB = R"([{"directory":".", "file":"/foo.c", "command":")" +
- Case.first + "\"}]";
- CompileCommand FoundCommand =
- findCompileArgsInJsonDatabase("/foo.c", DB, ErrorMessage);
- EXPECT_EQ(Case.second, llvm::join(FoundCommand.CommandLine, " "))
- << Case.first;
- }
-}
-
static std::vector<std::string> unescapeJsonCommandLine(StringRef Command) {
std::string JsonDatabase =
("[{\"directory\":\"//net/root\", \"file\":\"test\", \"command\": \"" +