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 "content/browser/loader/resource_scheduler.h" | 5 #include "content/browser/loader/resource_scheduler.h" |
6 | 6 |
7 #include "base/memory/scoped_vector.h" | 7 #include "base/memory/scoped_vector.h" |
8 #include "base/message_loop/message_loop.h" | 8 #include "base/message_loop/message_loop.h" |
9 #include "base/strings/string_number_conversions.h" | 9 #include "base/strings/string_number_conversions.h" |
10 #include "content/browser/browser_thread_impl.h" | 10 #include "content/browser/browser_thread_impl.h" |
(...skipping 74 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
85 | 85 |
86 scoped_ptr<TestRequest> request_to_cancel_; | 86 scoped_ptr<TestRequest> request_to_cancel_; |
87 }; | 87 }; |
88 | 88 |
89 class FakeResourceContext : public ResourceContext { | 89 class FakeResourceContext : public ResourceContext { |
90 private: | 90 private: |
91 virtual net::HostResolver* GetHostResolver() OVERRIDE { return NULL; } | 91 virtual net::HostResolver* GetHostResolver() OVERRIDE { return NULL; } |
92 virtual net::URLRequestContext* GetRequestContext() OVERRIDE { return NULL; } | 92 virtual net::URLRequestContext* GetRequestContext() OVERRIDE { return NULL; } |
93 virtual bool AllowMicAccess(const GURL& origin) OVERRIDE { return false; } | 93 virtual bool AllowMicAccess(const GURL& origin) OVERRIDE { return false; } |
94 virtual bool AllowCameraAccess(const GURL& origin) OVERRIDE { return false; } | 94 virtual bool AllowCameraAccess(const GURL& origin) OVERRIDE { return false; } |
| 95 virtual std::string GetMediaDeviceIDSalt() OVERRIDE { return std::string(); } |
95 }; | 96 }; |
96 | 97 |
97 class FakeResourceMessageFilter : public ResourceMessageFilter { | 98 class FakeResourceMessageFilter : public ResourceMessageFilter { |
98 public: | 99 public: |
99 FakeResourceMessageFilter(int child_id) | 100 FakeResourceMessageFilter(int child_id) |
100 : ResourceMessageFilter( | 101 : ResourceMessageFilter( |
101 child_id, | 102 child_id, |
102 PROCESS_TYPE_RENDERER, | 103 PROCESS_TYPE_RENDERER, |
103 NULL /* appcache_service */, | 104 NULL /* appcache_service */, |
104 NULL /* blob_storage_context */, | 105 NULL /* blob_storage_context */, |
(...skipping 354 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
459 scoped_ptr<TestRequest> low(NewRequest("http://host/high", net::LOWEST)); | 460 scoped_ptr<TestRequest> low(NewRequest("http://host/high", net::LOWEST)); |
460 | 461 |
461 scoped_ptr<TestRequest> request( | 462 scoped_ptr<TestRequest> request( |
462 NewRequest("chrome-extension://req", net::LOWEST)); | 463 NewRequest("chrome-extension://req", net::LOWEST)); |
463 EXPECT_TRUE(request->started()); | 464 EXPECT_TRUE(request->started()); |
464 } | 465 } |
465 | 466 |
466 } // unnamed namespace | 467 } // unnamed namespace |
467 | 468 |
468 } // namespace content | 469 } // namespace content |
OLD | NEW |