Index: cc/resources/picture_layer_tiling_unittest.cc |
diff --git a/cc/resources/picture_layer_tiling_unittest.cc b/cc/resources/picture_layer_tiling_unittest.cc |
index 91043e67b48006e13d72f42781c97fd55828fcdb..544cac8ad2a6eb9120757af19185c19ba361cd45 100644 |
--- a/cc/resources/picture_layer_tiling_unittest.cc |
+++ b/cc/resources/picture_layer_tiling_unittest.cc |
@@ -358,5 +358,16 @@ TEST(PictureLayerTilingTest, ExpandRectOutOfBounds) { |
EXPECT_TRUE(out.IsEmpty()); |
} |
+TEST(PictureLayerTilingTest, EmptyStartingRect) { |
enne (OOO)
2013/04/09 02:08:38
WTB unit test that makes sure this layer also has
danakj
2013/04/09 02:42:17
OK will do!
|
+ // If a layer has a non-invertible transform, then the starting rect |
+ // for the layer would be empty. |
+ gfx::Rect in(40, 40, 0, 0); |
+ gfx::Rect bounds(0, 0, 10, 10); |
+ int64 target_area = 400 * 400; |
+ gfx::Rect out = PictureLayerTiling::ExpandRectEquallyToAreaBoundedBy( |
+ in, target_area, bounds); |
+ EXPECT_TRUE(out.IsEmpty()); |
+} |
+ |
} // namespace |
} // namespace cc |