| OLD | NEW |
| 1 // Copyright 2015 The Chromium Authors. All rights reserved. | 1 // Copyright 2015 The Chromium Authors. All rights reserved. |
| 2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
| 3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
| 4 | 4 |
| 5 #include "chrome/browser/download/notification/download_item_notification.h" | 5 #include "chrome/browser/download/notification/download_item_notification.h" |
| 6 | 6 |
| 7 #include <stddef.h> | 7 #include <stddef.h> |
| 8 #include <utility> | 8 #include <utility> |
| 9 | 9 |
| 10 #include "base/macros.h" | 10 #include "base/macros.h" |
| 11 #include "base/message_loop/message_loop.h" | 11 #include "base/message_loop/message_loop.h" |
| 12 #include "base/run_loop.h" | 12 #include "base/run_loop.h" |
| 13 #include "base/test/test_simple_task_runner.h" | 13 #include "base/test/test_simple_task_runner.h" |
| 14 #include "base/thread_task_runner_handle.h" | 14 #include "base/threading/thread_task_runner_handle.h" |
| 15 #include "chrome/browser/download/notification/download_notification_manager.h" | 15 #include "chrome/browser/download/notification/download_notification_manager.h" |
| 16 #include "chrome/browser/notifications/notification_test_util.h" | 16 #include "chrome/browser/notifications/notification_test_util.h" |
| 17 #include "chrome/browser/notifications/platform_notification_service_impl.h" | 17 #include "chrome/browser/notifications/platform_notification_service_impl.h" |
| 18 #include "chrome/test/base/testing_browser_process.h" | 18 #include "chrome/test/base/testing_browser_process.h" |
| 19 #include "chrome/test/base/testing_profile.h" | 19 #include "chrome/test/base/testing_profile.h" |
| 20 #include "chrome/test/base/testing_profile_manager.h" | 20 #include "chrome/test/base/testing_profile_manager.h" |
| 21 #include "content/public/test/mock_download_item.h" | 21 #include "content/public/test/mock_download_item.h" |
| 22 #include "content/public/test/mock_download_manager.h" | 22 #include "content/public/test/mock_download_manager.h" |
| 23 #include "content/public/test/test_browser_thread.h" | 23 #include "content/public/test/test_browser_thread.h" |
| 24 #include "testing/gmock/include/gmock/gmock.h" | 24 #include "testing/gmock/include/gmock/gmock.h" |
| (...skipping 271 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 296 EXPECT_CALL(*download_item_, GetState()) | 296 EXPECT_CALL(*download_item_, GetState()) |
| 297 .WillRepeatedly(Return(content::DownloadItem::COMPLETE)); | 297 .WillRepeatedly(Return(content::DownloadItem::COMPLETE)); |
| 298 EXPECT_CALL(*download_item_, IsDone()).WillRepeatedly(Return(true)); | 298 EXPECT_CALL(*download_item_, IsDone()).WillRepeatedly(Return(true)); |
| 299 download_item_->NotifyObserversDownloadUpdated(); | 299 download_item_->NotifyObserversDownloadUpdated(); |
| 300 | 300 |
| 301 // Priority is updated back to normal. | 301 // Priority is updated back to normal. |
| 302 EXPECT_EQ(message_center::DEFAULT_PRIORITY, notification()->priority()); | 302 EXPECT_EQ(message_center::DEFAULT_PRIORITY, notification()->priority()); |
| 303 } | 303 } |
| 304 | 304 |
| 305 } // namespace test | 305 } // namespace test |
| OLD | NEW |