Index: chrome/test/base/testing_profile.cc |
=================================================================== |
--- chrome/test/base/testing_profile.cc (revision 152962) |
+++ chrome/test/base/testing_profile.cc (working copy) |
@@ -319,22 +319,17 @@ |
path = path.Append(chrome::kHistoryFilename); |
file_util::Delete(path, false); |
} |
+ // This will create and init the history service. |
HistoryService* history_service = static_cast<HistoryService*>( |
HistoryServiceFactory::GetInstance()->SetTestingFactoryAndUse( |
this, BuildHistoryService).get()); |
- if (!InitHistoryService(history_service, no_db)) |
+ if (!history_service->Init(this->GetPath(), |
+ BookmarkModelFactory::GetForProfile(this), |
+ no_db)) { |
HistoryServiceFactory::GetInstance()->SetTestingFactoryAndUse(this, NULL); |
+ } |
} |
-bool TestingProfile::InitHistoryService(HistoryService* history_service, |
- bool no_db) { |
- DCHECK(history_service); |
- // By default, disable the InMemoryURLIndex's cache database. |
- return history_service->Init(GetPath(), |
- BookmarkModelFactory::GetForProfile(this), |
- no_db, true); |
-} |
- |
void TestingProfile::DestroyHistoryService() { |
scoped_refptr<HistoryService> history_service = |
HistoryServiceFactory::GetForProfileWithoutCreating(this); |