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

Unified Diff: trunk/src/ui/compositor/layer_animation_element_unittest.cc

Issue 23809002: Revert 220479 "Add support for inverse transform animations." (Closed) Base URL: svn://svn.chromium.org/chrome/
Patch Set: Created 7 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
« no previous file with comments | « trunk/src/ui/compositor/layer_animation_element.cc ('k') | trunk/src/ui/compositor/test/test_utils.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: trunk/src/ui/compositor/layer_animation_element_unittest.cc
===================================================================
--- trunk/src/ui/compositor/layer_animation_element_unittest.cc (revision 220491)
+++ trunk/src/ui/compositor/layer_animation_element_unittest.cc (working copy)
@@ -10,7 +10,6 @@
#include "base/time/time.h"
#include "testing/gtest/include/gtest/gtest.h"
#include "ui/compositor/layer_animation_delegate.h"
-#include "ui/compositor/scoped_animation_duration_scale_mode.h"
#include "ui/compositor/test/test_layer_animation_delegate.h"
#include "ui/compositor/test/test_utils.h"
#include "ui/gfx/rect.h"
@@ -24,7 +23,7 @@
// that the element can be reused after it completes.
TEST(LayerAnimationElementTest, TransformElement) {
TestLayerAnimationDelegate delegate;
- gfx::Transform start_transform, target_transform;
+ gfx::Transform start_transform, target_transform, middle_transform;
start_transform.Rotate(-30.0);
target_transform.Rotate(30.0);
base::TimeTicks start_time;
@@ -66,36 +65,6 @@
CheckApproximatelyEqual(target_transform, target_value.transform);
}
-// Ensures that duration is copied correctly.
-TEST(LayerAnimationElementTest, InverseElementDurationNoScale) {
- gfx::Transform transform;
- base::TimeDelta delta;
-
- scoped_ptr<LayerAnimationElement> base_element(
- LayerAnimationElement::CreateTransformElement(transform, delta));
-
- scoped_ptr<LayerAnimationElement> inverse_element(
- LayerAnimationElement::CreateInverseTransformElement(transform,
- base_element.get()));
- EXPECT_EQ(base_element->duration(), inverse_element->duration());
-}
-
-// Ensures that duration is copied correctly and not double scaled.
-TEST(LayerAnimationElementTest, InverseElementDurationScaled) {
- gfx::Transform transform;
- base::TimeDelta delta;
-
- ScopedAnimationDurationScaleMode faster_duration(
- ScopedAnimationDurationScaleMode::FAST_DURATION);
- scoped_ptr<LayerAnimationElement> base_element(
- LayerAnimationElement::CreateTransformElement(transform, delta));
-
- scoped_ptr<LayerAnimationElement> inverse_element(
- LayerAnimationElement::CreateInverseTransformElement(transform,
- base_element.get()));
- EXPECT_EQ(base_element->duration(), inverse_element->duration());
-}
-
// Check that the bounds element progresses the delegate as expected and
// that the element can be reused after it completes.
TEST(LayerAnimationElementTest, BoundsElement) {
« no previous file with comments | « trunk/src/ui/compositor/layer_animation_element.cc ('k') | trunk/src/ui/compositor/test/test_utils.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698