Initializes Google Test. This must be called before calling RUN_ALL_TESTS(). In particular, it parses a command line for the flags that Google Test recognizes. Whenever a Google Test flag is seen, it is removed from argv, and *argc is decremented. No value is returned. Instead, the Google Test flag variables are updated. Calling the function for the second time has no user-visible effect.
| 6658 | // |
| 6659 | // Calling the function for the second time has no user-visible effect. |
| 6660 | void InitGoogleTest(int* argc, char** argv) { |
| 6661 | #if defined(GTEST_CUSTOM_INIT_GOOGLE_TEST_FUNCTION_) |
| 6662 | GTEST_CUSTOM_INIT_GOOGLE_TEST_FUNCTION_(argc, argv); |
| 6663 | #else // defined(GTEST_CUSTOM_INIT_GOOGLE_TEST_FUNCTION_) |
| 6664 | internal::InitGoogleTestImpl(argc, argv); |
| 6665 | #endif // defined(GTEST_CUSTOM_INIT_GOOGLE_TEST_FUNCTION_) |
| 6666 | } |
| 6667 | |
| 6668 | // This overloaded version can be used in Windows programs compiled in |
| 6669 | // UNICODE mode. |