diff options
Diffstat (limited to 'googletest/scripts/gen_gtest_pred_impl.py')
-rwxr-xr-x | googletest/scripts/gen_gtest_pred_impl.py | 14 |
1 files changed, 9 insertions, 5 deletions
diff --git a/googletest/scripts/gen_gtest_pred_impl.py b/googletest/scripts/gen_gtest_pred_impl.py index b43efdf..7294277 100755 --- a/googletest/scripts/gen_gtest_pred_impl.py +++ b/googletest/scripts/gen_gtest_pred_impl.py @@ -111,6 +111,8 @@ def HeaderPreamble(n): // '%(command)s'. DO NOT EDIT BY HAND! // // Implements a family of generic predicate assertion macros. +// GOOGLETEST_CM0001 DO NOT DELETE + #ifndef GTEST_INCLUDE_GTEST_GTEST_PRED_IMPL_H_ #define GTEST_INCLUDE_GTEST_GTEST_PRED_IMPL_H_ @@ -246,8 +248,10 @@ AssertionResult AssertPred%(n)sHelper(const char* pred_text""" % DEFS impl += ' << ") evaluates to false, where"' - impl += Iter(n, """ - << "\\n" << e%s << " evaluates to " << v%s""") + impl += Iter( + n, """ + << "\\n" << e%s << " evaluates to " << ::testing::PrintToString(v%s)""" + ) impl += """; } @@ -510,7 +514,7 @@ struct PredFormatFunctor%(n)s { class Predicate%(n)sTest : public testing::Test { protected: - virtual void SetUp() { + void SetUp() override { expected_to_finish_ = true; finished_ = false;""" % DEFS @@ -520,7 +524,7 @@ class Predicate%(n)sTest : public testing::Test { """ tests += """ - virtual void TearDown() { + void TearDown() override { // Verifies that each of the predicate's arguments was evaluated // exactly once.""" @@ -588,7 +592,7 @@ typedef Predicate%(n)sTest ASSERT_PRED%(n)sTest; if use_assert: assrt = 'ASSERT' # 'assert' is reserved, so we cannot use - # that identifier here. + # that identifier here. else: assrt = 'EXPECT' |