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

Side by Side Diff: cc/resources/tile_priority_unittest.cc

Issue 12471007: Part 8 of cc/ directory shuffles: resources (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 7 years, 9 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 unified diff | Download patch | Annotate | Revision Log
« no previous file with comments | « cc/resources/tile_priority.cc ('k') | cc/resources/transferable_resource.h » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright 2012 The Chromium Authors. All rights reserved. 1 // Copyright 2012 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 "cc/tile_priority.h" 5 #include "cc/resources/tile_priority.h"
6 6
7 #include "testing/gtest/include/gtest/gtest.h" 7 #include "testing/gtest/include/gtest/gtest.h"
8 8
9 namespace cc { 9 namespace cc {
10 namespace { 10 namespace {
11 11
12 TEST(TilePriorityTest, TimeForBoundsToIntersectWithScroll) { 12 TEST(TilePriorityTest, TimeForBoundsToIntersectWithScroll) {
13 const float inf = std::numeric_limits<float>::infinity(); 13 const float inf = std::numeric_limits<float>::infinity();
14 gfx::Rect target(0, 0, 800, 600); 14 gfx::Rect target(0, 0, 800, 600);
15 gfx::Rect current(100, 100, 100, 100); 15 gfx::Rect current(100, 100, 100, 100);
(...skipping 42 matching lines...) Expand 10 before | Expand all | Expand 10 after
58 58
59 EXPECT_EQ(1, TilePriority::manhattanDistance( 59 EXPECT_EQ(1, TilePriority::manhattanDistance(
60 gfx::Rect(0, 0, 400, 400), gfx::Rect(0, -100, 100, 100))); 60 gfx::Rect(0, 0, 400, 400), gfx::Rect(0, -100, 100, 100)));
61 61
62 EXPECT_EQ(202, TilePriority::manhattanDistance( 62 EXPECT_EQ(202, TilePriority::manhattanDistance(
63 gfx::Rect(0, 0, 100, 100), gfx::Rect(200, 200, 100, 100))); 63 gfx::Rect(0, 0, 100, 100), gfx::Rect(200, 200, 100, 100)));
64 } 64 }
65 65
66 } // namespace 66 } // namespace
67 } // namespace cc 67 } // namespace cc
OLDNEW
« no previous file with comments | « cc/resources/tile_priority.cc ('k') | cc/resources/transferable_resource.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698