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

Unified Diff: chrome/browser/sync/glue/favicon_cache_unittest.cc

Issue 773103004: Remove NOTIFICATION_HISTORY_URLS_DELETED (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Remove NotificationObserver from InMemoryURLIndex Created 6 years 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 side-by-side diff with in-line comments
Download patch
Index: chrome/browser/sync/glue/favicon_cache_unittest.cc
diff --git a/chrome/browser/sync/glue/favicon_cache_unittest.cc b/chrome/browser/sync/glue/favicon_cache_unittest.cc
index 9ba409185e78548ecc302f5db4bd584a0529bf2a..d73b08aeb2332267aef69fce0fa72eaf66a79fb8 100644
--- a/chrome/browser/sync/glue/favicon_cache_unittest.cc
+++ b/chrome/browser/sync/glue/favicon_cache_unittest.cc
@@ -1472,10 +1472,7 @@ TEST_F(SyncFaviconCacheTest, HistoryFullClear) {
history::URLsDeletedDetails deletions;
deletions.all_history = true;
EXPECT_EQ((unsigned long)kFaviconBatchSize, GetFaviconCount());
- content::NotificationService::current()->Notify(
- chrome::NOTIFICATION_HISTORY_URLS_DELETED,
- content::Source<Profile>(NULL),
- content::Details<history::URLsDeletedDetails>(&deletions));
+ cache()->OnURLsDeleted(nullptr, deletions);
EXPECT_EQ(0U, GetFaviconCount());
changes = processor()->GetAndResetChangeList();
ASSERT_EQ(changes.size(), (unsigned long)kFaviconBatchSize*2);
@@ -1532,10 +1529,7 @@ TEST_F(SyncFaviconCacheTest, HistorySubsetClear) {
EXPECT_TRUE(changes.empty());
EXPECT_EQ((unsigned long)kFaviconBatchSize, GetFaviconCount());
- content::NotificationService::current()->Notify(
- chrome::NOTIFICATION_HISTORY_URLS_DELETED,
- content::Source<Profile>(NULL),
- content::Details<history::URLsDeletedDetails>(&deletions));
+ cache()->OnURLsDeleted(nullptr, deletions);
EXPECT_EQ((unsigned long)kFaviconBatchSize/2, GetFaviconCount());
changes = processor()->GetAndResetChangeList();
ASSERT_EQ(changes.size(), (unsigned long)kFaviconBatchSize);

Powered by Google App Engine
This is Rietveld 408576698