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

Unified Diff: third_party/WebKit/Source/core/animation/AnimationTimelineTest.cpp

Issue 2952783002: Make AnimationTimeline.currentTime readonly (Closed)
Patch Set: Delete obsolete setCurrentTime* methods Created 3 years, 6 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 | « third_party/WebKit/Source/core/animation/AnimationTimeline.idl ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: third_party/WebKit/Source/core/animation/AnimationTimelineTest.cpp
diff --git a/third_party/WebKit/Source/core/animation/AnimationTimelineTest.cpp b/third_party/WebKit/Source/core/animation/AnimationTimelineTest.cpp
index 9e05e04559bee8a026e0f209bff6e09cb711e75e..46be9c5b17303faaac014fe8af60b9ff2c36f988 100644
--- a/third_party/WebKit/Source/core/animation/AnimationTimelineTest.cpp
+++ b/third_party/WebKit/Source/core/animation/AnimationTimelineTest.cpp
@@ -240,54 +240,6 @@ TEST_F(AnimationAnimationTimelineTest, PlaybackRateFast) {
EXPECT_FALSE(is_null);
}
-TEST_F(AnimationAnimationTimelineTest, SetCurrentTime) {
- double zero_time = timeline->ZeroTime();
-
- document->GetAnimationClock().UpdateTime(100);
- EXPECT_EQ(zero_time, timeline->ZeroTime());
- EXPECT_EQ(100, timeline->CurrentTimeInternal());
-
- timeline->SetCurrentTimeInternal(0);
- EXPECT_EQ(0, timeline->CurrentTimeInternal());
- EXPECT_EQ(zero_time + 100, timeline->ZeroTime());
-
- timeline->SetCurrentTimeInternal(100);
- EXPECT_EQ(100, timeline->CurrentTimeInternal());
- EXPECT_EQ(zero_time, timeline->ZeroTime());
-
- timeline->SetCurrentTimeInternal(200);
- EXPECT_EQ(200, timeline->CurrentTimeInternal());
- EXPECT_EQ(zero_time - 100, timeline->ZeroTime());
-
- document->GetAnimationClock().UpdateTime(200);
- EXPECT_EQ(300, timeline->CurrentTimeInternal());
- EXPECT_EQ(zero_time - 100, timeline->ZeroTime());
-
- timeline->SetCurrentTimeInternal(0);
- EXPECT_EQ(0, timeline->CurrentTimeInternal());
- EXPECT_EQ(zero_time + 200, timeline->ZeroTime());
-
- timeline->SetCurrentTimeInternal(100);
- EXPECT_EQ(100, timeline->CurrentTimeInternal());
- EXPECT_EQ(zero_time + 100, timeline->ZeroTime());
-
- timeline->SetCurrentTimeInternal(200);
- EXPECT_EQ(200, timeline->CurrentTimeInternal());
- EXPECT_EQ(zero_time, timeline->ZeroTime());
-
- timeline->setCurrentTime(0, false);
- EXPECT_EQ(0, timeline->currentTime());
- EXPECT_EQ(zero_time + 200, timeline->ZeroTime());
-
- timeline->setCurrentTime(1000, false);
- EXPECT_EQ(1000, timeline->currentTime());
- EXPECT_EQ(zero_time + 199, timeline->ZeroTime());
-
- timeline->setCurrentTime(2000, false);
- EXPECT_EQ(2000, timeline->currentTime());
- EXPECT_EQ(zero_time + 198, timeline->ZeroTime());
-}
-
TEST_F(AnimationAnimationTimelineTest, PauseForTesting) {
float seek_time = 1;
timing.fill_mode = Timing::FillMode::FORWARDS;
« no previous file with comments | « third_party/WebKit/Source/core/animation/AnimationTimeline.idl ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698