| OLD | NEW |
| 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2012 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/files/file_path.h" | 5 #include "base/files/file_path.h" |
| 6 #include "base/files/scoped_temp_dir.h" | 6 #include "base/files/scoped_temp_dir.h" |
| 7 #include "base/macros.h" | 7 #include "base/macros.h" |
| 8 #include "base/memory/ref_counted.h" | 8 #include "base/memory/ref_counted.h" |
| 9 #include "content/browser/download/download_file_factory.h" | 9 #include "content/browser/download/download_file_factory.h" |
| 10 #include "content/browser/download/download_file_impl.h" | 10 #include "content/browser/download/download_file_impl.h" |
| 11 #include "content/browser/download/download_item_impl.h" | 11 #include "content/browser/download/download_item_impl.h" |
| 12 #include "content/browser/download/download_manager_impl.h" | 12 #include "content/browser/download/download_manager_impl.h" |
| 13 #include "content/browser/download/drag_download_file.h" | 13 #include "content/browser/download/drag_download_file.h" |
| 14 #include "content/browser/download/drag_download_util.h" | 14 #include "content/browser/download/drag_download_util.h" |
| 15 #include "content/browser/web_contents/web_contents_impl.h" | 15 #include "content/browser/web_contents/web_contents_impl.h" |
| 16 #include "content/public/browser/content_browser_client.h" | 16 #include "content/public/browser/content_browser_client.h" |
| 17 #include "content/public/browser/power_save_blocker.h" | |
| 18 #include "content/public/common/content_client.h" | 17 #include "content/public/common/content_client.h" |
| 19 #include "content/public/test/content_browser_test.h" | 18 #include "content/public/test/content_browser_test.h" |
| 20 #include "content/public/test/content_browser_test_utils.h" | 19 #include "content/public/test/content_browser_test_utils.h" |
| 21 #include "content/public/test/download_test_observer.h" | 20 #include "content/public/test/download_test_observer.h" |
| 22 #include "content/public/test/test_utils.h" | 21 #include "content/public/test/test_utils.h" |
| 23 #include "content/shell/browser/shell.h" | 22 #include "content/shell/browser/shell.h" |
| 24 #include "content/shell/browser/shell_browser_context.h" | 23 #include "content/shell/browser/shell_browser_context.h" |
| 25 #include "content/shell/browser/shell_download_manager_delegate.h" | 24 #include "content/shell/browser/shell_download_manager_delegate.h" |
| 25 #include "device/power_save_blocker/power_save_blocker.h" |
| 26 #include "net/test/url_request/url_request_mock_http_job.h" | 26 #include "net/test/url_request/url_request_mock_http_job.h" |
| 27 #include "testing/gmock/include/gmock/gmock.h" | 27 #include "testing/gmock/include/gmock/gmock.h" |
| 28 #include "testing/gtest/include/gtest/gtest.h" | 28 #include "testing/gtest/include/gtest/gtest.h" |
| 29 #include "url/gurl.h" | 29 #include "url/gurl.h" |
| 30 | 30 |
| 31 using testing::_; | 31 using testing::_; |
| 32 using testing::InvokeWithoutArgs; | 32 using testing::InvokeWithoutArgs; |
| 33 | 33 |
| 34 namespace content { | 34 namespace content { |
| 35 | 35 |
| (...skipping 89 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 125 .WillOnce(InvokeWithoutArgs(this, &DragDownloadFileTest::Succeed)); | 125 .WillOnce(InvokeWithoutArgs(this, &DragDownloadFileTest::Succeed)); |
| 126 ON_CALL(*observer.get(), OnDownloadAborted()) | 126 ON_CALL(*observer.get(), OnDownloadAborted()) |
| 127 .WillByDefault(InvokeWithoutArgs(this, &DragDownloadFileTest::FailFast)); | 127 .WillByDefault(InvokeWithoutArgs(this, &DragDownloadFileTest::FailFast)); |
| 128 file->Start(observer.get()); | 128 file->Start(observer.get()); |
| 129 RunMessageLoop(); | 129 RunMessageLoop(); |
| 130 } | 130 } |
| 131 | 131 |
| 132 // TODO(benjhayden): Test Stop(). | 132 // TODO(benjhayden): Test Stop(). |
| 133 | 133 |
| 134 } // namespace content | 134 } // namespace content |
| OLD | NEW |