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

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

Issue 209613002: Download shelf autohides on showing in shell, just same as regular open Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Added browser and unit tests. Renamed 'UserActed' to 'OpenedOrShown'. Created 4 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/all_download_item_notifier_unittest.cc
diff --git a/chrome/browser/download/all_download_item_notifier_unittest.cc b/chrome/browser/download/all_download_item_notifier_unittest.cc
index 2a4de9e8580e140c1b9c55081c66dfab619d4825..731aa3c4bffee5a6630bed50069a9b08f4b45170 100644
--- a/chrome/browser/download/all_download_item_notifier_unittest.cc
+++ b/chrome/browser/download/all_download_item_notifier_unittest.cc
@@ -28,6 +28,8 @@ class MockNotifierObserver : public AllDownloadItemNotifier::Observer {
content::DownloadManager* manager, content::DownloadItem* item));
MOCK_METHOD2(OnDownloadOpened, void(
content::DownloadManager* manager, content::DownloadItem* item));
+ MOCK_METHOD2(OnDownloadShown, void(
+ content::DownloadManager* manager, content::DownloadItem* item));
MOCK_METHOD2(OnDownloadRemoved, void(
content::DownloadManager* manager, content::DownloadItem* item));
@@ -94,6 +96,9 @@ TEST_F(AllDownloadItemNotifierTest,
EXPECT_CALL(observer(), OnDownloadOpened(&manager(), &item()));
NotifierAsItemObserver()->OnDownloadOpened(&item());
+ EXPECT_CALL(observer(), OnDownloadShown(&manager(), &item()));
+ NotifierAsItemObserver()->OnDownloadShown(&item());
+
EXPECT_CALL(observer(), OnDownloadRemoved(&manager(), &item()));
NotifierAsItemObserver()->OnDownloadRemoved(&item());
« no previous file with comments | « chrome/browser/download/all_download_item_notifier.cc ('k') | chrome/browser/download/chrome_download_manager_delegate.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698