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

Side by Side Diff: content/test/layouttest_support.cc

Issue 18590002: Migrate MediaStream test code from content/shell/renderer/ to content/test/. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: rebase Created 7 years, 5 months 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 | Annotate | Revision Log
« no previous file with comments | « content/shell/renderer/webkit_test_runner.cc ('k') | content/test/test_media_stream_client.h » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
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/public/test/layouttest_support.h" 5 #include "content/public/test/layouttest_support.h"
6 6
7 #include "base/callback.h" 7 #include "base/callback.h"
8 #include "base/lazy_instance.h" 8 #include "base/lazy_instance.h"
9 #include "content/browser/renderer_host/render_widget_host_impl.h" 9 #include "content/browser/renderer_host/render_widget_host_impl.h"
10 #include "content/common/gpu/image_transport_surface.h" 10 #include "content/common/gpu/image_transport_surface.h"
11 #include "content/renderer/render_thread_impl.h" 11 #include "content/renderer/render_thread_impl.h"
12 #include "content/renderer/render_view_impl.h" 12 #include "content/renderer/render_view_impl.h"
13 #include "content/renderer/renderer_webkitplatformsupport_impl.h" 13 #include "content/renderer/renderer_webkitplatformsupport_impl.h"
14 #include "content/test/test_media_stream_client.h"
14 #include "third_party/WebKit/public/platform/WebGamepads.h" 15 #include "third_party/WebKit/public/platform/WebGamepads.h"
15 #include "third_party/WebKit/public/testing/WebFrameTestProxy.h" 16 #include "third_party/WebKit/public/testing/WebFrameTestProxy.h"
16 #include "third_party/WebKit/public/testing/WebTestProxy.h" 17 #include "third_party/WebKit/public/testing/WebTestProxy.h"
17 18
18 #if defined(OS_WIN) && !defined(USE_AURA) 19 #if defined(OS_WIN) && !defined(USE_AURA)
19 #include "content/browser/web_contents/web_contents_drag_win.h" 20 #include "content/browser/web_contents/web_contents_drag_win.h"
20 #endif 21 #endif
21 22
22 #if defined(OS_MACOSX) 23 #if defined(OS_MACOSX)
23 #include "content/browser/renderer_host/popup_menu_helper_mac.h" 24 #include "content/browser/renderer_host/popup_menu_helper_mac.h"
(...skipping 99 matching lines...) Expand 10 before | Expand all | Expand 10 after
123 const WebSize& max_size) { 124 const WebSize& max_size) {
124 static_cast<RenderViewImpl*>(render_view) 125 static_cast<RenderViewImpl*>(render_view)
125 ->EnableAutoResizeForTesting(min_size, max_size); 126 ->EnableAutoResizeForTesting(min_size, max_size);
126 } 127 }
127 128
128 void DisableAutoResizeMode(RenderView* render_view, const WebSize& new_size) { 129 void DisableAutoResizeMode(RenderView* render_view, const WebSize& new_size) {
129 static_cast<RenderViewImpl*>(render_view) 130 static_cast<RenderViewImpl*>(render_view)
130 ->DisableAutoResizeForTesting(new_size); 131 ->DisableAutoResizeForTesting(new_size);
131 } 132 }
132 133
134 void UseMockMediaStreams(RenderView* render_view) {
135 RenderViewImpl* render_view_impl = static_cast<RenderViewImpl*>(render_view);
136 render_view_impl->SetMediaStreamClientForTesting(
137 new TestMediaStreamClient(render_view_impl));
138 }
139
133 } // namespace content 140 } // namespace content
OLDNEW
« no previous file with comments | « content/shell/renderer/webkit_test_runner.cc ('k') | content/test/test_media_stream_client.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698