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

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

Issue 10916132: AppCache and StoragePartition'ing (Closed) Base URL: svn://chrome-svn/chrome/trunk/src/
Patch Set: Created 8 years, 3 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 | Annotate | Revision Log
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 <set> 5 #include <set>
6 #include <string> 6 #include <string>
7 7
8 #include "base/bind.h" 8 #include "base/bind.h"
9 #include "base/file_util.h" 9 #include "base/file_util.h"
10 #include "base/memory/scoped_ptr.h" 10 #include "base/memory/scoped_ptr.h"
(...skipping 356 matching lines...) Expand 10 before | Expand all | Expand 10 after
367 class MockBrowserContext : public content::BrowserContext { 367 class MockBrowserContext : public content::BrowserContext {
368 public: 368 public:
369 MockBrowserContext() {} 369 MockBrowserContext() {}
370 ~MockBrowserContext() {} 370 ~MockBrowserContext() {}
371 371
372 MOCK_METHOD0(GetPath, FilePath()); 372 MOCK_METHOD0(GetPath, FilePath());
373 MOCK_CONST_METHOD0(IsOffTheRecord, bool()); 373 MOCK_CONST_METHOD0(IsOffTheRecord, bool());
374 MOCK_METHOD0(GetRequestContext, net::URLRequestContextGetter*()); 374 MOCK_METHOD0(GetRequestContext, net::URLRequestContextGetter*());
375 MOCK_METHOD1(GetRequestContextForRenderProcess, 375 MOCK_METHOD1(GetRequestContextForRenderProcess,
376 net::URLRequestContextGetter*(int renderer_child_id)); 376 net::URLRequestContextGetter*(int renderer_child_id));
377 MOCK_METHOD1(GetRequestContextForStoragePartition,
378 net::URLRequestContextGetter*(const std::string& id));
377 MOCK_METHOD0(GetMediaRequestContext, 379 MOCK_METHOD0(GetMediaRequestContext,
378 net::URLRequestContextGetter*()); 380 net::URLRequestContextGetter*());
379 MOCK_METHOD1(GetMediaRequestContextForRenderProcess, 381 MOCK_METHOD1(GetMediaRequestContextForRenderProcess,
380 net::URLRequestContextGetter*(int renderer_child_id)); 382 net::URLRequestContextGetter*(int renderer_child_id));
381 MOCK_METHOD0(GetResourceContext, content::ResourceContext*()); 383 MOCK_METHOD0(GetResourceContext, content::ResourceContext*());
382 MOCK_METHOD0(GetDownloadManagerDelegate, content::DownloadManagerDelegate*()); 384 MOCK_METHOD0(GetDownloadManagerDelegate, content::DownloadManagerDelegate*());
383 MOCK_METHOD0(GetGeolocationPermissionContext, 385 MOCK_METHOD0(GetGeolocationPermissionContext,
384 content::GeolocationPermissionContext* ()); 386 content::GeolocationPermissionContext* ());
385 MOCK_METHOD0(GetSpeechRecognitionPreferences, 387 MOCK_METHOD0(GetSpeechRecognitionPreferences,
386 content::SpeechRecognitionPreferences* ()); 388 content::SpeechRecognitionPreferences* ());
(...skipping 259 matching lines...) Expand 10 before | Expand all | Expand 10 after
646 UpdateItemInPersistentStore(&item)); 648 UpdateItemInPersistentStore(&item));
647 EXPECT_CALL(item, GetState()) 649 EXPECT_CALL(item, GetState())
648 .WillRepeatedly(Return(DownloadItem::CANCELLED)); 650 .WillRepeatedly(Return(DownloadItem::CANCELLED));
649 EXPECT_CALL(item, GetDbHandle()) 651 EXPECT_CALL(item, GetDbHandle())
650 .WillRepeatedly(Return(db_handle)); 652 .WillRepeatedly(Return(db_handle));
651 653
652 EXPECT_CALL(item, OffThreadCancel()); 654 EXPECT_CALL(item, OffThreadCancel());
653 DownloadStopped(&item); 655 DownloadStopped(&item);
654 EXPECT_EQ(NULL, download_manager_->GetActiveDownloadItem(download_id)); 656 EXPECT_EQ(NULL, download_manager_->GetActiveDownloadItem(download_id));
655 } 657 }
OLDNEW
« no previous file with comments | « content/browser/browser_context.cc ('k') | content/browser/renderer_host/render_process_host_impl.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698