summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--googletest/test/googletest-param-test-test.cc38
1 files changed, 1 insertions, 37 deletions
diff --git a/googletest/test/googletest-param-test-test.cc b/googletest/test/googletest-param-test-test.cc
index 05e0b23..c78623a 100644
--- a/googletest/test/googletest-param-test-test.cc
+++ b/googletest/test/googletest-param-test-test.cc
@@ -67,43 +67,7 @@ using ::testing::internal::UnitTestOptions;
// EXPECT_THAT() and the matchers know how to print tuples.
template <typename T>
::std::string PrintValue(const T& value) {
- ::std::stringstream stream;
- stream << value;
- return stream.str();
-}
-
-// These overloads allow printing tuples in our tests. We cannot
-// define an operator<< for tuples, as that definition needs to be in
-// the std namespace in order to be picked up by Google Test via
-// Argument-Dependent Lookup, yet defining anything in the std
-// namespace in non-STL code is undefined behavior.
-
-template <typename T1, typename T2>
-::std::string PrintValue(const std::tuple<T1, T2>& value) {
- ::std::stringstream stream;
- stream << "(" << std::get<0>(value) << ", " << std::get<1>(value) << ")";
- return stream.str();
-}
-
-template <typename T1, typename T2, typename T3>
-::std::string PrintValue(const std::tuple<T1, T2, T3>& value) {
- ::std::stringstream stream;
- stream << "(" << std::get<0>(value) << ", " << std::get<1>(value) << ", "
- << std::get<2>(value) << ")";
- return stream.str();
-}
-
-template <typename T1, typename T2, typename T3, typename T4, typename T5,
- typename T6, typename T7, typename T8, typename T9, typename T10>
-::std::string PrintValue(
- const std::tuple<T1, T2, T3, T4, T5, T6, T7, T8, T9, T10>& value) {
- ::std::stringstream stream;
- stream << "(" << std::get<0>(value) << ", " << std::get<1>(value) << ", "
- << std::get<2>(value) << ", " << std::get<3>(value) << ", "
- << std::get<4>(value) << ", " << std::get<5>(value) << ", "
- << std::get<6>(value) << ", " << std::get<7>(value) << ", "
- << std::get<8>(value) << ", " << std::get<9>(value) << ")";
- return stream.str();
+ return testing::PrintToString(value);
}
// Verifies that a sequence generated by the generator and accessed