summaryrefslogtreecommitdiffstats
path: root/base/debug_util_unittest.cc
diff options
context:
space:
mode:
authorsatorux@chromium.org <satorux@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2010-01-25 12:29:35 +0000
committersatorux@chromium.org <satorux@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2010-01-25 12:29:35 +0000
commitd89fe9a43a9ee0f4b93ca8e1776bf281f85ef8f6 (patch)
tree374246dbe52c1b38301faa487f14b1907f0b4cf2 /base/debug_util_unittest.cc
parentb84167f708bc75d06bb175850d292778426d701c (diff)
downloadchromium_src-d89fe9a43a9ee0f4b93ca8e1776bf281f85ef8f6.zip
chromium_src-d89fe9a43a9ee0f4b93ca8e1776bf281f85ef8f6.tar.gz
chromium_src-d89fe9a43a9ee0f4b93ca8e1776bf281f85ef8f6.tar.bz2
Revert 36997 - Import googleglog's Symbolize() and use it in debug_util_posix.cc.
Unlike glibc's backtrace_symbols(), googleglog's Symbolize() can resolve symbols in binaries built with fvisibility=hidden. This is because Symbolize() uses both dynamic and regular symbols, while backtrace_symbols() only uses dynamic symbols. As shown below, the new backtrace is slightly less informative as it does not have the binary name like out/Debug/base_unittests and the distance information like +0x20, but it should be ok. BUG=32762 TEST=out/Debug/base_unittests gtest_filter='StackTrace*' gtest_also_run_disabled_tests; and manually: BEFORE out/Debug/base_unittests(StackTrace::StackTrace()+0x20) [0x81d38f6] out/Debug/base_unittests(StackTrace_DISABLED_DebugOutputToStream_Test::TestBody()+0x17) [0x806633d] out/Debug/base_unittests(testing::Test::Run()+0x7a) [0x8242f96] out/Debug/base_unittests(testing::internal::TestInfoImpl::Run()+0xb9) [0x824347b] out/Debug/base_unittests(testing::TestCase::Run()+0xb7) [0x8243a7f] out/Debug/base_unittests(testing::internal::UnitTestImpl::RunAllTests()+0x256) [0x824777e] out/Debug/base_unittests(testing::UnitTest::Run()+0x14) [0x824680a] out/Debug/base_unittests [0x8048cc5] out/Debug/base_unittests(main+0x50) [0x80482a4] /lib/tls/i686/cmov/libc.so.6(__libc_start_main+0xe6) [0xb6b41b56] out/Debug/base_unittests [0x80481c1] AFTER % out/Debug/base_unittests gtest_filter='*DebugOutputToStream' gtest_also_run_disabled_tests StackTrace::StackTrace() [0x81d3910] StackTrace_DISABLED_DebugOutputToStream_Test::TestBody() [0x806633d] testing::Test::Run() [0x8242f66] testing::internal::TestInfoImpl::Run() [0x824344b] testing::TestCase::Run() [0x8243a4f] testing::internal::UnitTestImpl::RunAllTests() [0x824774e] testing::UnitTest::Run() [0x82467da] TestSuite::Run() [0x8048cc5] main [0x80482a4] 0xb6c0db56 0x80481c1 Review URL: http://codereview.chromium.org/545148 TBR=satorux@chromium.org Review URL: http://codereview.chromium.org/545185 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@36998 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'base/debug_util_unittest.cc')
-rw-r--r--base/debug_util_unittest.cc15
1 files changed, 0 insertions, 15 deletions
diff --git a/base/debug_util_unittest.cc b/base/debug_util_unittest.cc
index 6d3043f..7bee4cc 100644
--- a/base/debug_util_unittest.cc
+++ b/base/debug_util_unittest.cc
@@ -91,18 +91,3 @@ TEST(StackTrace, DISABLED_OutputToStream) {
#endif // define(OS_MACOSX)
}
-
-// The test is used for manual testing (i.e. see the raw output).
-// To run the test use the flags:
-// --gtest_filter='*DebugOutputToStream' --gtest_also_run_disabled_tests
-TEST(StackTrace, DISABLED_DebugOutputToStream) {
- StackTrace trace;
- std::ostringstream os;
- trace.OutputToStream(&os);
- LOG(INFO) << os.str();
-}
-
-// The test is used for manual testing. See the comment above.
-TEST(StackTrace, DISABLED_DebugPrintBacktrace) {
- StackTrace().PrintBacktrace();
-}