Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(635)

Side by Side Diff: content/browser/site_per_process_browsertest.cc

Issue 2480903002: Enable overlay scrollbars on ChromeOS (Closed)
Patch Set: Fixed PhishingDOMFeatureExtractor test Created 4 years, 1 month ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
OLDNEW
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 51 matching lines...) Expand 10 before | Expand all | Expand 10 after
62 #include "testing/gtest/include/gtest/gtest.h" 62 #include "testing/gtest/include/gtest/gtest.h"
63 #include "third_party/WebKit/public/platform/WebInsecureRequestPolicy.h" 63 #include "third_party/WebKit/public/platform/WebInsecureRequestPolicy.h"
64 #include "third_party/WebKit/public/web/WebInputEvent.h" 64 #include "third_party/WebKit/public/web/WebInputEvent.h"
65 #include "third_party/WebKit/public/web/WebSandboxFlags.h" 65 #include "third_party/WebKit/public/web/WebSandboxFlags.h"
66 #include "ui/display/display_switches.h" 66 #include "ui/display/display_switches.h"
67 #include "ui/display/screen.h" 67 #include "ui/display/screen.h"
68 #include "ui/events/event.h" 68 #include "ui/events/event.h"
69 #include "ui/events/event_utils.h" 69 #include "ui/events/event_utils.h"
70 #include "ui/events/latency_info.h" 70 #include "ui/events/latency_info.h"
71 #include "ui/gfx/geometry/point.h" 71 #include "ui/gfx/geometry/point.h"
72 #include "ui/native_theme/native_theme_switches.h"
72 73
73 #if defined(USE_AURA) 74 #if defined(USE_AURA)
74 #include "content/browser/renderer_host/render_widget_host_view_aura.h" 75 #include "content/browser/renderer_host/render_widget_host_view_aura.h"
75 #endif 76 #endif
76 77
77 #if defined(OS_MACOSX) 78 #if defined(OS_MACOSX)
78 #include "ui/base/test/scoped_preferred_scroller_style_mac.h" 79 #include "ui/base/test/scoped_preferred_scroller_style_mac.h"
79 #endif 80 #endif
80 81
81 namespace content { 82 namespace content {
(...skipping 463 matching lines...) Expand 10 before | Expand all | Expand 10 after
545 SitePerProcessBrowserTest::SitePerProcessBrowserTest() { 546 SitePerProcessBrowserTest::SitePerProcessBrowserTest() {
546 }; 547 };
547 548
548 std::string SitePerProcessBrowserTest::DepictFrameTree(FrameTreeNode* node) { 549 std::string SitePerProcessBrowserTest::DepictFrameTree(FrameTreeNode* node) {
549 return visualizer_.DepictFrameTree(node); 550 return visualizer_.DepictFrameTree(node);
550 } 551 }
551 552
552 void SitePerProcessBrowserTest::SetUpCommandLine( 553 void SitePerProcessBrowserTest::SetUpCommandLine(
553 base::CommandLine* command_line) { 554 base::CommandLine* command_line) {
554 IsolateAllSitesForTesting(command_line); 555 IsolateAllSitesForTesting(command_line);
556 #if !defined(OS_ANDROID)
557 // TODO(bokan): Needed for scrollability check in
558 // FrameOwnerPropertiesPropagationScrolling. crbug.com/662196.
559 command_line->AppendSwitch(switches::kDisableOverlayScrollbar);
560 #endif
555 }; 561 };
556 562
557 void SitePerProcessBrowserTest::SetUpOnMainThread() { 563 void SitePerProcessBrowserTest::SetUpOnMainThread() {
558 host_resolver()->AddRule("*", "127.0.0.1"); 564 host_resolver()->AddRule("*", "127.0.0.1");
559 ASSERT_TRUE(embedded_test_server()->Start()); 565 ASSERT_TRUE(embedded_test_server()->Start());
560 SetupCrossSiteRedirector(embedded_test_server()); 566 SetupCrossSiteRedirector(embedded_test_server());
561 } 567 }
562 568
563 // 569 //
564 // SitePerProcessHighDPIBrowserTest 570 // SitePerProcessHighDPIBrowserTest
(...skipping 2412 matching lines...) Expand 10 before | Expand all | Expand 10 after
2977 navigation_observer.Wait(); 2983 navigation_observer.Wait();
2978 EXPECT_TRUE(observer.last_navigation_succeeded()); 2984 EXPECT_TRUE(observer.last_navigation_succeeded());
2979 EXPECT_EQ(cross_site_url, observer.last_navigation_url()); 2985 EXPECT_EQ(cross_site_url, observer.last_navigation_url());
2980 EXPECT_EQ(0U, child->child_count()); 2986 EXPECT_EQ(0U, child->child_count());
2981 } 2987 }
2982 } 2988 }
2983 2989
2984 // Verify that "scrolling" property on frame elements propagates to child frames 2990 // Verify that "scrolling" property on frame elements propagates to child frames
2985 // correctly. 2991 // correctly.
2986 // Does not work on android since android has scrollbars overlayed. 2992 // Does not work on android since android has scrollbars overlayed.
2993 // TODO(bokan): Pretty soon most/all platforms will use overlay scrollbars. This
2994 // test should find a better way to check for scrollability. crbug.com/662196.
2987 #if defined(OS_ANDROID) 2995 #if defined(OS_ANDROID)
2988 #define MAYBE_FrameOwnerPropertiesPropagationScrolling \ 2996 #define MAYBE_FrameOwnerPropertiesPropagationScrolling \
2989 DISABLED_FrameOwnerPropertiesPropagationScrolling 2997 DISABLED_FrameOwnerPropertiesPropagationScrolling
2990 #else 2998 #else
2991 #define MAYBE_FrameOwnerPropertiesPropagationScrolling \ 2999 #define MAYBE_FrameOwnerPropertiesPropagationScrolling \
2992 FrameOwnerPropertiesPropagationScrolling 3000 FrameOwnerPropertiesPropagationScrolling
2993 #endif 3001 #endif
2994 IN_PROC_BROWSER_TEST_F(SitePerProcessBrowserTest, 3002 IN_PROC_BROWSER_TEST_F(SitePerProcessBrowserTest,
2995 MAYBE_FrameOwnerPropertiesPropagationScrolling) { 3003 MAYBE_FrameOwnerPropertiesPropagationScrolling) {
2996 #if defined(OS_MACOSX) 3004 #if defined(OS_MACOSX)
(...skipping 5551 matching lines...) Expand 10 before | Expand all | Expand 10 after
8548 EXPECT_TRUE(NavigateToURL(shell(), b_url)); 8556 EXPECT_TRUE(NavigateToURL(shell(), b_url));
8549 8557
8550 base::string16 expected_title(base::UTF8ToUTF16("foo")); 8558 base::string16 expected_title(base::UTF8ToUTF16("foo"));
8551 TitleWatcher title_watcher(popup2->web_contents(), expected_title); 8559 TitleWatcher title_watcher(popup2->web_contents(), expected_title);
8552 EXPECT_TRUE(ExecuteScript( 8560 EXPECT_TRUE(ExecuteScript(
8553 shell(), "window.open('','popup2').postMessage('foo', '*');")); 8561 shell(), "window.open('','popup2').postMessage('foo', '*');"));
8554 EXPECT_EQ(expected_title, title_watcher.WaitAndGetTitle()); 8562 EXPECT_EQ(expected_title, title_watcher.WaitAndGetTitle());
8555 } 8563 }
8556 8564
8557 } // namespace content 8565 } // namespace content
OLDNEW
« no previous file with comments | « chrome/renderer/safe_browsing/threat_dom_details_browsertest.cc ('k') | content/renderer/render_view_browsertest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698