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 "chrome/browser/safe_browsing/download_feedback_service.h" | 5 #include "chrome/browser/safe_browsing/download_feedback_service.h" |
6 | 6 |
7 #include <stddef.h> | 7 #include <stddef.h> |
8 #include <stdint.h> | 8 #include <stdint.h> |
9 | 9 |
10 #include <vector> | 10 #include <vector> |
11 | 11 |
12 #include "base/files/file_util.h" | 12 #include "base/files/file_util.h" |
13 #include "base/files/scoped_temp_dir.h" | 13 #include "base/files/scoped_temp_dir.h" |
14 #include "base/memory/ptr_util.h" | 14 #include "base/memory/ptr_util.h" |
15 #include "base/run_loop.h" | 15 #include "base/run_loop.h" |
| 16 #include "base/single_thread_task_runner.h" |
16 #include "base/strings/string_number_conversions.h" | 17 #include "base/strings/string_number_conversions.h" |
17 #include "chrome/browser/safe_browsing/download_feedback.h" | 18 #include "chrome/browser/safe_browsing/download_feedback.h" |
18 #include "content/public/browser/browser_thread.h" | 19 #include "content/public/browser/browser_thread.h" |
19 #include "content/public/test/mock_download_item.h" | 20 #include "content/public/test/mock_download_item.h" |
20 #include "content/public/test/test_browser_thread_bundle.h" | 21 #include "content/public/test/test_browser_thread_bundle.h" |
21 #include "net/url_request/url_request_test_util.h" | 22 #include "net/url_request/url_request_test_util.h" |
22 #include "testing/gmock/include/gmock/gmock.h" | 23 #include "testing/gmock/include/gmock/gmock.h" |
23 #include "testing/gtest/include/gtest/gtest.h" | 24 #include "testing/gtest/include/gtest/gtest.h" |
24 | 25 |
25 using ::testing::_; | 26 using ::testing::_; |
(...skipping 403 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
429 // was deleted. | 430 // was deleted. |
430 EXPECT_FALSE(base::PathExists(file_path[2])); | 431 EXPECT_FALSE(base::PathExists(file_path[2])); |
431 | 432 |
432 // These files should still exist since the FakeDownloadFeedback does not | 433 // These files should still exist since the FakeDownloadFeedback does not |
433 // delete them. | 434 // delete them. |
434 EXPECT_TRUE(base::PathExists(file_path[0])); | 435 EXPECT_TRUE(base::PathExists(file_path[0])); |
435 EXPECT_TRUE(base::PathExists(file_path[1])); | 436 EXPECT_TRUE(base::PathExists(file_path[1])); |
436 } | 437 } |
437 | 438 |
438 } // namespace safe_browsing | 439 } // namespace safe_browsing |
OLD | NEW |