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/logging.h" | 5 #include "base/logging.h" |
6 #include "base/utf_string_conversions.h" | 6 #include "base/utf_string_conversions.h" |
7 #include "content/browser/mock_content_browser_client.h" | 7 #include "content/browser/mock_content_browser_client.h" |
8 #include "content/browser/renderer_host/render_view_host_impl.h" | 8 #include "content/browser/renderer_host/render_view_host_impl.h" |
9 #include "content/browser/renderer_host/test_render_view_host.h" | 9 #include "content/browser/renderer_host/test_render_view_host.h" |
10 #include "content/browser/site_instance_impl.h" | 10 #include "content/browser/site_instance_impl.h" |
11 #include "content/browser/web_contents/interstitial_page_impl.h" | 11 #include "content/browser/web_contents/interstitial_page_impl.h" |
12 #include "content/browser/web_contents/navigation_entry_impl.h" | 12 #include "content/browser/web_contents/navigation_entry_impl.h" |
13 #include "content/browser/web_contents/test_web_contents.h" | 13 #include "content/browser/web_contents/test_web_contents.h" |
14 #include "content/common/view_messages.h" | 14 #include "content/common/view_messages.h" |
15 #include "content/public/browser/interstitial_page_delegate.h" | 15 #include "content/public/browser/interstitial_page_delegate.h" |
16 #include "content/public/browser/navigation_details.h" | 16 #include "content/public/browser/navigation_details.h" |
17 #include "content/public/browser/notification_details.h" | 17 #include "content/public/browser/notification_details.h" |
18 #include "content/public/browser/notification_source.h" | 18 #include "content/public/browser/notification_source.h" |
19 #include "content/public/browser/notification_source.h" | 19 #include "content/public/browser/notification_source.h" |
20 #include "content/public/browser/render_widget_host_view.h" | 20 #include "content/public/browser/render_widget_host_view.h" |
21 #include "content/public/browser/web_ui_controller.h" | 21 #include "content/public/browser/web_ui_controller.h" |
22 #include "content/public/browser/web_ui_controller_factory.h" | 22 #include "content/public/browser/web_ui_controller_factory.h" |
23 #include "content/public/common/bindings_policy.h" | 23 #include "content/public/common/bindings_policy.h" |
24 #include "content/public/common/content_constants.h" | 24 #include "content/public/common/content_constants.h" |
25 #include "content/public/common/url_constants.h" | 25 #include "content/public/common/url_constants.h" |
26 #include "content/public/test/mock_render_process_host.h" | 26 #include "content/public/test/mock_render_process_host.h" |
27 #include "content/test/test_browser_thread.h" | 27 #include "content/public/test/test_browser_thread.h" |
28 #include "content/test/test_content_client.h" | 28 #include "content/test/test_content_client.h" |
29 #include "googleurl/src/url_util.h" | 29 #include "googleurl/src/url_util.h" |
30 #include "testing/gtest/include/gtest/gtest.h" | 30 #include "testing/gtest/include/gtest/gtest.h" |
31 #include "webkit/glue/webkit_glue.h" | 31 #include "webkit/glue/webkit_glue.h" |
32 | 32 |
33 using content::BrowserContext; | 33 using content::BrowserContext; |
34 using content::BrowserThread; | 34 using content::BrowserThread; |
35 using content::InterstitialPage; | 35 using content::InterstitialPage; |
36 using content::MockRenderProcessHost; | 36 using content::MockRenderProcessHost; |
37 using content::NavigationEntry; | 37 using content::NavigationEntry; |
(...skipping 1901 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1939 // It should have a transient entry. | 1939 // It should have a transient entry. |
1940 EXPECT_TRUE(other_controller.GetTransientEntry()); | 1940 EXPECT_TRUE(other_controller.GetTransientEntry()); |
1941 | 1941 |
1942 // And the interstitial should be showing. | 1942 // And the interstitial should be showing. |
1943 EXPECT_TRUE(other_contents->ShowingInterstitialPage()); | 1943 EXPECT_TRUE(other_contents->ShowingInterstitialPage()); |
1944 | 1944 |
1945 // And the interstitial should do a reload on don't proceed. | 1945 // And the interstitial should do a reload on don't proceed. |
1946 EXPECT_TRUE(static_cast<InterstitialPageImpl*>( | 1946 EXPECT_TRUE(static_cast<InterstitialPageImpl*>( |
1947 other_contents->GetInterstitialPage())->reload_on_dont_proceed()); | 1947 other_contents->GetInterstitialPage())->reload_on_dont_proceed()); |
1948 } | 1948 } |
OLD | NEW |