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

Side by Side Diff: content/renderer/render_view_browsertest.cc

Issue 2473163002: Fix tests to ship Aura overlay scrollbars for ChromeOS (Closed)
Patch Set: Flag Off - Removed DCHECKs in painting - Should pass all tests 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 <stddef.h> 5 #include <stddef.h>
6 #include <stdint.h> 6 #include <stdint.h>
7 #include <tuple> 7 #include <tuple>
8 8
9 #include "base/bind.h" 9 #include "base/bind.h"
10 #include "base/callback.h" 10 #include "base/callback.h"
(...skipping 57 matching lines...) Expand 10 before | Expand all | Expand 10 after
68 #include "third_party/WebKit/public/platform/WebHTTPBody.h" 68 #include "third_party/WebKit/public/platform/WebHTTPBody.h"
69 #include "third_party/WebKit/public/platform/WebString.h" 69 #include "third_party/WebKit/public/platform/WebString.h"
70 #include "third_party/WebKit/public/platform/WebURLResponse.h" 70 #include "third_party/WebKit/public/platform/WebURLResponse.h"
71 #include "third_party/WebKit/public/web/WebDataSource.h" 71 #include "third_party/WebKit/public/web/WebDataSource.h"
72 #include "third_party/WebKit/public/web/WebDeviceEmulationParams.h" 72 #include "third_party/WebKit/public/web/WebDeviceEmulationParams.h"
73 #include "third_party/WebKit/public/web/WebFrameContentDumper.h" 73 #include "third_party/WebKit/public/web/WebFrameContentDumper.h"
74 #include "third_party/WebKit/public/web/WebHistoryCommitType.h" 74 #include "third_party/WebKit/public/web/WebHistoryCommitType.h"
75 #include "third_party/WebKit/public/web/WebHistoryItem.h" 75 #include "third_party/WebKit/public/web/WebHistoryItem.h"
76 #include "third_party/WebKit/public/web/WebLocalFrame.h" 76 #include "third_party/WebKit/public/web/WebLocalFrame.h"
77 #include "third_party/WebKit/public/web/WebPerformance.h" 77 #include "third_party/WebKit/public/web/WebPerformance.h"
78 #include "third_party/WebKit/public/web/WebRuntimeFeatures.h"
79 #include "third_party/WebKit/public/web/WebScriptSource.h" 78 #include "third_party/WebKit/public/web/WebScriptSource.h"
80 #include "third_party/WebKit/public/web/WebSettings.h" 79 #include "third_party/WebKit/public/web/WebSettings.h"
81 #include "third_party/WebKit/public/web/WebView.h" 80 #include "third_party/WebKit/public/web/WebView.h"
82 #include "third_party/WebKit/public/web/WebWindowFeatures.h" 81 #include "third_party/WebKit/public/web/WebWindowFeatures.h"
83 #include "ui/events/event.h" 82 #include "ui/events/event.h"
84 #include "ui/events/keycodes/keyboard_codes.h" 83 #include "ui/events/keycodes/keyboard_codes.h"
85 #include "ui/gfx/codec/jpeg_codec.h" 84 #include "ui/gfx/codec/jpeg_codec.h"
86 #include "ui/gfx/range/range.h" 85 #include "ui/gfx/range/range.h"
87 86
88 #if defined(USE_AURA) && defined(USE_X11) 87 #if defined(USE_AURA) && defined(USE_X11)
89 #include <X11/Xlib.h> 88 #include <X11/Xlib.h>
90 #include "ui/events/event_constants.h" 89 #include "ui/events/event_constants.h"
91 #include "ui/events/keycodes/keyboard_code_conversion.h" 90 #include "ui/events/keycodes/keyboard_code_conversion.h"
92 #include "ui/events/test/events_test_utils.h" 91 #include "ui/events/test/events_test_utils.h"
93 #include "ui/events/test/events_test_utils_x11.h" 92 #include "ui/events/test/events_test_utils_x11.h"
94 #endif 93 #endif
95 94
96 #if defined(USE_OZONE) 95 #if defined(USE_OZONE)
97 #include "ui/events/keycodes/keyboard_code_conversion.h" 96 #include "ui/events/keycodes/keyboard_code_conversion.h"
98 #endif 97 #endif
99 98
100 #include "url/url_constants.h" 99 #include "url/url_constants.h"
101 100
102 using base::TimeDelta; 101 using base::TimeDelta;
103 using blink::WebFrame; 102 using blink::WebFrame;
104 using blink::WebFrameContentDumper; 103 using blink::WebFrameContentDumper;
105 using blink::WebInputEvent; 104 using blink::WebInputEvent;
106 using blink::WebLocalFrame; 105 using blink::WebLocalFrame;
107 using blink::WebMouseEvent; 106 using blink::WebMouseEvent;
108 using blink::WebRuntimeFeatures;
109 using blink::WebString; 107 using blink::WebString;
110 using blink::WebTextDirection; 108 using blink::WebTextDirection;
111 using blink::WebURLError; 109 using blink::WebURLError;
112 110
113 namespace content { 111 namespace content {
114 112
115 namespace { 113 namespace {
116 114
117 static const int kProxyRoutingId = 13; 115 static const int kProxyRoutingId = 13;
118 116
(...skipping 89 matching lines...) Expand 10 before | Expand all | Expand 10 after
208 206
209 class RenderViewImplTest : public RenderViewTest { 207 class RenderViewImplTest : public RenderViewTest {
210 public: 208 public:
211 RenderViewImplTest() { 209 RenderViewImplTest() {
212 // Attach a pseudo keyboard device to this object. 210 // Attach a pseudo keyboard device to this object.
213 mock_keyboard_.reset(new MockKeyboard()); 211 mock_keyboard_.reset(new MockKeyboard());
214 } 212 }
215 213
216 ~RenderViewImplTest() override {} 214 ~RenderViewImplTest() override {}
217 215
218 void SetUp() override {
219 // Enable Blink's experimental and test only features so that test code
220 // does not have to bother enabling each feature.
221 WebRuntimeFeatures::enableExperimentalFeatures(true);
222 WebRuntimeFeatures::enableTestOnlyFeatures(true);
223 RenderViewTest::SetUp();
224 }
225
226 RenderViewImpl* view() { 216 RenderViewImpl* view() {
227 return static_cast<RenderViewImpl*>(view_); 217 return static_cast<RenderViewImpl*>(view_);
228 } 218 }
229 219
230 TestRenderFrame* frame() { 220 TestRenderFrame* frame() {
231 return static_cast<TestRenderFrame*>(view()->GetMainRenderFrame()); 221 return static_cast<TestRenderFrame*>(view()->GetMainRenderFrame());
232 } 222 }
233 223
234 void GoToOffsetWithParams(int offset, 224 void GoToOffsetWithParams(int offset,
235 const PageState& state, 225 const PageState& state,
(...skipping 2253 matching lines...) Expand 10 before | Expand all | Expand 10 after
2489 ExpectPauseAndResume(3); 2479 ExpectPauseAndResume(3);
2490 blink::WebScriptSource source2( 2480 blink::WebScriptSource source2(
2491 WebString::fromUTF8("function func2() { func1(); }; func2();")); 2481 WebString::fromUTF8("function func2() { func1(); }; func2();"));
2492 frame()->GetWebFrame()->executeScriptInIsolatedWorld(17, &source2, 1, 1); 2482 frame()->GetWebFrame()->executeScriptInIsolatedWorld(17, &source2, 1, 1);
2493 2483
2494 EXPECT_FALSE(IsPaused()); 2484 EXPECT_FALSE(IsPaused());
2495 Detach(); 2485 Detach();
2496 } 2486 }
2497 2487
2498 } // namespace content 2488 } // namespace content
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698