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

Unified Diff: cc/test/animation_timelines_test_common.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/test/animation_timelines_test_common.h ('k') | cc/trees/layer_tree_host_common_unittest.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: cc/test/animation_timelines_test_common.cc
diff --git a/cc/test/animation_timelines_test_common.cc b/cc/test/animation_timelines_test_common.cc
index 82559f90ce299f2ed325a64bed9fcc1a7b5dd0eb..54c59a613f7458e461a6bdb2c1e4fa49d8b4338a 100644
--- a/cc/test/animation_timelines_test_common.cc
+++ b/cc/test/animation_timelines_test_common.cc
@@ -395,6 +395,8 @@ void AnimationTimelinesTest::AttachTimelinePlayerLayer() {
host_->AddAnimationTimeline(timeline_);
timeline_->AttachPlayer(player_);
player_->AttachElement(element_id_);
+
+ element_animations_ = player_->element_animations();
}
void AnimationTimelinesTest::CreateImplTimelineAndPlayer() {
@@ -402,25 +404,13 @@ void AnimationTimelinesTest::CreateImplTimelineAndPlayer() {
GetImplTimelineAndPlayerByID();
}
-scoped_refptr<ElementAnimations> AnimationTimelinesTest::element_animations()
- const {
- DCHECK(player_);
- DCHECK(player_->element_animations());
- return player_->element_animations();
-}
-
-scoped_refptr<ElementAnimations>
-AnimationTimelinesTest::element_animations_impl() const {
- DCHECK(player_impl_);
- DCHECK(player_impl_->element_animations());
- return player_impl_->element_animations();
-}
-
void AnimationTimelinesTest::GetImplTimelineAndPlayerByID() {
timeline_impl_ = host_impl_->GetTimelineById(timeline_id_);
EXPECT_TRUE(timeline_impl_);
player_impl_ = timeline_impl_->GetPlayerById(player_id_);
EXPECT_TRUE(player_impl_);
+
+ element_animations_impl_ = player_impl_->element_animations();
}
void AnimationTimelinesTest::ReleaseRefPtrs() {
« no previous file with comments | « cc/test/animation_timelines_test_common.h ('k') | cc/trees/layer_tree_host_common_unittest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698