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

Unified Diff: content/child/resource_dispatcher_unittest.cc

Issue 23583039: Convert a bunch of resource IPCs to be control messages. They didn't need to be routed. (Closed) Base URL: svn://chrome-svn/chrome/trunk/src/
Patch Set: remove dcheck from RenderProcessHost instead Created 7 years, 3 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
« no previous file with comments | « content/child/resource_dispatcher.cc ('k') | content/common/resource_messages.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: content/child/resource_dispatcher_unittest.cc
===================================================================
--- content/child/resource_dispatcher_unittest.cc (revision 221543)
+++ content/child/resource_dispatcher_unittest.cc (working copy)
@@ -134,10 +134,9 @@
base::SharedMemoryHandle dup_handle;
EXPECT_TRUE(shared_mem.GiveToProcess(
base::Process::Current().handle(), &dup_handle));
- dispatcher_->OnSetDataBuffer(message_queue_[0], request_id, dup_handle,
+ dispatcher_->OnSetDataBuffer(request_id, dup_handle,
test_page_contents_len, 0);
- dispatcher_->OnReceivedData(message_queue_[0], request_id, 0,
- test_page_contents_len,
+ dispatcher_->OnReceivedData(request_id, 0, test_page_contents_len,
test_page_contents_len);
message_queue_.erase(message_queue_.begin());
@@ -251,7 +250,7 @@
response_head.error_code = net::OK;
dispatcher_->OnMessageReceived(
- ResourceMsg_ReceivedResponse(0, 0, response_head));
+ ResourceMsg_ReceivedResponse(0, response_head));
// Duplicate the shared memory handle so both the test and the callee can
// close their copy.
@@ -260,9 +259,8 @@
&duplicated_handle));
dispatcher_->OnMessageReceived(
- ResourceMsg_SetDataBuffer(0, 0, duplicated_handle, 100, 0));
- dispatcher_->OnMessageReceived(
- ResourceMsg_DataReceived(0, 0, 0, 100, 100));
+ ResourceMsg_SetDataBuffer(0, duplicated_handle, 100, 0));
+ dispatcher_->OnMessageReceived(ResourceMsg_DataReceived(0, 0, 100, 100));
set_defer_loading(false);
}
@@ -355,7 +353,7 @@
bridge->Start(this);
dispatcher_->OnMessageReceived(
- ResourceMsg_ReceivedResponse(0, 0, response_head));
+ ResourceMsg_ReceivedResponse(0, response_head));
}
// ResourceLoaderBridge::Peer methods.
« no previous file with comments | « content/child/resource_dispatcher.cc ('k') | content/common/resource_messages.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698