Index: chrome/browser/safe_browsing/download_protection_service_unittest.cc |
diff --git a/chrome/browser/safe_browsing/download_protection_service_unittest.cc b/chrome/browser/safe_browsing/download_protection_service_unittest.cc |
index 1b44858b1f9258c0428c790fbb516a5edde32118..20e652796a1ca447cda04e873dcdd4ec9d918cb1 100644 |
--- a/chrome/browser/safe_browsing/download_protection_service_unittest.cc |
+++ b/chrome/browser/safe_browsing/download_protection_service_unittest.cc |
@@ -431,6 +431,12 @@ class DownloadProtectionServiceTest : public testing::Test { |
final_path_ = final_full_path; |
hash_ = "hash"; |
+ if (url_chain_.size() > 0) { |
+ EXPECT_CALL(*item, GetURL()).WillRepeatedly(ReturnRef(url_chain_.back())); |
+ } else{ |
+ GURL empty_url; |
+ EXPECT_CALL(*item, GetURL()).WillRepeatedly(ReturnRef(empty_url)); |
+ } |
EXPECT_CALL(*item, GetFullPath()).WillRepeatedly(ReturnRef(tmp_path_)); |
EXPECT_CALL(*item, GetTargetFilePath()) |
.WillRepeatedly(ReturnRef(final_path_)); |