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

Unified Diff: cc/animation/animation_player_unittest.cc

Issue 2377223002: CC Animations: Rewrite unit tests to work with AnimationPlayer. (Closed)
Patch Set: Reparent. Created 4 years, 2 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 | « cc/animation/animation_player.cc ('k') | cc/animation/element_animations.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: cc/animation/animation_player_unittest.cc
diff --git a/cc/animation/animation_player_unittest.cc b/cc/animation/animation_player_unittest.cc
index 4bdce50c6a3c407b6123806e21f0884adbcefddf..c6d1a431aa024514752a13401ca13185fdeca713 100644
--- a/cc/animation/animation_player_unittest.cc
+++ b/cc/animation/animation_player_unittest.cc
@@ -295,8 +295,8 @@ TEST_F(AnimationPlayerTest, AddRemoveAnimationToNonAttachedPlayer) {
const int filter_id =
AddAnimatedFilterToPlayer(player_.get(), duration, 0.1f, 0.9f);
- const int opacity_id = AddOpacityTransitionToPlayer(
- player_.get(), duration, start_opacity, end_opacity, false);
+ AddOpacityTransitionToPlayer(player_.get(), duration, start_opacity,
+ end_opacity, false);
EXPECT_FALSE(player_->needs_push_properties());
@@ -311,10 +311,10 @@ TEST_F(AnimationPlayerTest, AddRemoveAnimationToNonAttachedPlayer) {
player_->AttachElement(element_id_);
EXPECT_TRUE(player_->element_animations());
- EXPECT_FALSE(player_->element_animations()
- ->GetAnimationById(filter_id));
- EXPECT_TRUE(player_->element_animations()
- ->GetAnimationById(opacity_id));
+ EXPECT_FALSE(player_->element_animations()->HasAnyAnimationTargetingProperty(
+ TargetProperty::FILTER));
+ EXPECT_TRUE(player_->element_animations()->HasAnyAnimationTargetingProperty(
+ TargetProperty::OPACITY));
EXPECT_TRUE(player_->needs_push_properties());
host_->PushPropertiesTo(host_impl_);
« no previous file with comments | « cc/animation/animation_player.cc ('k') | cc/animation/element_animations.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698