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

Unified Diff: cc/trees/layer_tree_host_unittest_damage.cc

Issue 85143002: Dirty rects always contain full tiles with delegated rendering. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Fixed broken test due to this patch Created 7 years 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
« cc/test/fake_content_layer.cc ('K') | « cc/test/fake_content_layer.cc ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: cc/trees/layer_tree_host_unittest_damage.cc
diff --git a/cc/trees/layer_tree_host_unittest_damage.cc b/cc/trees/layer_tree_host_unittest_damage.cc
index 58644e63b50e1c077d8f794ff39e2b54ac9645cd..dc6c22a39fdbee45e3dec78d3da3991a46007b7d 100644
--- a/cc/trees/layer_tree_host_unittest_damage.cc
+++ b/cc/trees/layer_tree_host_unittest_damage.cc
@@ -372,9 +372,21 @@ class LayerTreeHostDamageTestForcedFullDamage : public LayerTreeHostDamageTest {
} else {
// When using a delegating renderer, or using impl side painting, the
// entire child is considered damaged as we need to replace its
- // resources with newly created ones.
- EXPECT_EQ(gfx::RectF(child_->position(), child_->bounds()).ToString(),
+ // resources with newly created ones. The damaged area is kept as it
+ // is, but entire child is painted.
+
+ // Verify damage area.
danakj 2013/12/02 15:09:49 Instead of saying "Verify damage area" which is cl
+ EXPECT_EQ(gfx::RectF(100+10, 100+11, 12, 13).ToString(),
root_damage.ToString());
+ // Verify paint area.
danakj 2013/12/02 15:09:49 Same here, say what you're expecting or why rather
+ gfx::RectF paint_rect = static_cast<gfx::RectF>
danakj 2013/12/02 15:06:52 You don't need to cast from Rect to RectF
+ (child_->Updater()->content_rect());
+ EXPECT_EQ((gfx::RectF(child_->bounds()).ToString()),
danakj 2013/12/02 15:06:52 you don't need () around the RectF.ToString() call
+ paint_rect.ToString());
prashant.n 2013/12/02 14:30:48 Do we need this as we can verify with actual value
+ paint_rect.set_origin(child_->position());
+ EXPECT_EQ(gfx::RectF(100, 100, 30, 30).ToString(),
+ paint_rect.ToString());
+ EXPECT_FALSE(root_damage.Contains(paint_rect));
prashant.n 2013/12/02 14:30:48 Should we verify this, as we have verified with ac
danakj 2013/12/02 15:06:52 I think the above check against layer->bounds() is
}
EXPECT_FALSE(frame_data->has_no_damage);
« cc/test/fake_content_layer.cc ('K') | « cc/test/fake_content_layer.cc ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698