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..7c1c5f7d2330f43adf7dde060c3b07e27c2cd62a 100644 |
--- a/chrome/browser/download/download_item_unittest.cc |
+++ b/chrome/browser/download/download_item_unittest.cc |
@@ -10,6 +10,7 @@ |
#include "content/browser/download/download_item.h" |
#include "content/browser/download/download_status_updater.h" |
#include "content/browser/download/interrupt_reasons.h" |
+#include "content/browser/download/mock_download_item.h" |
#include "content/browser/download/mock_download_manager.h" |
#include "content/browser/download/mock_download_manager_delegate.h" |
#include "content/test/test_browser_thread.h" |
@@ -191,7 +192,7 @@ TEST_F(DownloadItemTest, NotificationAfterSetFileCheckResults) { |
DownloadItem* safe_item = CreateDownloadItem(DownloadItem::IN_PROGRESS); |
MockObserver safe_observer(safe_item); |
- DownloadStateInfo state = safe_item->state_info();; |
+ DownloadStateInfo state = safe_item->GetStateInfo();; |
state.is_dangerous_file = false; |
state.is_dangerous_url = false; |
safe_item->SetFileCheckResults(state); |
@@ -201,7 +202,7 @@ TEST_F(DownloadItemTest, NotificationAfterSetFileCheckResults) { |
DownloadItem* unsafeurl_item = CreateDownloadItem(DownloadItem::IN_PROGRESS); |
MockObserver unsafeurl_observer(unsafeurl_item); |
- state = unsafeurl_item->state_info();; |
+ state = unsafeurl_item->GetStateInfo();; |
state.is_dangerous_file = false; |
state.is_dangerous_url = true; |
unsafeurl_item->SetFileCheckResults(state); |
@@ -213,7 +214,7 @@ TEST_F(DownloadItemTest, NotificationAfterSetFileCheckResults) { |
DownloadItem* unsafefile_item = CreateDownloadItem(DownloadItem::IN_PROGRESS); |
MockObserver unsafefile_observer(unsafefile_item); |
- state = unsafefile_item->state_info();; |
+ state = unsafefile_item->GetStateInfo();; |
state.is_dangerous_file = true; |
state.is_dangerous_url = false; |
unsafefile_item->SetFileCheckResults(state); |
@@ -251,3 +252,7 @@ TEST_F(DownloadItemTest, NotificationAfterTogglePause) { |
item->TogglePause(); |
ASSERT_TRUE(observer.CheckUpdated()); |
} |
+ |
+TEST(MockDownloadItem, Compiles) { |
cbentzel
2011/11/16 12:28:44
Do you want to remove this test?
benjhayden
2011/11/18 18:59:34
No, because it ensures that MockDownloadItem doesn
|
+ MockDownloadItem mock_item; |
+} |