remove GTEST_HAS_PARAM_TESTS

As mentioned in issue #360:
"Now that all the platforms gtest supports work with value-parameterized
tests, we should remove the uses of the GTEST_HAS_PARAM_TESTS macro from
the codebase everywhere."
https://github.com/google/googletest/issues/360
This commit is contained in:
Herbert Thielen
2017-09-04 19:38:35 +02:00
parent 7c6353d29a
commit aa0b5458a1
16 changed files with 4 additions and 112 deletions

View File

@@ -40,7 +40,6 @@
#include "gtest/gtest.h"
namespace {
#if GTEST_HAS_PARAM_TEST
using ::testing::TestWithParam;
using ::testing::Values;
@@ -116,15 +115,4 @@ INSTANTIATE_TEST_CASE_P(OnTheFlyAndPreCalculated, PrimeTableTestSmpl7,
Values(&CreateOnTheFlyPrimeTable,
&CreatePreCalculatedPrimeTable<1000>));
#else
// Google Test may not support value-parameterized tests with some
// compilers. If we use conditional compilation to compile out all
// code referring to the gtest_main library, MSVC linker will not link
// that library at all and consequently complain about missing entry
// point defined in that library (fatal error LNK1561: entry point
// must be defined). This dummy test keeps gtest_main linked in.
TEST(DummyTest, ValueParameterizedTestsAreNotSupportedOnThisPlatform) {}
#endif // GTEST_HAS_PARAM_TEST
} // namespace