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

Unified Diff: Source/core/animation/animatable/AnimatableLengthTest.cpp

Issue 1120003002: [Oilpan] Migrate most classes under core/animations to Oilpan heap. (Closed) Base URL: https://chromium.googlesource.com/chromium/blink.git@master
Patch Set: Rebase Created 5 years, 4 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: Source/core/animation/animatable/AnimatableLengthTest.cpp
diff --git a/Source/core/animation/animatable/AnimatableLengthTest.cpp b/Source/core/animation/animatable/AnimatableLengthTest.cpp
index 459b3568328a8643290c2210ae6f77f68f4f2d7d..15e938db614ab63e8ddb16d3e664dd067301d062 100644
--- a/Source/core/animation/animatable/AnimatableLengthTest.cpp
+++ b/Source/core/animation/animatable/AnimatableLengthTest.cpp
@@ -12,7 +12,7 @@ namespace blink {
namespace {
-PassRefPtrWillBeRawPtr<AnimatableLength> create(const Length& length, double zoom = 1)
+AnimatableLength* create(const Length& length, double zoom = 1)
{
return AnimatableLength::create(length, zoom);
}
@@ -52,21 +52,21 @@ TEST(AnimationAnimatableLengthTest, Zoom)
TEST(AnimationAnimatableLengthTest, Equals)
{
- EXPECT_TRUE(create(Length(10, Fixed))->equals(create(Length(10, Fixed)).get()));
- EXPECT_TRUE(create(Length(20, Percent))->equals(create(Length(20, Percent)).get()));
- EXPECT_FALSE(create(Length(10, Fixed))->equals(create(Length(10, Percent)).get()));
- EXPECT_FALSE(create(Length(0, Percent))->equals(create(Length(0, Fixed)).get()));
+ EXPECT_TRUE(create(Length(10, Fixed))->equals(create(Length(10, Fixed))));
+ EXPECT_TRUE(create(Length(20, Percent))->equals(create(Length(20, Percent))));
+ EXPECT_FALSE(create(Length(10, Fixed))->equals(create(Length(10, Percent))));
+ EXPECT_FALSE(create(Length(0, Percent))->equals(create(Length(0, Fixed))));
Length calc = Length(CalculationValue::create(PixelsAndPercent(5, 10), ValueRangeAll));
- EXPECT_TRUE(create(calc)->equals(create(calc).get()));
- EXPECT_FALSE(create(calc)->equals(create(Length(10, Percent)).get()));
+ EXPECT_TRUE(create(calc)->equals(create(calc)));
+ EXPECT_FALSE(create(calc)->equals(create(Length(10, Percent))));
}
TEST(AnimationAnimatableLengthTest, Interpolate)
{
- EXPECT_TRUE(AnimatableValue::interpolate(create(Length(10, Fixed)).get(), create(Length(0, Fixed)).get(), 0.2)->equals(create(Length(8, Fixed)).get()));
- EXPECT_TRUE(AnimatableValue::interpolate(create(Length(4, Percent)).get(), create(Length(12, Percent)).get(), 0.25)->equals(create(Length(6, Percent)).get()));
+ EXPECT_TRUE(AnimatableValue::interpolate(create(Length(10, Fixed)), create(Length(0, Fixed)), 0.2)->equals(create(Length(8, Fixed))));
+ EXPECT_TRUE(AnimatableValue::interpolate(create(Length(4, Percent)), create(Length(12, Percent)), 0.25)->equals(create(Length(6, Percent))));
Length calc = Length(CalculationValue::create(PixelsAndPercent(12, 4), ValueRangeAll));
- EXPECT_TRUE(AnimatableValue::interpolate(create(Length(20, Fixed)).get(), create(Length(10, Percent)).get(), 0.4)->equals(create(calc).get()));
+ EXPECT_TRUE(AnimatableValue::interpolate(create(Length(20, Fixed)), create(Length(10, Percent)), 0.4)->equals(create(calc)));
}
} // namespace blink
« no previous file with comments | « Source/core/animation/animatable/AnimatableLengthSize.cpp ('k') | Source/core/animation/animatable/AnimatableNeutral.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698