Index: chrome/browser/favicon/favicon_handler_unittest.cc |
diff --git a/chrome/browser/favicon/favicon_handler_unittest.cc b/chrome/browser/favicon/favicon_handler_unittest.cc |
index a583065757deb879cfde2b008ab7c19eb41c4328..71024190ea40bd9d8292c51f2fa69a182b9fd993 100644 |
--- a/chrome/browser/favicon/favicon_handler_unittest.cc |
+++ b/chrome/browser/favicon/favicon_handler_unittest.cc |
@@ -189,36 +189,36 @@ class TestFaviconClient : public FaviconClient { |
virtual bool IsBookmarked(const GURL& url) OVERRIDE { return false; } |
}; |
-class TestFaviconHandlerDelegate : public FaviconHandlerDelegate { |
+class TestFaviconDriver : public FaviconDriver { |
public: |
- TestFaviconHandlerDelegate() { |
+ TestFaviconDriver() { |
} |
- virtual ~TestFaviconHandlerDelegate() { |
+ virtual ~TestFaviconDriver() { |
} |
virtual bool IsOffTheRecord() OVERRIDE { return false; } |
virtual NavigationEntry* GetActiveEntry() OVERRIDE { |
- ADD_FAILURE() << "TestFaviconHandlerDelegate::GetActiveEntry() " |
+ ADD_FAILURE() << "TestFaviconDriver::GetActiveEntry() " |
<< "should never be called in tests."; |
return NULL; |
} |
virtual int StartDownload(const GURL& url, |
int max_bitmap_size) OVERRIDE { |
- ADD_FAILURE() << "TestFaviconHandlerDelegate::StartDownload() " |
+ ADD_FAILURE() << "TestFaviconDriver::StartDownload() " |
<< "should never be called in tests."; |
return -1; |
} |
virtual void NotifyFaviconUpdated(bool icon_url_changed) OVERRIDE { |
- ADD_FAILURE() << "TestFaviconHandlerDelegate::NotifyFaviconUpdated() " |
+ ADD_FAILURE() << "TestFaviconDriver::NotifyFaviconUpdated() " |
<< "should never be called in tests."; |
} |
private: |
- DISALLOW_COPY_AND_ASSIGN(TestFaviconHandlerDelegate); |
+ DISALLOW_COPY_AND_ASSIGN(TestFaviconDriver); |
}; |
// This class is used to catch the FaviconHandler's download and history |
@@ -228,7 +228,7 @@ class TestFaviconHandler : public FaviconHandler { |
public: |
TestFaviconHandler(const GURL& page_url, |
FaviconClient* client, |
- FaviconHandlerDelegate* delegate, |
+ FaviconDriver* delegate, |
Type type, |
bool download_largest_icon) |
: FaviconHandler(client, delegate, type, |
@@ -473,7 +473,7 @@ TEST_F(FaviconHandlerTest, GetFaviconFromHistory) { |
const GURL page_url("http://www.google.com"); |
const GURL icon_url("http://www.google.com/favicon"); |
- TestFaviconHandlerDelegate delegate; |
+ TestFaviconDriver delegate; |
TestFaviconClient client; |
TestFaviconHandler helper( |
page_url, &client, &delegate, FaviconHandler::FAVICON, false); |
@@ -514,7 +514,7 @@ TEST_F(FaviconHandlerTest, DownloadFavicon) { |
const GURL page_url("http://www.google.com"); |
const GURL icon_url("http://www.google.com/favicon"); |
- TestFaviconHandlerDelegate delegate; |
+ TestFaviconDriver delegate; |
TestFaviconClient client; |
TestFaviconHandler helper( |
page_url, &client, &delegate, FaviconHandler::FAVICON, false); |
@@ -584,7 +584,7 @@ TEST_F(FaviconHandlerTest, UpdateAndDownloadFavicon) { |
const GURL icon_url("http://www.google.com/favicon"); |
const GURL new_icon_url("http://www.google.com/new_favicon"); |
- TestFaviconHandlerDelegate delegate; |
+ TestFaviconDriver delegate; |
blundell
2014/04/28 08:59:28
Rename this variable to driver everywhere in this
|
TestFaviconClient client; |
TestFaviconHandler helper( |
page_url, &client, &delegate, FaviconHandler::FAVICON, false); |
@@ -666,7 +666,7 @@ TEST_F(FaviconHandlerTest, FaviconInHistoryInvalid) { |
const GURL page_url("http://www.google.com"); |
const GURL icon_url("http://www.google.com/favicon"); |
- TestFaviconHandlerDelegate delegate; |
+ TestFaviconDriver delegate; |
TestFaviconClient client; |
TestFaviconHandler helper( |
page_url, &client, &delegate, FaviconHandler::FAVICON, false); |
@@ -739,7 +739,7 @@ TEST_F(FaviconHandlerTest, UpdateFavicon) { |
const GURL icon_url("http://www.google.com/favicon"); |
const GURL new_icon_url("http://www.google.com/new_favicon"); |
- TestFaviconHandlerDelegate delegate; |
+ TestFaviconDriver delegate; |
TestFaviconClient client; |
TestFaviconHandler helper( |
page_url, &client, &delegate, FaviconHandler::FAVICON, false); |
@@ -801,7 +801,7 @@ TEST_F(FaviconHandlerTest, Download2ndFaviconURLCandidate) { |
const GURL icon_url("http://www.google.com/favicon"); |
const GURL new_icon_url("http://www.google.com/new_favicon"); |
- TestFaviconHandlerDelegate delegate; |
+ TestFaviconDriver delegate; |
TestFaviconClient client; |
TestFaviconHandler helper( |
page_url, &client, &delegate, FaviconHandler::TOUCH, false); |
@@ -915,7 +915,7 @@ TEST_F(FaviconHandlerTest, UpdateDuringDownloading) { |
const GURL icon_url("http://www.google.com/favicon"); |
const GURL new_icon_url("http://www.google.com/new_favicon"); |
- TestFaviconHandlerDelegate delegate; |
+ TestFaviconDriver delegate; |
TestFaviconClient client; |
TestFaviconHandler helper( |
page_url, &client, &delegate, FaviconHandler::TOUCH, false); |
@@ -1057,7 +1057,7 @@ TEST_F(FaviconHandlerTest, MultipleFavicons) { |
// 1) Test that if there are several single resolution favicons to choose from |
// that the largest exact match is chosen. |
- TestFaviconHandlerDelegate delegate1; |
+ TestFaviconDriver delegate1; |
TestFaviconClient client; |
TestFaviconHandler handler1( |
kPageURL, &client, &delegate1, FaviconHandler::FAVICON, false); |
@@ -1080,7 +1080,7 @@ TEST_F(FaviconHandlerTest, MultipleFavicons) { |
// 2) Test that if there are several single resolution favicons to choose |
// from, the exact match is preferred even if it results in upsampling. |
- TestFaviconHandlerDelegate delegate2; |
+ TestFaviconDriver delegate2; |
TestFaviconHandler handler2( |
kPageURL, &client, &delegate2, FaviconHandler::FAVICON, false); |
@@ -1096,7 +1096,7 @@ TEST_F(FaviconHandlerTest, MultipleFavicons) { |
// 3) Test that favicons which need to be upsampled a little or downsampled |
// a little are preferred over huge favicons. |
- TestFaviconHandlerDelegate delegate3; |
+ TestFaviconDriver delegate3; |
TestFaviconHandler handler3( |
kPageURL, &client, &delegate3, FaviconHandler::FAVICON, false); |
@@ -1110,7 +1110,7 @@ TEST_F(FaviconHandlerTest, MultipleFavicons) { |
EXPECT_EQ(kSourceIconURLs[expected_index].icon_url, |
handler3.GetEntry()->GetFavicon().url); |
- TestFaviconHandlerDelegate delegate4; |
+ TestFaviconDriver delegate4; |
TestFaviconHandler handler4( |
kPageURL, &client, &delegate4, FaviconHandler::FAVICON, false); |
@@ -1159,7 +1159,7 @@ TEST_F(FaviconHandlerTest, TestSortFavicon) { |
std::vector<gfx::Size>())}; |
TestFaviconClient client; |
- TestFaviconHandlerDelegate delegate1; |
+ TestFaviconDriver delegate1; |
TestFaviconHandler handler1( |
kPageURL, &client, &delegate1, FaviconHandler::FAVICON, true); |
std::vector<FaviconURL> urls1(kSourceIconURLs, |
@@ -1224,7 +1224,7 @@ TEST_F(FaviconHandlerTest, TestDownloadLargestFavicon) { |
std::vector<gfx::Size>())}; |
TestFaviconClient client; |
- TestFaviconHandlerDelegate delegate1; |
+ TestFaviconDriver delegate1; |
TestFaviconHandler handler1( |
kPageURL, &client, &delegate1, FaviconHandler::FAVICON, true); |
std::vector<FaviconURL> urls1(kSourceIconURLs, |
@@ -1296,7 +1296,7 @@ TEST_F(FaviconHandlerTest, TestSelectLargestFavicon) { |
two_icons)}; |
TestFaviconClient client; |
- TestFaviconHandlerDelegate delegate1; |
+ TestFaviconDriver delegate1; |
TestFaviconHandler handler1( |
kPageURL, &client, &delegate1, FaviconHandler::FAVICON, true); |
std::vector<FaviconURL> urls1(kSourceIconURLs, |
@@ -1364,7 +1364,7 @@ TEST_F(FaviconHandlerTest, TestKeepDownloadedLargestFavicon) { |
std::vector<gfx::Size>())}; |
TestFaviconClient client; |
- TestFaviconHandlerDelegate delegate1; |
+ TestFaviconDriver delegate1; |
TestFaviconHandler handler1( |
kPageURL, &client, &delegate1, FaviconHandler::FAVICON, true); |
std::vector<FaviconURL> urls1(kSourceIconURLs, |