• Home
  • Line#
  • Scopes#
  • Navigate#
  • Raw
  • Download
1 #include <gtest/gtest.h>
2 
add_negative_flag(const std::string & flag)3 std::string add_negative_flag(const std::string& flag) {
4   std::string filter = ::testing::GTEST_FLAG(filter);
5   if (filter.find('-') == std::string::npos) {
6     filter.push_back('-');
7   } else {
8     filter.push_back(':');
9   }
10   filter += flag;
11   return filter;
12 }
main(int argc,char * argv[])13 int main(int argc, char* argv[]) {
14     ::testing::InitGoogleTest(&argc, argv);
15     ::testing::GTEST_FLAG(filter) = add_negative_flag("*_CUDA:*_MultiCUDA");
16 
17     return RUN_ALL_TESTS();
18 }
19