Reads and returns the string environment variable corresponding to the given flag; if it's not set, returns default_value.
| 796 | // Reads and returns the string environment variable corresponding to |
| 797 | // the given flag; if it's not set, returns default_value. |
| 798 | const char* StringFromGTestEnv(const char* flag, const char* default_value) { |
| 799 | const std::string env_var = FlagToEnvVar(flag); |
| 800 | const char* const value = posix::GetEnv(env_var.c_str()); |
| 801 | return value == NULL ? default_value : value; |
| 802 | } |
| 803 | |
| 804 | } // namespace internal |
| 805 | } // namespace testing |
no test coverage detected