summaryrefslogtreecommitdiffstats
path: root/base/debug_util_unittest.cc
diff options
context:
space:
mode:
authorevan@chromium.org <evan@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2009-11-18 18:03:23 +0000
committerevan@chromium.org <evan@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2009-11-18 18:03:23 +0000
commit0d1c22616423011f8fb4979a04bfbbef3efa1cb2 (patch)
tree25d78de3d7ae6769eaa2df47f33ba0e21134a723 /base/debug_util_unittest.cc
parent9428edc493bf5097cc74fca5fcaf4506c4068668 (diff)
downloadchromium_src-0d1c22616423011f8fb4979a04bfbbef3efa1cb2.zip
chromium_src-0d1c22616423011f8fb4979a04bfbbef3efa1cb2.tar.gz
chromium_src-0d1c22616423011f8fb4979a04bfbbef3efa1cb2.tar.bz2
linux: StackTrace test isn't expected to work in Release builds anymore
Dropping the exception unwind data cut our executable size considerably, but it means we can't get stack traces anymore in Release builds, so stop this test early in that case. Review URL: http://codereview.chromium.org/399069 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@32346 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'base/debug_util_unittest.cc')
-rw-r--r--base/debug_util_unittest.cc7
1 files changed, 7 insertions, 0 deletions
diff --git a/base/debug_util_unittest.cc b/base/debug_util_unittest.cc
index b9300a4..930e9e0 100644
--- a/base/debug_util_unittest.cc
+++ b/base/debug_util_unittest.cc
@@ -17,6 +17,13 @@ TEST(StackTrace, OutputToStream) {
trace.OutputToStream(&os);
std::string backtrace_message = os.str();
+#if defined(OS_LINUX) && NDEBUG
+ // Stack traces require an extra data table that bloats our binaries,
+ // so they're turned off for release builds. We stop the test here,
+ // at least letting us verify that the calls don't crash.
+ return;
+#endif // defined(OS_LINUX) && NDEBUG
+
size_t frames_found = 0;
trace.Addresses(&frames_found);
ASSERT_GE(frames_found, 5u) <<