Index: chrome/browser/history/top_sites_impl_unittest.cc |
diff --git a/chrome/browser/history/top_sites_impl_unittest.cc b/chrome/browser/history/top_sites_impl_unittest.cc |
index 799a011e2d2bbd523247ed4ae7b8015782a1a49b..e5b9209f6cf585f880fb7eb5993ebbf98550180f 100644 |
--- a/chrome/browser/history/top_sites_impl_unittest.cc |
+++ b/chrome/browser/history/top_sites_impl_unittest.cc |
@@ -15,6 +15,7 @@ |
#include "chrome/browser/history/top_sites.h" |
#include "chrome/browser/history/top_sites_cache.h" |
#include "chrome/browser/history/top_sites_impl.h" |
+#include "chrome/browser/history/top_sites_factory.h" |
#include "chrome/common/chrome_constants.h" |
#include "chrome/common/chrome_paths.h" |
#include "chrome/test/base/testing_profile.h" |
@@ -54,8 +55,7 @@ TestTopSitesObserver::TestTopSitesObserver(Profile* profile, |
void TestTopSitesObserver::TopSitesLoaded(history::TopSites* top_sites) { |
content::NotificationService::current()->Notify( |
- chrome::NOTIFICATION_TOP_SITES_LOADED, |
- content::Source<Profile>(profile_), |
+ chrome::NOTIFICATION_TOP_SITES_LOADED, content::Source<Profile>(profile_), |
content::Details<history::TopSites>(top_sites)); |
} |
@@ -236,7 +236,8 @@ class TopSitesImplTest : public HistoryUnitTestBase { |
} |
TopSitesImpl* top_sites() { |
- return static_cast<TopSitesImpl*>(profile_->GetTopSites()); |
+ return static_cast<TopSitesImpl*>( |
+ TopSitesFactory::GetForProfile(profile_).get()); |
} |
TestingProfile* profile() {return profile_.get();} |
HistoryService* history_service() { |
@@ -369,9 +370,9 @@ class TopSitesImplTest : public HistoryUnitTestBase { |
if (top_sites_observer_) |
top_sites_observer_.reset(); |
- profile_->CreateTopSites(); |
+ profile_->CreateTopSitesService(); |
top_sites_observer_.reset( |
- new TestTopSitesObserver(profile_.get(), profile_->GetTopSites())); |
+ new TestTopSitesObserver(profile_.get(), TopSitesFactory::GetForProfile(profile_)); |
Bernhard Bauer
2015/01/06 11:10:30
Please fit this into 80 columns.
Jitu( very slow this week)
2015/01/08 09:38:25
Done.
|
} |
private: |