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

Unified Diff: ui/views/animation/ink_drop_impl_unittest.cc

Issue 2642173002: Migrate GCMKeyStore and InkDropImpl tests to use EXPECT_DCHECK_DEATH. (Closed)
Patch Set: Remove static_assert()s Created 3 years, 11 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 | « components/gcm_driver/crypto/gcm_key_store_unittest.cc ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: ui/views/animation/ink_drop_impl_unittest.cc
diff --git a/ui/views/animation/ink_drop_impl_unittest.cc b/ui/views/animation/ink_drop_impl_unittest.cc
index 8b9336c9a85d8626e303a711ac44bda766e46e6e..d63ce2112f09ee338efbee970d53343c07baa23f 100644
--- a/ui/views/animation/ink_drop_impl_unittest.cc
+++ b/ui/views/animation/ink_drop_impl_unittest.cc
@@ -8,6 +8,7 @@
#include "base/macros.h"
#include "base/memory/ptr_util.h"
+#include "base/test/gtest_util.h"
#include "base/test/test_simple_task_runner.h"
#include "base/threading/thread_task_runner_handle.h"
#include "testing/gtest/include/gtest/gtest.h"
@@ -232,24 +233,20 @@ TEST_F(InkDropImplTest, LayersArentRemovedWhenPreemptingFadeOut) {
EXPECT_TRUE(AreLayersAddedToHost());
}
-#if DCHECK_IS_ON()
TEST_F(InkDropImplTest,
SettingHighlightStateDuringStateExitIsntAllowedDeathTest) {
::testing::FLAGS_gtest_death_test_style = "threadsafe";
test::InkDropImplTestApi::SetStateOnExitHighlightState::Install(
test_api()->state_factory());
- ASSERT_DEATH_IF_SUPPORTED(
+ EXPECT_DCHECK_DEATH(
test::InkDropImplTestApi::AccessFactoryOnExitHighlightState::Install(
- test_api()->state_factory()),
- ".*HighlightStates should not be changed within a call to "
- "HighlightState::Exit\\(\\)\\..*");
+ test_api()->state_factory()));
// Need to set the |highlight_state_| directly because the
// SetStateOnExitHighlightState will recursively try to set it during tear
// down and cause a stack overflow.
test_api()->SetHighlightState(nullptr);
}
-#endif
// Verifies there is no use after free errors.
TEST_F(InkDropImplTest,
« no previous file with comments | « components/gcm_driver/crypto/gcm_key_store_unittest.cc ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698