| OLD | NEW |
| 1 /* | 1 /* |
| 2 * Copyright (c) 2013, Google Inc. All rights reserved. | 2 * Copyright (c) 2013, Google Inc. All rights reserved. |
| 3 * | 3 * |
| 4 * Redistribution and use in source and binary forms, with or without | 4 * Redistribution and use in source and binary forms, with or without |
| 5 * modification, are permitted provided that the following conditions are | 5 * modification, are permitted provided that the following conditions are |
| 6 * met: | 6 * met: |
| 7 * | 7 * |
| 8 * * Redistributions of source code must retain the above copyright | 8 * * Redistributions of source code must retain the above copyright |
| 9 * notice, this list of conditions and the following disclaimer. | 9 * notice, this list of conditions and the following disclaimer. |
| 10 * * Redistributions in binary form must reproduce the above | 10 * * Redistributions in binary form must reproduce the above |
| (...skipping 34 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 45 virtual void SetUp() | 45 virtual void SetUp() |
| 46 { | 46 { |
| 47 cssValue = CSSArrayFunctionValue::create(); | 47 cssValue = CSSArrayFunctionValue::create(); |
| 48 animatableUnknown = AnimatableUnknown::create(cssValue); | 48 animatableUnknown = AnimatableUnknown::create(cssValue); |
| 49 | 49 |
| 50 otherCSSValue = CSSArrayFunctionValue::create(); | 50 otherCSSValue = CSSArrayFunctionValue::create(); |
| 51 otherAnimatableUnknown = AnimatableUnknown::create(otherCSSValue); | 51 otherAnimatableUnknown = AnimatableUnknown::create(otherCSSValue); |
| 52 } | 52 } |
| 53 | 53 |
| 54 RefPtrWillBePersistent<CSSValue> cssValue; | 54 RefPtrWillBePersistent<CSSValue> cssValue; |
| 55 RefPtr<AnimatableValue> animatableUnknown; | 55 RefPtrWillBePersistent<AnimatableValue> animatableUnknown; |
| 56 | |
| 57 RefPtrWillBePersistent<CSSValue> otherCSSValue; | 56 RefPtrWillBePersistent<CSSValue> otherCSSValue; |
| 58 RefPtr<AnimatableValue> otherAnimatableUnknown; | 57 RefPtrWillBePersistent<AnimatableValue> otherAnimatableUnknown; |
| 59 }; | 58 }; |
| 60 | 59 |
| 61 TEST_F(AnimationAnimatableUnknownTest, Create) | 60 TEST_F(AnimationAnimatableUnknownTest, Create) |
| 62 { | 61 { |
| 63 EXPECT_TRUE(animatableUnknown); | 62 EXPECT_TRUE(animatableUnknown); |
| 64 } | 63 } |
| 65 | 64 |
| 66 TEST_F(AnimationAnimatableUnknownTest, ToCSSValue) | 65 TEST_F(AnimationAnimatableUnknownTest, ToCSSValue) |
| 67 { | 66 { |
| 68 EXPECT_EQ(cssValue, toAnimatableUnknown(animatableUnknown.get())->toCSSValue
()); | 67 EXPECT_EQ(cssValue, toAnimatableUnknown(animatableUnknown.get())->toCSSValue
()); |
| (...skipping 14 matching lines...) Expand all Loading... |
| 83 EXPECT_EQ(cssValue, toAnimatableUnknown(AnimatableValue::interpolate(otherAn
imatableUnknown.get(), animatableUnknown.get(), 1).get())->toCSSValue()); | 82 EXPECT_EQ(cssValue, toAnimatableUnknown(AnimatableValue::interpolate(otherAn
imatableUnknown.get(), animatableUnknown.get(), 1).get())->toCSSValue()); |
| 84 } | 83 } |
| 85 | 84 |
| 86 TEST_F(AnimationAnimatableUnknownTest, Add) | 85 TEST_F(AnimationAnimatableUnknownTest, Add) |
| 87 { | 86 { |
| 88 EXPECT_EQ(otherCSSValue, toAnimatableUnknown(AnimatableValue::add(animatable
Unknown.get(), otherAnimatableUnknown.get()).get())->toCSSValue()); | 87 EXPECT_EQ(otherCSSValue, toAnimatableUnknown(AnimatableValue::add(animatable
Unknown.get(), otherAnimatableUnknown.get()).get())->toCSSValue()); |
| 89 EXPECT_EQ(cssValue, toAnimatableUnknown(AnimatableValue::add(otherAnimatable
Unknown.get(), animatableUnknown.get()).get())->toCSSValue()); | 88 EXPECT_EQ(cssValue, toAnimatableUnknown(AnimatableValue::add(otherAnimatable
Unknown.get(), animatableUnknown.get()).get())->toCSSValue()); |
| 90 } | 89 } |
| 91 | 90 |
| 92 } | 91 } |
| OLD | NEW |