Inject implementation of *FromGTestEnv using macros.
This commit is contained in:
@@ -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.
|
||||
|
||||
Reference in New Issue
Block a user