OLD | NEW |
1 // Copyright (c) 2006-2008 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2006-2008 The Chromium Authors. All rights reserved. |
2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
4 | 4 |
5 #include "base/logging.h" | |
6 #include "base/message_loop.h" | 5 #include "base/message_loop.h" |
7 #include "chrome/common/animation.h" | 6 #include "chrome/common/animation.h" |
8 #include "testing/gtest/include/gtest/gtest.h" | 7 #include "testing/gtest/include/gtest/gtest.h" |
9 | 8 |
10 using namespace std; | 9 using namespace std; |
11 | 10 |
12 class AnimationTest: public testing::Test { | 11 class AnimationTest: public testing::Test { |
13 private: | 12 private: |
14 MessageLoopForUI message_loop_; | 13 MessageLoopForUI message_loop_; |
15 }; | 14 }; |
(...skipping 78 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
94 | 93 |
95 TEST_F(AnimationTest, CancelCase) { | 94 TEST_F(AnimationTest, CancelCase) { |
96 TestAnimationDelegate ad; | 95 TestAnimationDelegate ad; |
97 CancelAnimation a2(2000, 150, &ad); | 96 CancelAnimation a2(2000, 150, &ad); |
98 a2.Start(); | 97 a2.Start(); |
99 MessageLoop::current()->Run(); | 98 MessageLoop::current()->Run(); |
100 | 99 |
101 EXPECT_TRUE(ad.finished()); | 100 EXPECT_TRUE(ad.finished()); |
102 EXPECT_TRUE(ad.canceled()); | 101 EXPECT_TRUE(ad.canceled()); |
103 } | 102 } |
OLD | NEW |