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

Side by Side Diff: chrome/browser/chromeos/gview_request_interceptor_unittest.cc

Issue 10310124: Implement a ResourceThrottle for URL overriding in Chrome on Android. (Closed) Base URL: http://git.chromium.org/chromium/src.git@master
Patch Set: fix build (Referrer is a struct, not a class) Created 8 years, 6 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
« no previous file with comments | « no previous file | chrome/browser/extensions/api/declarative_webrequest/webrequest_condition_attribute_unittest.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
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/at_exit.h" 8 #include "base/at_exit.h"
9 #include "base/message_loop.h" 9 #include "base/message_loop.h"
10 #include "chrome/browser/chrome_plugin_service_filter.h" 10 #include "chrome/browser/chrome_plugin_service_filter.h"
(...skipping 141 matching lines...) Expand 10 before | Expand all | Expand 10 after
152 UnregisterPDFPlugin(); 152 UnregisterPDFPlugin();
153 } 153 }
154 is_loaded = PluginService::GetInstance()->GetPluginInfoByPath( 154 is_loaded = PluginService::GetInstance()->GetPluginInfoByPath(
155 pdf_path_, &info); 155 pdf_path_, &info);
156 ASSERT_EQ(want_loaded, is_loaded); 156 ASSERT_EQ(want_loaded, is_loaded);
157 } 157 }
158 158
159 void SetupRequest(net::URLRequest* request) { 159 void SetupRequest(net::URLRequest* request) {
160 content::ResourceRequestInfo::AllocateForTesting(request, 160 content::ResourceRequestInfo::AllocateForTesting(request,
161 ResourceType::MAIN_FRAME, 161 ResourceType::MAIN_FRAME,
162 &resource_context_); 162 &resource_context_,
163 -1,
164 -1);
163 request->set_context(resource_context_.GetRequestContext()); 165 request->set_context(resource_context_.GetRequestContext());
164 } 166 }
165 167
166 protected: 168 protected:
167 base::ShadowingAtExitManager at_exit_manager_; // Deletes PluginService. 169 base::ShadowingAtExitManager at_exit_manager_; // Deletes PluginService.
168 MessageLoopForIO message_loop_; 170 MessageLoopForIO message_loop_;
169 content::TestBrowserThread ui_thread_; 171 content::TestBrowserThread ui_thread_;
170 content::TestBrowserThread file_thread_; 172 content::TestBrowserThread file_thread_;
171 content::TestBrowserThread io_thread_; 173 content::TestBrowserThread io_thread_;
172 webkit::npapi::MockPluginList plugin_list_; 174 webkit::npapi::MockPluginList plugin_list_;
(...skipping 95 matching lines...) Expand 10 before | Expand all | Expand 10 after
268 SetupRequest(&request); 270 SetupRequest(&request);
269 request.Start(); 271 request.Start();
270 MessageLoop::current()->Run(); 272 MessageLoop::current()->Run();
271 EXPECT_EQ(0, test_delegate_.received_redirect_count()); 273 EXPECT_EQ(0, test_delegate_.received_redirect_count());
272 EXPECT_EQ(GURL(kPdfBlob), request.url()); 274 EXPECT_EQ(GURL(kPdfBlob), request.url());
273 } 275 }
274 276
275 } // namespace 277 } // namespace
276 278
277 } // namespace chromeos 279 } // namespace chromeos
OLDNEW
« no previous file with comments | « no previous file | chrome/browser/extensions/api/declarative_webrequest/webrequest_condition_attribute_unittest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698