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 fb5138552ee5ec5879cd515c8f237b2ef3015397..698690397fed7df03b51f7383a3f05ad2fdf2847 100644 |
--- a/components/favicon/core/favicon_handler_unittest.cc |
+++ b/components/favicon/core/favicon_handler_unittest.cc |
@@ -247,8 +247,9 @@ class TestFaviconDriver : public FaviconDriver { |
image_ = image; |
} |
- void OnFaviconAvailable(const gfx::Image& image, |
+ void OnFaviconAvailable(const GURL& page_url, |
const GURL& icon_url, |
+ const gfx::Image& image, |
bool update_active_favicon) override { |
++num_favicon_available_; |
available_image_ = image; |
@@ -398,7 +399,7 @@ class TestFaviconHandler : public FaviconHandler { |
page_url, icon_url, icon_type, bitmap_data, image.Size())); |
} |
- bool ShouldSaveFavicon(const GURL& url) override { return true; } |
+ bool ShouldSaveFavicon() override { return true; } |
GURL page_url_; |
@@ -502,7 +503,7 @@ class FaviconHandlerTest : public testing::Test { |
favicon_handler->FetchFavicon(page_url); |
favicon_handler->history_handler()->InvokeCallback(); |
- favicon_handler->OnUpdateFaviconURL(candidate_icons); |
+ favicon_handler->OnUpdateFaviconURL(page_url, candidate_icons); |
} |
void SetUp() override { |
@@ -551,7 +552,7 @@ TEST_F(FaviconHandlerTest, GetFaviconFromHistory) { |
std::vector<FaviconURL> urls; |
urls.push_back( |
FaviconURL(icon_url, favicon_base::FAVICON, std::vector<gfx::Size>())); |
- helper.OnUpdateFaviconURL(urls); |
+ helper.OnUpdateFaviconURL(page_url, urls); |
// Verify FaviconHandler status |
EXPECT_EQ(1U, helper.urls().size()); |
@@ -593,7 +594,7 @@ TEST_F(FaviconHandlerTest, DownloadFavicon) { |
std::vector<FaviconURL> urls; |
urls.push_back( |
FaviconURL(icon_url, favicon_base::FAVICON, std::vector<gfx::Size>())); |
- helper.OnUpdateFaviconURL(urls); |
+ helper.OnUpdateFaviconURL(page_url, urls); |
// Verify FaviconHandler status |
EXPECT_EQ(1U, helper.urls().size()); |
@@ -662,7 +663,7 @@ TEST_F(FaviconHandlerTest, UpdateAndDownloadFavicon) { |
std::vector<FaviconURL> urls; |
urls.push_back(FaviconURL( |
new_icon_url, favicon_base::FAVICON, std::vector<gfx::Size>())); |
- helper.OnUpdateFaviconURL(urls); |
+ helper.OnUpdateFaviconURL(page_url, urls); |
// Verify FaviconHandler status. |
EXPECT_EQ(1U, helper.urls().size()); |
@@ -749,7 +750,7 @@ TEST_F(FaviconHandlerTest, FaviconInHistoryInvalid) { |
std::vector<FaviconURL> urls; |
urls.push_back( |
FaviconURL(icon_url, favicon_base::FAVICON, std::vector<gfx::Size>())); |
- helper.OnUpdateFaviconURL(urls); |
+ helper.OnUpdateFaviconURL(page_url, urls); |
// A download for the favicon should be requested, and we should not do |
// another history request. |
@@ -810,7 +811,7 @@ TEST_F(FaviconHandlerTest, UpdateFavicon) { |
std::vector<FaviconURL> urls; |
urls.push_back(FaviconURL( |
new_icon_url, favicon_base::FAVICON, std::vector<gfx::Size>())); |
- helper.OnUpdateFaviconURL(urls); |
+ helper.OnUpdateFaviconURL(page_url, urls); |
// Verify FaviconHandler status. |
EXPECT_EQ(1U, helper.urls().size()); |
@@ -879,7 +880,7 @@ TEST_F(FaviconHandlerTest, Download2ndFaviconURLCandidate) { |
new_icon_url, favicon_base::TOUCH_ICON, std::vector<gfx::Size>())); |
urls.push_back(FaviconURL( |
new_icon_url, favicon_base::FAVICON, std::vector<gfx::Size>())); |
- helper.OnUpdateFaviconURL(urls); |
+ helper.OnUpdateFaviconURL(page_url, urls); |
// Verify FaviconHandler status. |
EXPECT_EQ(2U, helper.urls().size()); |
@@ -990,7 +991,7 @@ TEST_F(FaviconHandlerTest, UpdateDuringDownloading) { |
new_icon_url, favicon_base::TOUCH_ICON, std::vector<gfx::Size>())); |
urls.push_back(FaviconURL( |
new_icon_url, favicon_base::FAVICON, std::vector<gfx::Size>())); |
- helper.OnUpdateFaviconURL(urls); |
+ helper.OnUpdateFaviconURL(page_url, urls); |
// Verify FaviconHandler status. |
EXPECT_EQ(2U, helper.urls().size()); |
@@ -1024,7 +1025,7 @@ TEST_F(FaviconHandlerTest, UpdateDuringDownloading) { |
std::vector<FaviconURL> latest_urls; |
latest_urls.push_back(FaviconURL( |
latest_icon_url, favicon_base::TOUCH_ICON, std::vector<gfx::Size>())); |
- helper.OnUpdateFaviconURL(latest_urls); |
+ helper.OnUpdateFaviconURL(page_url, latest_urls); |
EXPECT_EQ(1U, helper.urls().size()); |
EXPECT_EQ(latest_icon_url, helper.current_candidate()->icon_url); |