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

Side by Side Diff: content/browser/download/download_manager_impl_unittest.cc

Issue 2898443002: Implement GetBrowsingDataRemoverDelegate() for BrowserContext subclasses (Closed)
Patch Set: More fixes. Created 3 years, 7 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 | « content/browser/browser_context.cc ('k') | content/public/browser/browser_context.h » ('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 "content/browser/download/download_manager_impl.h" 5 #include "content/browser/download/download_manager_impl.h"
6 6
7 #include <stddef.h> 7 #include <stddef.h>
8 #include <stdint.h> 8 #include <stdint.h>
9 9
10 #include <map> 10 #include <map>
(...skipping 297 matching lines...) Expand 10 before | Expand all | Expand 10 after
308 ZoomLevelDelegate*(const base::FilePath&)); 308 ZoomLevelDelegate*(const base::FilePath&));
309 MOCK_CONST_METHOD0(IsOffTheRecord, bool()); 309 MOCK_CONST_METHOD0(IsOffTheRecord, bool());
310 MOCK_METHOD0(GetResourceContext, ResourceContext*()); 310 MOCK_METHOD0(GetResourceContext, ResourceContext*());
311 MOCK_METHOD0(GetDownloadManagerDelegate, DownloadManagerDelegate*()); 311 MOCK_METHOD0(GetDownloadManagerDelegate, DownloadManagerDelegate*());
312 MOCK_METHOD0(GetGuestManager, BrowserPluginGuestManager* ()); 312 MOCK_METHOD0(GetGuestManager, BrowserPluginGuestManager* ());
313 MOCK_METHOD0(GetSpecialStoragePolicy, storage::SpecialStoragePolicy*()); 313 MOCK_METHOD0(GetSpecialStoragePolicy, storage::SpecialStoragePolicy*());
314 MOCK_METHOD0(GetPushMessagingService, PushMessagingService*()); 314 MOCK_METHOD0(GetPushMessagingService, PushMessagingService*());
315 MOCK_METHOD0(GetSSLHostStateDelegate, SSLHostStateDelegate*()); 315 MOCK_METHOD0(GetSSLHostStateDelegate, SSLHostStateDelegate*());
316 MOCK_METHOD0(GetPermissionManager, PermissionManager*()); 316 MOCK_METHOD0(GetPermissionManager, PermissionManager*());
317 MOCK_METHOD0(GetBackgroundSyncController, BackgroundSyncController*()); 317 MOCK_METHOD0(GetBackgroundSyncController, BackgroundSyncController*());
318 MOCK_METHOD0(GetBrowsingDataRemoverDelegate, BrowsingDataRemoverDelegate*());
318 MOCK_METHOD0(CreateMediaRequestContext, 319 MOCK_METHOD0(CreateMediaRequestContext,
319 net::URLRequestContextGetter*()); 320 net::URLRequestContextGetter*());
320 MOCK_METHOD2(CreateMediaRequestContextForStoragePartition, 321 MOCK_METHOD2(CreateMediaRequestContextForStoragePartition,
321 net::URLRequestContextGetter*( 322 net::URLRequestContextGetter*(
322 const base::FilePath& partition_path, bool in_memory)); 323 const base::FilePath& partition_path, bool in_memory));
323 324
324 // Define these two methods to avoid a 325 // Define these two methods to avoid a
325 // 'cannot access private member declared in class 326 // 'cannot access private member declared in class
326 // URLRequestInterceptorScopedVector' 327 // URLRequestInterceptorScopedVector'
327 // build error if they're put in MOCK_METHOD. 328 // build error if they're put in MOCK_METHOD.
(...skipping 313 matching lines...) Expand 10 before | Expand all | Expand 10 after
641 EXPECT_CALL(GetMockDownloadItem(1), Remove()).Times(0); 642 EXPECT_CALL(GetMockDownloadItem(1), Remove()).Times(0);
642 643
643 base::Callback<bool(const GURL&)> url_filter = 644 base::Callback<bool(const GURL&)> url_filter =
644 GetSingleURLFilter(download_urls_[0]); 645 GetSingleURLFilter(download_urls_[0]);
645 int remove_count = download_manager_->RemoveDownloadsByURLAndTime( 646 int remove_count = download_manager_->RemoveDownloadsByURLAndTime(
646 url_filter, base::Time(), base::Time::Max()); 647 url_filter, base::Time(), base::Time::Max());
647 EXPECT_EQ(remove_count, 1); 648 EXPECT_EQ(remove_count, 1);
648 } 649 }
649 650
650 } // namespace content 651 } // namespace content
OLDNEW
« no previous file with comments | « content/browser/browser_context.cc ('k') | content/public/browser/browser_context.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698