OLD | NEW |
1 // Copyright (c) 2011 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2011 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 #ifndef CONTENT_BROWSER_MOCK_CONTENT_BROWSER_CLIENT_H_ | 5 #ifndef CONTENT_BROWSER_MOCK_CONTENT_BROWSER_CLIENT_H_ |
6 #define CONTENT_BROWSER_MOCK_CONTENT_BROWSER_CLIENT_H_ | 6 #define CONTENT_BROWSER_MOCK_CONTENT_BROWSER_CLIENT_H_ |
7 #pragma once | 7 #pragma once |
8 | 8 |
| 9 #include <string> |
| 10 |
9 #include "base/compiler_specific.h" | 11 #include "base/compiler_specific.h" |
10 #include "content/browser/content_browser_client.h" | 12 #include "content/browser/content_browser_client.h" |
11 | 13 |
12 namespace content { | 14 namespace content { |
13 | 15 |
14 // Base for unit tests that need to mock the ContentBrowserClient. | 16 // Base for unit tests that need to mock the ContentBrowserClient. |
15 class MockContentBrowserClient : public ContentBrowserClient { | 17 class MockContentBrowserClient : public ContentBrowserClient { |
16 public: | 18 public: |
17 virtual ~MockContentBrowserClient(); | 19 virtual ~MockContentBrowserClient(); |
18 | 20 |
(...skipping 33 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
52 const content::ResourceContext& context) OVERRIDE; | 54 const content::ResourceContext& context) OVERRIDE; |
53 virtual net::URLRequestContext* OverrideRequestContextForURL( | 55 virtual net::URLRequestContext* OverrideRequestContextForURL( |
54 const GURL& url, const content::ResourceContext& context) OVERRIDE; | 56 const GURL& url, const content::ResourceContext& context) OVERRIDE; |
55 virtual QuotaPermissionContext* CreateQuotaPermissionContext() OVERRIDE; | 57 virtual QuotaPermissionContext* CreateQuotaPermissionContext() OVERRIDE; |
56 virtual void OpenItem(const FilePath& path) OVERRIDE; | 58 virtual void OpenItem(const FilePath& path) OVERRIDE; |
57 virtual void ShowItemInFolder(const FilePath& path) OVERRIDE; | 59 virtual void ShowItemInFolder(const FilePath& path) OVERRIDE; |
58 virtual void AllowCertificateError( | 60 virtual void AllowCertificateError( |
59 SSLCertErrorHandler* handler, | 61 SSLCertErrorHandler* handler, |
60 bool overridable, | 62 bool overridable, |
61 Callback2<SSLCertErrorHandler*, bool>::Type* callback) OVERRIDE; | 63 Callback2<SSLCertErrorHandler*, bool>::Type* callback) OVERRIDE; |
62 virtual void ShowClientCertificateRequestDialog( | 64 virtual void SelectClientCertificate( |
63 int render_process_id, | 65 int render_process_id, |
64 int render_view_id, | 66 int render_view_id, |
65 SSLClientAuthHandler* handler) OVERRIDE; | 67 SSLClientAuthHandler* handler) OVERRIDE; |
66 virtual void AddNewCertificate( | 68 virtual void AddNewCertificate( |
67 net::URLRequest* request, | 69 net::URLRequest* request, |
68 net::X509Certificate* cert, | 70 net::X509Certificate* cert, |
69 int render_process_id, | 71 int render_process_id, |
70 int render_view_id) OVERRIDE; | 72 int render_view_id) OVERRIDE; |
71 virtual void RequestDesktopNotificationPermission( | 73 virtual void RequestDesktopNotificationPermission( |
72 const GURL& source_origin, | 74 const GURL& source_origin, |
(...skipping 44 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
117 #if defined(USE_NSS) | 119 #if defined(USE_NSS) |
118 virtual | 120 virtual |
119 crypto::CryptoModuleBlockingPasswordDelegate* GetCryptoPasswordDelegate( | 121 crypto::CryptoModuleBlockingPasswordDelegate* GetCryptoPasswordDelegate( |
120 const GURL& url) OVERRIDE; | 122 const GURL& url) OVERRIDE; |
121 #endif | 123 #endif |
122 }; | 124 }; |
123 | 125 |
124 } // namespace content | 126 } // namespace content |
125 | 127 |
126 #endif // CONTENT_BROWSER_MOCK_CONTENT_BROWSER_CLIENT_H_ | 128 #endif // CONTENT_BROWSER_MOCK_CONTENT_BROWSER_CLIENT_H_ |
OLD | NEW |