OLD | NEW |
1 // Copyright 2017 The Chromium Authors. All rights reserved. | 1 // Copyright 2017 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/notification_image_reporter.h" | 5 #include "chrome/browser/safe_browsing/notification_image_reporter.h" |
6 | 6 |
7 #include "base/callback.h" | 7 #include "base/callback.h" |
8 #include "base/memory/ptr_util.h" | 8 #include "base/memory/ptr_util.h" |
9 #include "base/run_loop.h" | 9 #include "base/run_loop.h" |
10 #include "base/test/scoped_feature_list.h" | 10 #include "base/test/scoped_feature_list.h" |
11 #include "chrome/browser/safe_browsing/mock_permission_report_sender.h" | 11 #include "chrome/browser/safe_browsing/mock_permission_report_sender.h" |
12 #include "chrome/browser/safe_browsing/ping_manager.h" | 12 #include "chrome/browser/safe_browsing/ping_manager.h" |
13 #include "chrome/browser/safe_browsing/test_safe_browsing_service.h" | 13 #include "chrome/browser/safe_browsing/test_safe_browsing_service.h" |
14 #include "chrome/common/safe_browsing/csd.pb.h" | |
15 #include "chrome/test/base/testing_browser_process.h" | 14 #include "chrome/test/base/testing_browser_process.h" |
16 #include "chrome/test/base/testing_profile.h" | 15 #include "chrome/test/base/testing_profile.h" |
| 16 #include "components/safe_browsing/csd.pb.h" |
17 #include "components/safe_browsing_db/safe_browsing_prefs.h" | 17 #include "components/safe_browsing_db/safe_browsing_prefs.h" |
18 #include "components/safe_browsing_db/test_database_manager.h" | 18 #include "components/safe_browsing_db/test_database_manager.h" |
19 #include "content/public/browser/browser_thread.h" | 19 #include "content/public/browser/browser_thread.h" |
20 #include "content/public/test/test_browser_thread_bundle.h" | 20 #include "content/public/test/test_browser_thread_bundle.h" |
21 #include "testing/gtest/include/gtest/gtest.h" | 21 #include "testing/gtest/include/gtest/gtest.h" |
22 #include "third_party/skia/include/core/SkBitmap.h" | 22 #include "third_party/skia/include/core/SkBitmap.h" |
23 #include "third_party/skia/include/core/SkColor.h" | 23 #include "third_party/skia/include/core/SkColor.h" |
24 #include "url/gurl.h" | 24 #include "url/gurl.h" |
25 | 25 |
26 using content::BrowserThread; | 26 using content::BrowserThread; |
(...skipping 249 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
276 mock_report_sender_->WaitForReportSent(); | 276 mock_report_sender_->WaitForReportSent(); |
277 } | 277 } |
278 ReportNotificationImage(); | 278 ReportNotificationImage(); |
279 notification_image_reporter_->WaitForReportSkipped(); | 279 notification_image_reporter_->WaitForReportSkipped(); |
280 | 280 |
281 EXPECT_EQ(kMaxReportsPerDay, | 281 EXPECT_EQ(kMaxReportsPerDay, |
282 mock_report_sender_->GetAndResetNumberOfReportsSent()); | 282 mock_report_sender_->GetAndResetNumberOfReportsSent()); |
283 } | 283 } |
284 | 284 |
285 } // namespace safe_browsing | 285 } // namespace safe_browsing |
OLD | NEW |