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

Side by Side Diff: content/child/resource_dispatcher_unittest.cc

Issue 203853003: Merge weburlrequest_extradata_impl.cc/h into content/child/request_extra_data.cc/h (attempt #2) (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: style feedback Created 6 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
OLDNEW
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. 1 // Copyright (c) 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 <string> 5 #include <string>
6 #include <vector> 6 #include <vector>
7 7
8 #include "base/memory/scoped_ptr.h" 8 #include "base/memory/scoped_ptr.h"
9 #include "base/message_loop/message_loop.h" 9 #include "base/message_loop/message_loop.h"
10 #include "base/process/process.h" 10 #include "base/process/process.h"
(...skipping 156 matching lines...) Expand 10 before | Expand all | Expand 10 after
167 request_info.method = "GET"; 167 request_info.method = "GET";
168 request_info.url = GURL(test_page_url); 168 request_info.url = GURL(test_page_url);
169 request_info.first_party_for_cookies = GURL(test_page_url); 169 request_info.first_party_for_cookies = GURL(test_page_url);
170 request_info.referrer = GURL(); 170 request_info.referrer = GURL();
171 request_info.headers = std::string(); 171 request_info.headers = std::string();
172 request_info.load_flags = 0; 172 request_info.load_flags = 0;
173 request_info.requestor_pid = 0; 173 request_info.requestor_pid = 0;
174 request_info.request_type = ResourceType::SUB_RESOURCE; 174 request_info.request_type = ResourceType::SUB_RESOURCE;
175 request_info.appcache_host_id = appcache::kNoHostId; 175 request_info.appcache_host_id = appcache::kNoHostId;
176 request_info.routing_id = 0; 176 request_info.routing_id = 0;
177 RequestExtraData extra_data(blink::WebPageVisibilityStateVisible, 177 RequestExtraData extra_data;
178 blink::WebString(),
179 false, MSG_ROUTING_NONE, true, GURL(),
180 false, -1, true,
181 PAGE_TRANSITION_LINK, false, -1, -1,
182 kInvalidServiceWorkerProviderId);
183 request_info.extra_data = &extra_data; 178 request_info.extra_data = &extra_data;
184 179
185 return dispatcher_->CreateBridge(request_info); 180 return dispatcher_->CreateBridge(request_info);
186 } 181 }
187 182
188 std::vector<IPC::Message> message_queue_; 183 std::vector<IPC::Message> message_queue_;
189 static scoped_ptr<ResourceDispatcher> dispatcher_; 184 static scoped_ptr<ResourceDispatcher> dispatcher_;
190 }; 185 };
191 186
192 /*static*/ 187 /*static*/
(...skipping 243 matching lines...) Expand 10 before | Expand all | Expand 10 after
436 response_head.error_code = net::OK; 431 response_head.error_code = net::OK;
437 432
438 PerformTest(response_head); 433 PerformTest(response_head);
439 434
440 EXPECT_EQ(base::TimeTicks(), response_info().load_timing.request_start); 435 EXPECT_EQ(base::TimeTicks(), response_info().load_timing.request_start);
441 EXPECT_EQ(base::TimeTicks(), 436 EXPECT_EQ(base::TimeTicks(),
442 response_info().load_timing.connect_timing.dns_start); 437 response_info().load_timing.connect_timing.dns_start);
443 } 438 }
444 439
445 } // namespace content 440 } // namespace content
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698