diff --git a/test/gtest_env_var_test.py b/test/gtest_env_var_test.py index 64d17e85..1b86b5a9 100755 --- a/test/gtest_env_var_test.py +++ b/test/gtest_env_var_test.py @@ -101,6 +101,7 @@ def TestEnvVarAffectsFlag(command): TestFlag(command, 'color', 'yes', 'auto') TestFlag(command, 'filter', 'FooTest.Bar', '*') TestFlag(command, 'output', 'tmp/foo.xml', '') + TestFlag(command, 'print_time', '1', '0') TestFlag(command, 'repeat', '999', '1') if IS_WINDOWS: diff --git a/test/gtest_env_var_test_.cc b/test/gtest_env_var_test_.cc index 81056e84..16b31103 100644 --- a/test/gtest_env_var_test_.cc +++ b/test/gtest_env_var_test_.cc @@ -81,6 +81,11 @@ void PrintFlag(const char* flag) { return; } + if (strcmp(flag, "print_time") == 0) { + cout << GTEST_FLAG(print_time); + return; + } + if (strcmp(flag, "repeat") == 0) { cout << GTEST_FLAG(repeat); return;