| Index: Source/core/animation/AnimationStackTest.cpp
|
| diff --git a/Source/core/animation/AnimationStackTest.cpp b/Source/core/animation/AnimationStackTest.cpp
|
| index 02c60590eb2f5eae36735397f4ab43212b37be93..b107076f2dd68188a48e0b604d638a6c9038362c 100644
|
| --- a/Source/core/animation/AnimationStackTest.cpp
|
| +++ b/Source/core/animation/AnimationStackTest.cpp
|
| @@ -117,4 +117,38 @@
|
| EXPECT_TRUE(interpolationValue(result.get(CSSPropertyZIndex))->equals(AnimatableDouble::create(2).get()));
|
| }
|
|
|
| +TEST_F(AnimationAnimationStackTest, ForwardsFillDiscarding)
|
| +{
|
| + play(makeAnimation(makeAnimationEffect(CSSPropertyFontSize, AnimatableDouble::create(1))).get(), 2);
|
| + play(makeAnimation(makeAnimationEffect(CSSPropertyFontSize, AnimatableDouble::create(2))).get(), 6);
|
| + play(makeAnimation(makeAnimationEffect(CSSPropertyFontSize, AnimatableDouble::create(3))).get(), 4);
|
| + document->compositorPendingAnimations().update();
|
| + WillBeHeapHashMap<CSSPropertyID, RefPtrWillBeMember<Interpolation> > interpolations;
|
| +
|
| + updateTimeline(11);
|
| + Heap::collectAllGarbage();
|
| + interpolations = AnimationStack::activeInterpolations(&element->activeAnimations()->defaultStack(), 0, 0, Animation::DefaultPriority, 0);
|
| + EXPECT_TRUE(interpolationValue(interpolations.get(CSSPropertyFontSize))->equals(AnimatableDouble::create(3).get()));
|
| + EXPECT_EQ(3u, effects().size());
|
| + EXPECT_EQ(1u, interpolations.size());
|
| +
|
| + updateTimeline(13);
|
| + Heap::collectAllGarbage();
|
| + interpolations = AnimationStack::activeInterpolations(&element->activeAnimations()->defaultStack(), 0, 0, Animation::DefaultPriority, 0);
|
| + EXPECT_TRUE(interpolationValue(interpolations.get(CSSPropertyFontSize))->equals(AnimatableDouble::create(3).get()));
|
| + EXPECT_EQ(3u, effects().size());
|
| +
|
| + updateTimeline(15);
|
| + Heap::collectAllGarbage();
|
| + interpolations = AnimationStack::activeInterpolations(&element->activeAnimations()->defaultStack(), 0, 0, Animation::DefaultPriority, 0);
|
| + EXPECT_TRUE(interpolationValue(interpolations.get(CSSPropertyFontSize))->equals(AnimatableDouble::create(3).get()));
|
| + EXPECT_EQ(2u, effects().size());
|
| +
|
| + updateTimeline(17);
|
| + Heap::collectAllGarbage();
|
| + interpolations = AnimationStack::activeInterpolations(&element->activeAnimations()->defaultStack(), 0, 0, Animation::DefaultPriority, 0);
|
| + EXPECT_TRUE(interpolationValue(interpolations.get(CSSPropertyFontSize))->equals(AnimatableDouble::create(3).get()));
|
| + EXPECT_EQ(1u, effects().size());
|
| }
|
| +
|
| +}
|
|
|