| 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 "content/browser/site_per_process_browsertest.h" | 5 #include "content/browser/site_per_process_browsertest.h" | 
| 6 | 6 | 
| 7 #include <stddef.h> | 7 #include <stddef.h> | 
| 8 #include <stdint.h> | 8 #include <stdint.h> | 
| 9 | 9 | 
| 10 #include <algorithm> | 10 #include <algorithm> | 
| (...skipping 34 matching lines...) Expand 10 before | Expand all | Expand 10 after  Loading... | 
| 45 #include "content/test/content_browser_test_utils_internal.h" | 45 #include "content/test/content_browser_test_utils_internal.h" | 
| 46 #include "content/test/test_frame_navigation_observer.h" | 46 #include "content/test/test_frame_navigation_observer.h" | 
| 47 #include "ipc/ipc_security_test_util.h" | 47 #include "ipc/ipc_security_test_util.h" | 
| 48 #include "net/dns/mock_host_resolver.h" | 48 #include "net/dns/mock_host_resolver.h" | 
| 49 #include "net/test/embedded_test_server/embedded_test_server.h" | 49 #include "net/test/embedded_test_server/embedded_test_server.h" | 
| 50 #include "third_party/WebKit/public/web/WebInputEvent.h" | 50 #include "third_party/WebKit/public/web/WebInputEvent.h" | 
| 51 #include "third_party/WebKit/public/web/WebSandboxFlags.h" | 51 #include "third_party/WebKit/public/web/WebSandboxFlags.h" | 
| 52 #include "ui/gfx/switches.h" | 52 #include "ui/gfx/switches.h" | 
| 53 | 53 | 
| 54 #if defined(OS_MACOSX) | 54 #if defined(OS_MACOSX) | 
| 55 #include "ui/base/test/scoped_preferred_scroller_style_legacy_mac.h" | 55 #include "ui/base/test/scoped_preferred_scroller_style_mac.h" | 
| 56 #endif | 56 #endif | 
| 57 | 57 | 
| 58 namespace content { | 58 namespace content { | 
| 59 | 59 | 
| 60 namespace { | 60 namespace { | 
| 61 | 61 | 
| 62 // Helper function to send a postMessage and wait for a reply message.  The | 62 // Helper function to send a postMessage and wait for a reply message.  The | 
| 63 // |post_message_script| is executed on the |sender_ftn| frame, and the sender | 63 // |post_message_script| is executed on the |sender_ftn| frame, and the sender | 
| 64 // frame is expected to post |reply_status| from the DOMAutomationController | 64 // frame is expected to post |reply_status| from the DOMAutomationController | 
| 65 // when it receives a reply. | 65 // when it receives a reply. | 
| (...skipping 2075 matching lines...) Expand 10 before | Expand all | Expand 10 after  Loading... | 
| 2141 #if defined(OS_ANDROID) | 2141 #if defined(OS_ANDROID) | 
| 2142 #define MAYBE_FrameOwnerPropertiesPropagationScrolling \ | 2142 #define MAYBE_FrameOwnerPropertiesPropagationScrolling \ | 
| 2143         DISABLED_FrameOwnerPropertiesPropagationScrolling | 2143         DISABLED_FrameOwnerPropertiesPropagationScrolling | 
| 2144 #else | 2144 #else | 
| 2145 #define MAYBE_FrameOwnerPropertiesPropagationScrolling \ | 2145 #define MAYBE_FrameOwnerPropertiesPropagationScrolling \ | 
| 2146         FrameOwnerPropertiesPropagationScrolling | 2146         FrameOwnerPropertiesPropagationScrolling | 
| 2147 #endif | 2147 #endif | 
| 2148 IN_PROC_BROWSER_TEST_F(SitePerProcessBrowserTest, | 2148 IN_PROC_BROWSER_TEST_F(SitePerProcessBrowserTest, | 
| 2149                        MAYBE_FrameOwnerPropertiesPropagationScrolling) { | 2149                        MAYBE_FrameOwnerPropertiesPropagationScrolling) { | 
| 2150 #if defined(OS_MACOSX) | 2150 #if defined(OS_MACOSX) | 
| 2151   ui::test::ScopedPreferredScrollerStyleLegacy scroller_style_override; | 2151   ui::test::ScopedPreferredScrollerStyle scroller_style_override(false); | 
| 2152 #endif | 2152 #endif | 
| 2153   GURL main_url(embedded_test_server()->GetURL( | 2153   GURL main_url(embedded_test_server()->GetURL( | 
| 2154       "a.com", "/frame_owner_properties_scrolling.html")); | 2154       "a.com", "/frame_owner_properties_scrolling.html")); | 
| 2155   NavigateToURL(shell(), main_url); | 2155   NavigateToURL(shell(), main_url); | 
| 2156 | 2156 | 
| 2157   // It is safe to obtain the root frame tree node here, as it doesn't change. | 2157   // It is safe to obtain the root frame tree node here, as it doesn't change. | 
| 2158   FrameTreeNode* root = static_cast<WebContentsImpl*>(shell()->web_contents()) | 2158   FrameTreeNode* root = static_cast<WebContentsImpl*>(shell()->web_contents()) | 
| 2159                             ->GetFrameTree() | 2159                             ->GetFrameTree() | 
| 2160                             ->root(); | 2160                             ->root(); | 
| 2161   ASSERT_EQ(1u, root->child_count()); | 2161   ASSERT_EQ(1u, root->child_count()); | 
| (...skipping 3088 matching lines...) Expand 10 before | Expand all | Expand 10 after  Loading... | 
| 5250 | 5250 | 
| 5251   // Force the renderer to generate a new frame. | 5251   // Force the renderer to generate a new frame. | 
| 5252   EXPECT_TRUE(ExecuteScript(shell()->web_contents(), | 5252   EXPECT_TRUE(ExecuteScript(shell()->web_contents(), | 
| 5253                             "document.body.style.background = 'black'")); | 5253                             "document.body.style.background = 'black'")); | 
| 5254 | 5254 | 
| 5255   // Waits for the next frame. | 5255   // Waits for the next frame. | 
| 5256   observer->Wait(); | 5256   observer->Wait(); | 
| 5257 } | 5257 } | 
| 5258 | 5258 | 
| 5259 }  // namespace content | 5259 }  // namespace content | 
| OLD | NEW | 
|---|