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 <list> | 5 #include <list> |
6 | 6 |
7 #include "base/run_loop.h" | 7 #include "base/run_loop.h" |
8 #include "chrome/browser/interstitials/chrome_controller_client.h" | 8 #include "chrome/browser/interstitials/chrome_controller_client.h" |
9 #include "chrome/browser/profiles/profile.h" | 9 #include "chrome/browser/profiles/profile.h" |
10 #include "chrome/browser/safe_browsing/safe_browsing_blocking_page.h" | 10 #include "chrome/browser/safe_browsing/safe_browsing_blocking_page.h" |
11 #include "chrome/browser/safe_browsing/test_safe_browsing_service.h" | 11 #include "chrome/browser/safe_browsing/test_safe_browsing_service.h" |
12 #include "chrome/browser/safe_browsing/threat_details.h" | |
13 #include "chrome/browser/safe_browsing/ui_manager.h" | 12 #include "chrome/browser/safe_browsing/ui_manager.h" |
14 #include "chrome/common/pref_names.h" | 13 #include "chrome/common/pref_names.h" |
15 #include "chrome/test/base/chrome_render_view_host_test_harness.h" | 14 #include "chrome/test/base/chrome_render_view_host_test_harness.h" |
16 #include "chrome/test/base/testing_profile.h" | 15 #include "chrome/test/base/testing_profile.h" |
17 #include "components/prefs/pref_service.h" | 16 #include "components/prefs/pref_service.h" |
| 17 #include "components/safe_browsing/browser/threat_details.h" |
18 #include "components/safe_browsing_db/safe_browsing_prefs.h" | 18 #include "components/safe_browsing_db/safe_browsing_prefs.h" |
19 #include "content/public/browser/interstitial_page.h" | 19 #include "content/public/browser/interstitial_page.h" |
20 #include "content/public/browser/navigation_entry.h" | 20 #include "content/public/browser/navigation_entry.h" |
21 #include "content/public/browser/render_process_host.h" | 21 #include "content/public/browser/render_process_host.h" |
22 #include "content/public/browser/web_contents.h" | 22 #include "content/public/browser/web_contents.h" |
23 #include "content/public/test/web_contents_tester.h" | 23 #include "content/public/test/web_contents_tester.h" |
24 #include "testing/gmock/include/gmock/gmock.h" | 24 #include "testing/gmock/include/gmock/gmock.h" |
25 #include "testing/gtest/include/gtest/gtest.h" | 25 #include "testing/gtest/include/gtest/gtest.h" |
26 | 26 |
27 using content::InterstitialPage; | 27 using content::InterstitialPage; |
(...skipping 744 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
772 // The interstitial should be gone. | 772 // The interstitial should be gone. |
773 EXPECT_EQ(CANCEL, user_response()); | 773 EXPECT_EQ(CANCEL, user_response()); |
774 EXPECT_FALSE(GetSafeBrowsingBlockingPage()); | 774 EXPECT_FALSE(GetSafeBrowsingBlockingPage()); |
775 | 775 |
776 // No report should have been sent. | 776 // No report should have been sent. |
777 EXPECT_EQ(0u, ui_manager_->GetThreatDetails()->size()); | 777 EXPECT_EQ(0u, ui_manager_->GetThreatDetails()->size()); |
778 ui_manager_->GetThreatDetails()->clear(); | 778 ui_manager_->GetThreatDetails()->clear(); |
779 } | 779 } |
780 | 780 |
781 } // namespace safe_browsing | 781 } // namespace safe_browsing |
OLD | NEW |