aboutsummaryrefslogtreecommitdiff
path: root/tests/gtest/src/gtest-test-part.cc
diff options
context:
space:
mode:
authorRiccardo Spagni <ric@spagni.net>2015-03-24 08:48:43 +0200
committerRiccardo Spagni <ric@spagni.net>2015-03-24 08:48:43 +0200
commit1c49d6b2d392f67df18cfa8103584957c1bfe562 (patch)
treeeed9fa17abebf81016c6d569051350c747ebdd74 /tests/gtest/src/gtest-test-part.cc
parentMerge pull request #238 (diff)
downloadmonero-1c49d6b2d392f67df18cfa8103584957c1bfe562.tar.xz
updated gtest to latest
Diffstat (limited to 'tests/gtest/src/gtest-test-part.cc')
-rw-r--r--tests/gtest/src/gtest-test-part.cc12
1 files changed, 6 insertions, 6 deletions
diff --git a/tests/gtest/src/gtest-test-part.cc b/tests/gtest/src/gtest-test-part.cc
index 5ddc67c1c..fb0e35425 100644
--- a/tests/gtest/src/gtest-test-part.cc
+++ b/tests/gtest/src/gtest-test-part.cc
@@ -35,9 +35,9 @@
// Indicates that this translation unit is part of Google Test's
// implementation. It must come before gtest-internal-inl.h is
-// included, or there will be a compiler error. This trick is to
-// prevent a user from accidentally including gtest-internal-inl.h in
-// his code.
+// included, or there will be a compiler error. This trick exists to
+// prevent the accidental inclusion of gtest-internal-inl.h in the
+// user's code.
#define GTEST_IMPLEMENTATION_ 1
#include "src/gtest-internal-inl.h"
#undef GTEST_IMPLEMENTATION_
@@ -48,10 +48,10 @@ using internal::GetUnitTestImpl;
// Gets the summary of the failure message by omitting the stack trace
// in it.
-internal::String TestPartResult::ExtractSummary(const char* message) {
+std::string TestPartResult::ExtractSummary(const char* message) {
const char* const stack_trace = strstr(message, internal::kStackTraceMarker);
- return stack_trace == NULL ? internal::String(message) :
- internal::String(message, stack_trace - message);
+ return stack_trace == NULL ? message :
+ std::string(message, stack_trace);
}
// Prints a TestPartResult object.