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

Unified Diff: components/favicon/core/favicon_handler_unittest.cc

Issue 2828173002: [Refactor] Simplify HistoryBackend::UpdateFaviconMappingsAndFetchImpl() signature (Closed)
Patch Set: Merge branch 'master' into icon_type0 Created 3 years, 8 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 side-by-side diff with in-line comments
Download patch
Index: components/favicon/core/favicon_handler_unittest.cc
diff --git a/components/favicon/core/favicon_handler_unittest.cc b/components/favicon/core/favicon_handler_unittest.cc
index 4a997f382474f3ff6783867958eccd253e6ccf70..7cc76f768822a6f1c3e7c288193318429cc6b527 100644
--- a/components/favicon/core/favicon_handler_unittest.cc
+++ b/components/favicon/core/favicon_handler_unittest.cc
@@ -264,13 +264,12 @@ class FakeFaviconService {
base::CancelableTaskTracker::TaskId UpdateFaviconMappingsAndFetch(
const GURL& page_url,
- const std::vector<GURL>& icon_urls,
- int icon_types,
+ const GURL& icon_url,
+ favicon_base::IconType icon_type,
int desired_size_in_dip,
const favicon_base::FaviconResultsCallback& callback,
base::CancelableTaskTracker* tracker) {
- CHECK_EQ(1U, icon_urls.size()) << "Multi-icon lookup not implemented";
- return GetFaviconForPageOrIconURL(icon_urls.front(), callback, tracker);
+ return GetFaviconForPageOrIconURL(icon_url, callback, tracker);
}
private:
@@ -408,9 +407,9 @@ TEST_F(FaviconHandlerTest, GetFaviconFromHistory) {
// Test that UpdateFaviconsAndFetch() is called with the appropriate parameters
// when there is data in the database for neither the page URL nor the icon URL.
TEST_F(FaviconHandlerTest, UpdateFaviconMappingsAndFetch) {
- EXPECT_CALL(favicon_service_, UpdateFaviconMappingsAndFetch(
- kPageURL, URLVector{kIconURL16x16}, FAVICON,
- /*desired_size_in_dip=*/16, _, _));
+ EXPECT_CALL(favicon_service_,
+ UpdateFaviconMappingsAndFetch(kPageURL, kIconURL16x16, FAVICON,
+ /*desired_size_in_dip=*/16, _, _));
RunHandlerWithSimpleFaviconCandidates({kIconURL16x16});
}

Powered by Google App Engine
This is Rietveld 408576698