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

Unified Diff: chrome/browser/download/download_item_unittest.cc

Issue 8468020: Propagate the SafeBrowsing download protection verdict to the DownloadItem. (Closed) Base URL: http://git.chromium.org/git/chromium.git@trunk
Patch Set: Merge Created 9 years, 1 month 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/download/download_item_unittest.cc
diff --git a/chrome/browser/download/download_item_unittest.cc b/chrome/browser/download/download_item_unittest.cc
index 85edae9c42a7d7f08a555eaef4b632ca01454405..1a0a4f0b793f10d8b7415379c5d3d532a932bb90 100644
--- a/chrome/browser/download/download_item_unittest.cc
+++ b/chrome/browser/download/download_item_unittest.cc
@@ -192,8 +192,7 @@ TEST_F(DownloadItemTest, NotificationAfterSetFileCheckResults) {
MockObserver safe_observer(safe_item);
DownloadStateInfo state = safe_item->state_info();;
- state.is_dangerous_file = false;
- state.is_dangerous_url = false;
+ state.danger = DownloadStateInfo::NOT_DANGEROUS;
safe_item->SetFileCheckResults(state);
ASSERT_FALSE(safe_observer.CheckUpdated());
@@ -202,8 +201,7 @@ TEST_F(DownloadItemTest, NotificationAfterSetFileCheckResults) {
MockObserver unsafeurl_observer(unsafeurl_item);
state = unsafeurl_item->state_info();;
- state.is_dangerous_file = false;
- state.is_dangerous_url = true;
+ state.danger = DownloadStateInfo::DANGEROUS_URL;
unsafeurl_item->SetFileCheckResults(state);
ASSERT_TRUE(unsafeurl_observer.CheckUpdated());
@@ -214,8 +212,7 @@ TEST_F(DownloadItemTest, NotificationAfterSetFileCheckResults) {
MockObserver unsafefile_observer(unsafefile_item);
state = unsafefile_item->state_info();;
- state.is_dangerous_file = true;
- state.is_dangerous_url = false;
+ state.danger = DownloadStateInfo::DANGEROUS_FILE;
unsafefile_item->SetFileCheckResults(state);
ASSERT_TRUE(unsafefile_observer.CheckUpdated());

Powered by Google App Engine
This is Rietveld 408576698