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

Unified Diff: base/message_pump_libevent_unittest.cc

Issue 9020008: Enable ThreadChecker in non-debug builds if DCHECK_ALWAYS_ON is (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Merge to LKGR (pure merge). Created 8 years, 12 months 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 | base/threading/thread_checker.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: base/message_pump_libevent_unittest.cc
diff --git a/base/message_pump_libevent_unittest.cc b/base/message_pump_libevent_unittest.cc
index 9ec78de587d31f73ca4873a02713e4380fd91826..92531fd67d0ec28dfa9a61f76d3ed77cb7d0662c 100644
--- a/base/message_pump_libevent_unittest.cc
+++ b/base/message_pump_libevent_unittest.cc
@@ -59,7 +59,7 @@ class StupidWatcher : public MessagePumpLibevent::Watcher {
virtual void OnFileCanWriteWithoutBlocking(int fd) {}
};
-#if GTEST_HAS_DEATH_TEST
+#if GTEST_HAS_DEATH_TEST && !defined(NDEBUG)
// Test to make sure that we catch calling WatchFileDescriptor off of the
// wrong thread.
@@ -67,13 +67,13 @@ TEST_F(MessagePumpLibeventTest, TestWatchingFromBadThread) {
MessagePumpLibevent::FileDescriptorWatcher watcher;
StupidWatcher delegate;
- ASSERT_DEBUG_DEATH(io_loop()->WatchFileDescriptor(
+ ASSERT_DEATH(io_loop()->WatchFileDescriptor(
STDOUT_FILENO, false, MessageLoopForIO::WATCH_READ, &watcher, &delegate),
"Check failed: "
"watch_file_descriptor_caller_checker_.CalledOnValidThread()");
}
-#endif // GTEST_HAS_DEATH_TEST
+#endif // GTEST_HAS_DEATH_TEST && !defined(NDEBUG)
class DeleteWatcher : public MessagePumpLibevent::Watcher {
public:
« no previous file with comments | « no previous file | base/threading/thread_checker.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698