add unit test

This commit is contained in:
Joel Hock 2017-12-19 00:16:21 -06:00 committed by Jacob Dufault
parent bea5b38bc5
commit 4b420c53d3

View File

@ -511,6 +511,14 @@ TEST_SUITE("Project") {
"-Wno-unknown-warning-option"}); "-Wno-unknown-warning-option"});
} }
TEST_CASE("Implied binary") {
CheckFlags("/home/user", "/home/user/foo/bar.cc",
/* raw */ {"-DDONT_IGNORE_ME"},
/* expected */ {"clang++", "-DDONT_IGNORE_ME", "-xc++", "-std=c++11",
"-resource-dir=/w/resource_dir/",
"-Wno-unknown-warning-option"});
}
// Checks flag parsing for a random chromium file in comparison to what // Checks flag parsing for a random chromium file in comparison to what
// YouCompleteMe fetches. // YouCompleteMe fetches.
TEST_CASE("ycm") { TEST_CASE("ycm") {