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

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

Issue 2615613003: Fix double ripple on activated flood fill ripple (Closed)
Patch Set: Addressed nits 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
Index: ui/views/animation/ink_drop_ripple_unittest.cc
diff --git a/ui/views/animation/ink_drop_ripple_unittest.cc b/ui/views/animation/ink_drop_ripple_unittest.cc
index add5baf5dae7062f88589f384cdc5f34e0d14f49..1beb05bb53957b57c64969ebd3a170a590758f6a 100644
--- a/ui/views/animation/ink_drop_ripple_unittest.cc
+++ b/ui/views/animation/ink_drop_ripple_unittest.cc
@@ -358,5 +358,18 @@ TEST_P(InkDropRippleTest, TargetInkDropStateOnAnimationEnded) {
observer_.target_state_at_last_animation_ended());
}
+// Verifies that when an we ink drop transitions from ACTION_PENDING to
+// ACTIVATED state, animation observers are called in order.
+TEST_P(InkDropRippleTest, RipplePendingToActivatedObserverOrder) {
+ ink_drop_ripple_->AnimateToState(InkDropState::ACTION_PENDING);
+ ink_drop_ripple_->AnimateToState(InkDropState::ACTIVATED);
+ test_api_->CompleteAnimations();
+
+ EXPECT_TRUE(observer_.AnimationStartedContextsMatch(
+ {InkDropState::ACTION_PENDING, InkDropState::ACTIVATED}));
+ EXPECT_TRUE(observer_.AnimationEndedContextsMatch(
+ {InkDropState::ACTION_PENDING, InkDropState::ACTIVATED}));
+}
+
} // namespace test
} // namespace views
« no previous file with comments | « ui/views/animation/ink_drop_ripple.cc ('k') | ui/views/animation/test/flood_fill_ink_drop_ripple_test_api.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698