| OLD | NEW |
| 1 // Copyright 2013 The Chromium Authors. All rights reserved. | 1 // Copyright 2013 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 "base/bind.h" | 5 #include "base/bind.h" |
| 6 #include "base/callback.h" | 6 #include "base/callback.h" |
| 7 #include "base/files/file_path.h" | 7 #include "base/files/file_path.h" |
| 8 #include "base/memory/ref_counted.h" | 8 #include "base/memory/ref_counted.h" |
| 9 #include "base/memory/scoped_ptr.h" | 9 #include "base/memory/scoped_ptr.h" |
| 10 #include "base/memory/weak_ptr.h" | 10 #include "base/memory/weak_ptr.h" |
| 11 #include "base/observer_list.h" | 11 #include "base/observer_list.h" |
| 12 #include "chrome/browser/download/download_history.h" | 12 #include "chrome/browser/download/download_history.h" |
| 13 #include "chrome/browser/download/download_service.h" | 13 #include "chrome/browser/download/download_service.h" |
| 14 #include "chrome/browser/download/download_service_factory.h" | 14 #include "chrome/browser/download/download_service_factory.h" |
| 15 #include "chrome/browser/download/download_ui_controller.h" | 15 #include "chrome/browser/download/download_ui_controller.h" |
| 16 #include "chrome/browser/history/download_row.h" | |
| 17 #include "chrome/browser/profiles/profile.h" | 16 #include "chrome/browser/profiles/profile.h" |
| 18 #include "chrome/test/base/chrome_render_view_host_test_harness.h" | 17 #include "chrome/test/base/chrome_render_view_host_test_harness.h" |
| 18 #include "components/history/core/browser/download_row.h" |
| 19 #include "content/public/test/mock_download_item.h" | 19 #include "content/public/test/mock_download_item.h" |
| 20 #include "content/public/test/mock_download_manager.h" | 20 #include "content/public/test/mock_download_manager.h" |
| 21 #include "testing/gmock/include/gmock/gmock.h" | 21 #include "testing/gmock/include/gmock/gmock.h" |
| 22 #include "testing/gtest/include/gtest/gtest.h" | 22 #include "testing/gtest/include/gtest/gtest.h" |
| 23 | 23 |
| 24 using content::MockDownloadItem; | 24 using content::MockDownloadItem; |
| 25 using content::MockDownloadManager; | 25 using content::MockDownloadManager; |
| 26 using testing::AnyNumber; | 26 using testing::AnyNumber; |
| 27 using testing::Assign; | 27 using testing::Assign; |
| 28 using testing::Return; | 28 using testing::Return; |
| (...skipping 308 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 337 // DownloadUIController. It should ignore the download since it's marked as | 337 // DownloadUIController. It should ignore the download since it's marked as |
| 338 // being restored from history. | 338 // being restored from history. |
| 339 ASSERT_TRUE(manager_observer()); | 339 ASSERT_TRUE(manager_observer()); |
| 340 manager_observer()->OnDownloadCreated(manager(), item.get()); | 340 manager_observer()->OnDownloadCreated(manager(), item.get()); |
| 341 | 341 |
| 342 // Finally, the expectation we've been waiting for: | 342 // Finally, the expectation we've been waiting for: |
| 343 EXPECT_FALSE(notified_item()); | 343 EXPECT_FALSE(notified_item()); |
| 344 } | 344 } |
| 345 | 345 |
| 346 } // namespace | 346 } // namespace |
| OLD | NEW |