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/safe_browsing/incident_reporting/resource_request_detec
tor.h" | 5 #include "chrome/browser/safe_browsing/incident_reporting/resource_request_detec
tor.h" |
6 | 6 |
7 #include <utility> | 7 #include <utility> |
8 | 8 |
9 #include "base/bind.h" | 9 #include "base/bind.h" |
10 #include "base/memory/ptr_util.h" | 10 #include "base/memory/ptr_util.h" |
11 #include "base/run_loop.h" | 11 #include "base/run_loop.h" |
12 #include "chrome/browser/safe_browsing/incident_reporting/incident.h" | 12 #include "chrome/browser/safe_browsing/incident_reporting/incident.h" |
13 #include "chrome/browser/safe_browsing/incident_reporting/incident_receiver.h" | 13 #include "chrome/browser/safe_browsing/incident_reporting/incident_receiver.h" |
14 #include "chrome/browser/safe_browsing/incident_reporting/mock_incident_receiver
.h" | 14 #include "chrome/browser/safe_browsing/incident_reporting/mock_incident_receiver
.h" |
15 #include "chrome/common/safe_browsing/csd.pb.h" | 15 #include "components/safe_browsing/csd.pb.h" |
16 #include "components/safe_browsing_db/test_database_manager.h" | 16 #include "components/safe_browsing_db/test_database_manager.h" |
17 #include "content/public/browser/resource_request_info.h" | 17 #include "content/public/browser/resource_request_info.h" |
18 #include "content/public/common/previews_state.h" | 18 #include "content/public/common/previews_state.h" |
19 #include "content/public/common/resource_type.h" | 19 #include "content/public/common/resource_type.h" |
20 #include "content/public/test/test_browser_thread_bundle.h" | 20 #include "content/public/test/test_browser_thread_bundle.h" |
21 #include "crypto/sha2.h" | 21 #include "crypto/sha2.h" |
22 #include "ipc/ipc_message.h" | 22 #include "ipc/ipc_message.h" |
23 #include "net/base/request_priority.h" | 23 #include "net/base/request_priority.h" |
24 #include "net/url_request/url_request.h" | 24 #include "net/url_request/url_request.h" |
25 #include "net/url_request/url_request_test_util.h" | 25 #include "net/url_request/url_request_test_util.h" |
(...skipping 198 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
224 const std::string url = "http://www.example.com/"; | 224 const std::string url = "http://www.example.com/"; |
225 const std::string digest = "dummydigest"; | 225 const std::string digest = "dummydigest"; |
226 for (auto resource_type : supported_types) { | 226 for (auto resource_type : supported_types) { |
227 ExpectAsyncDatabaseCheck(url, true, digest); | 227 ExpectAsyncDatabaseCheck(url, true, digest); |
228 ExpectIncidentAdded(url, resource_type, | 228 ExpectIncidentAdded(url, resource_type, |
229 ResourceRequestIncidentMessage::TYPE_PATTERN, digest); | 229 ResourceRequestIncidentMessage::TYPE_PATTERN, digest); |
230 } | 230 } |
231 } | 231 } |
232 | 232 |
233 } // namespace safe_browsing | 233 } // namespace safe_browsing |
OLD | NEW |