OLD | NEW |
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/macros.h" | 8 #include "base/macros.h" |
9 #include "base/memory/scoped_ptr.h" | 9 #include "base/memory/scoped_ptr.h" |
10 #include "base/memory/shared_memory.h" | 10 #include "base/memory/shared_memory.h" |
(...skipping 304 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
315 } | 315 } |
316 | 316 |
317 ResourceDispatcher* dispatcher() { return &dispatcher_; } | 317 ResourceDispatcher* dispatcher() { return &dispatcher_; } |
318 | 318 |
319 private: | 319 private: |
320 ResourceLoaderBridge* CreateBridgeInternal(bool download_to_file) { | 320 ResourceLoaderBridge* CreateBridgeInternal(bool download_to_file) { |
321 RequestInfo request_info; | 321 RequestInfo request_info; |
322 request_info.method = "GET"; | 322 request_info.method = "GET"; |
323 request_info.url = GURL(kTestPageUrl); | 323 request_info.url = GURL(kTestPageUrl); |
324 request_info.first_party_for_cookies = GURL(kTestPageUrl); | 324 request_info.first_party_for_cookies = GURL(kTestPageUrl); |
325 request_info.referrer = GURL(); | 325 request_info.referrer = Referrer(); |
326 request_info.headers = std::string(); | 326 request_info.headers = std::string(); |
327 request_info.load_flags = 0; | 327 request_info.load_flags = 0; |
328 request_info.requestor_pid = 0; | 328 request_info.requestor_pid = 0; |
329 request_info.request_type = RESOURCE_TYPE_SUB_RESOURCE; | 329 request_info.request_type = RESOURCE_TYPE_SUB_RESOURCE; |
330 request_info.appcache_host_id = kAppCacheNoHostId; | 330 request_info.appcache_host_id = kAppCacheNoHostId; |
331 request_info.routing_id = 0; | 331 request_info.routing_id = 0; |
332 request_info.download_to_file = download_to_file; | 332 request_info.download_to_file = download_to_file; |
333 RequestExtraData extra_data; | 333 RequestExtraData extra_data; |
334 request_info.extra_data = &extra_data; | 334 request_info.extra_data = &extra_data; |
335 | 335 |
(...skipping 445 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
781 ResourceResponseHead response_head; | 781 ResourceResponseHead response_head; |
782 | 782 |
783 PerformTest(response_head); | 783 PerformTest(response_head); |
784 | 784 |
785 EXPECT_EQ(base::TimeTicks(), response_info().load_timing.request_start); | 785 EXPECT_EQ(base::TimeTicks(), response_info().load_timing.request_start); |
786 EXPECT_EQ(base::TimeTicks(), | 786 EXPECT_EQ(base::TimeTicks(), |
787 response_info().load_timing.connect_timing.dns_start); | 787 response_info().load_timing.connect_timing.dns_start); |
788 } | 788 } |
789 | 789 |
790 } // namespace content | 790 } // namespace content |
OLD | NEW |