Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(8)

Unified Diff: base/debug_util_unittest.cc

Issue 399069: linux: StackTrace test isn't expected to work in Release builds anymore (Closed)
Patch Set: Created 11 years, 1 month ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « no previous file | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: base/debug_util_unittest.cc
diff --git a/base/debug_util_unittest.cc b/base/debug_util_unittest.cc
index b9300a43bb8dc486ee3d0da9133e87998224aba0..930e9e0865940d7bfd508f52cb69a55f8e62c16e 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) <<
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698