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

Unified Diff: content/browser/renderer_host/render_widget_host_unittest.cc

Issue 9980016: Delete background tab IOSurfaces on Mac. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: comments and piman feedback Created 8 years, 8 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
Index: content/browser/renderer_host/render_widget_host_unittest.cc
diff --git a/content/browser/renderer_host/render_widget_host_unittest.cc b/content/browser/renderer_host/render_widget_host_unittest.cc
index 8f5c465a87afac5d1ce457c4bf42671f85df3d1e..27ea7a0915bf03d2ff4694e884eea0a75c5be90b 100644
--- a/content/browser/renderer_host/render_widget_host_unittest.cc
+++ b/content/browser/renderer_host/render_widget_host_unittest.cc
@@ -508,6 +508,11 @@ TEST_F(RenderWidgetHostTest, Background) {
// Tests getting the backing store with the renderer not setting repaint ack
// flags.
TEST_F(RenderWidgetHostTest, GetBackingStore_NoRepaintAck) {
+ // First set the view size to match what the renderer is rendering.
+ ViewHostMsg_UpdateRect_Params params;
+ process_->InitUpdateRectParams(&params);
+ view_->set_bounds(gfx::Rect(params.view_size));
+
// We don't currently have a backing store, and if the renderer doesn't send
// one in time, we should get nothing.
process_->set_update_msg_should_reply(false);
@@ -534,6 +539,11 @@ TEST_F(RenderWidgetHostTest, GetBackingStore_NoRepaintAck) {
// Tests getting the backing store with the renderer sending a repaint ack.
TEST_F(RenderWidgetHostTest, GetBackingStore_RepaintAck) {
+ // First set the view size to match what the renderer is rendering.
+ ViewHostMsg_UpdateRect_Params params;
+ process_->InitUpdateRectParams(&params);
+ view_->set_bounds(gfx::Rect(params.view_size));
+
// Doing a request request with the update message allowed should work and
// the repaint ack should work.
process_->set_update_msg_should_reply(true);

Powered by Google App Engine
This is Rietveld 408576698