diff options
author | kosak <kosak@google.com> | 2015-07-24 19:07:10 (GMT) |
---|---|---|
committer | kosak <kosak@google.com> | 2015-07-24 19:07:10 (GMT) |
commit | 41b5b28d4858530a94078a5204c9d393f520159d (patch) | |
tree | be2453958d84033ca83486358e0e0784c6f928a8 /test | |
parent | c6b9fcd60ab2b9c08c01c641d5b41fb13c577ce2 (diff) | |
download | googletest-41b5b28d4858530a94078a5204c9d393f520159d.zip googletest-41b5b28d4858530a94078a5204c9d393f520159d.tar.gz googletest-41b5b28d4858530a94078a5204c9d393f520159d.tar.bz2 |
Inject implementation of *FromGTestEnv using macros.
Diffstat (limited to 'test')
-rw-r--r-- | test/gtest_unittest.cc | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/test/gtest_unittest.cc b/test/gtest_unittest.cc index dd7f19f..60aed35 100644 --- a/test/gtest_unittest.cc +++ b/test/gtest_unittest.cc @@ -1671,6 +1671,8 @@ TEST(Int32FromGTestEnvTest, ReturnsDefaultWhenVariableIsNotSet) { EXPECT_EQ(10, Int32FromGTestEnv("temp", 10)); } +# if !defined(GTEST_GET_INT32_FROM_ENV_) + // Tests that Int32FromGTestEnv() returns the default value when the // environment variable overflows as an Int32. TEST(Int32FromGTestEnvTest, ReturnsDefaultWhenValueOverflows) { @@ -1695,6 +1697,8 @@ TEST(Int32FromGTestEnvTest, ReturnsDefaultWhenValueIsInvalid) { EXPECT_EQ(50, Int32FromGTestEnv("temp", 50)); } +# endif // !defined(GTEST_GET_INT32_FROM_ENV_) + // Tests that Int32FromGTestEnv() parses and returns the value of the // environment variable when it represents a valid decimal integer in // the range of an Int32. |