aboutsummaryrefslogtreecommitdiffstats
path: root/googletest/test/gtest_output_test_.cc
diff options
context:
space:
mode:
authorGennadiy Civil <gennadiycivil@users.noreply.github.com>2018-01-18 09:47:22 -0500
committerGitHub <noreply@github.com>2018-01-18 09:47:22 -0500
commit8d733dc19525c4c898a85f9ae02713f42fe6d083 (patch)
treebaefd7543494c50239a21602dbb0fd89ca939770 /googletest/test/gtest_output_test_.cc
parent1b077667bd950be0f5b106e033fb820b008ad0c0 (diff)
parent8e862211a24804d6635adc867f9b9199220e1128 (diff)
downloadgoogletest-8d733dc19525c4c898a85f9ae02713f42fe6d083.tar.gz
googletest-8d733dc19525c4c898a85f9ae02713f42fe6d083.tar.bz2
googletest-8d733dc19525c4c898a85f9ae02713f42fe6d083.zip
Merge pull request #1407 from ted-xp/master
Expose ScopedTrace utility in public interface
Diffstat (limited to 'googletest/test/gtest_output_test_.cc')
-rw-r--r--googletest/test/gtest_output_test_.cc7
1 files changed, 7 insertions, 0 deletions
diff --git a/googletest/test/gtest_output_test_.cc b/googletest/test/gtest_output_test_.cc
index 6aaba977..04ca5e5e 100644
--- a/googletest/test/gtest_output_test_.cc
+++ b/googletest/test/gtest_output_test_.cc
@@ -315,6 +315,13 @@ TEST(SCOPED_TRACETest, WorksConcurrently) {
}
#endif // GTEST_IS_THREADSAFE
+// Tests basic functionality of the ScopedTrace utility (most of its features
+// are already tested in SCOPED_TRACETest).
+TEST(ScopedTraceTest, WithExplicitFileAndLine) {
+ testing::ScopedTrace trace("explicit_file.cc", 123, "expected trace message");
+ ADD_FAILURE() << "Check that the trace is attached to a particular location.";
+}
+
TEST(DisabledTestsWarningTest,
DISABLED_AlsoRunDisabledTestsFlagSuppressesWarning) {
// This test body is intentionally empty. Its sole purpose is for