summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--chrome/chrome_tests.gypi9
-rw-r--r--content/browser/renderer_host/render_widget_host_unittest.cc16
-rw-r--r--content/common/notification_service_unittest.cc3
-rw-r--r--content/content_tests.gypi13
4 files changed, 21 insertions, 20 deletions
diff --git a/chrome/chrome_tests.gypi b/chrome/chrome_tests.gypi
index 04b757c..504e41b 100644
--- a/chrome/chrome_tests.gypi
+++ b/chrome/chrome_tests.gypi
@@ -2022,21 +2022,13 @@
'../content/browser/renderer_host/render_view_host_unittest.cc',
'../content/browser/renderer_host/render_widget_host_unittest.cc',
'../content/browser/renderer_host/resource_dispatcher_host_unittest.cc',
- '../content/browser/renderer_host/resource_queue_unittest.cc',
- '../content/browser/resolve_proxy_msg_helper_unittest.cc',
'../content/browser/site_instance_unittest.cc',
- '../content/browser/speech/endpointer/endpointer_unittest.cc',
- '../content/browser/speech/speech_recognition_request_unittest.cc',
- '../content/browser/speech/speech_recognizer_unittest.cc',
'../content/browser/tab_contents/navigation_controller_unittest.cc',
'../content/browser/tab_contents/navigation_entry_unittest.cc',
'../content/browser/tab_contents/render_view_host_manager_unittest.cc',
'../content/browser/tab_contents/tab_contents_delegate_unittest.cc',
'../content/common/font_descriptor_mac_unittest.mm',
- '../content/common/gpu/gpu_feature_flags_unittest.cc',
- '../content/common/gpu/gpu_info_unittest.cc',
'../content/common/hi_res_timer_manager_unittest.cc',
- '../content/common/notification_service_unittest.cc',
'../content/common/sandbox_mac_diraccess_unittest.mm',
'../content/common/sandbox_mac_fontloading_unittest.mm',
'../content/common/sandbox_mac_unittest_helper.h',
@@ -2044,7 +2036,6 @@
'../content/common/sandbox_mac_system_access_unittest.mm',
'../content/gpu/gpu_idirect3d9_mock_win.cc',
'../content/gpu/gpu_idirect3d9_mock_win.h',
- '../content/gpu/gpu_info_collector_unittest.cc',
'../content/gpu/gpu_info_collector_unittest_win.cc',
'../testing/gtest_mac_unittest.mm',
'../third_party/cld/encodings/compact_lang_det/compact_lang_det_unittest_small.cc',
diff --git a/content/browser/renderer_host/render_widget_host_unittest.cc b/content/browser/renderer_host/render_widget_host_unittest.cc
index f77b56a..1cbb45e 100644
--- a/content/browser/renderer_host/render_widget_host_unittest.cc
+++ b/content/browser/renderer_host/render_widget_host_unittest.cc
@@ -6,9 +6,6 @@
#include "base/memory/scoped_ptr.h"
#include "base/shared_memory.h"
#include "base/timer.h"
-#include "build/build_config.h"
-#include "chrome/test/base/testing_browser_process_test.h"
-#include "chrome/test/base/testing_profile.h"
#include "content/browser/browser_thread.h"
#include "content/browser/renderer_host/backing_store.h"
#include "content/browser/renderer_host/test_render_view_host.h"
@@ -17,6 +14,7 @@
#include "content/common/notification_registrar.h"
#include "content/common/notification_source.h"
#include "content/common/view_messages.h"
+#include "content/test/test_browser_context.h"
#include "testing/gtest/include/gtest/gtest.h"
#include "ui/base/keycodes/keyboard_codes.h"
#include "ui/gfx/canvas_skia.h"
@@ -34,8 +32,8 @@ class Size;
class RenderWidgetHostProcess : public MockRenderProcessHost {
public:
- explicit RenderWidgetHostProcess(Profile* profile)
- : MockRenderProcessHost(profile),
+ explicit RenderWidgetHostProcess(content::BrowserContext* browser_context)
+ : MockRenderProcessHost(browser_context),
current_update_buf_(NULL),
update_msg_should_reply_(false),
update_msg_reply_flags_(0) {
@@ -257,8 +255,8 @@ class RenderWidgetHostTest : public TestingBrowserProcessTest {
protected:
// testing::Test
void SetUp() {
- profile_.reset(new TestingProfile());
- process_ = new RenderWidgetHostProcess(profile_.get());
+ browser_context_.reset(new TestBrowserContext());
+ process_ = new RenderWidgetHostProcess(browser_context_.get());
host_.reset(new MockRenderWidgetHost(process_, 1));
view_.reset(new TestView(host_.get()));
host_->SetView(view_.get());
@@ -268,7 +266,7 @@ class RenderWidgetHostTest : public TestingBrowserProcessTest {
view_.reset();
host_.reset();
process_ = NULL;
- profile_.reset();
+ browser_context_.reset();
// Process all pending tasks to avoid leaks.
MessageLoop::current()->RunAllPending();
@@ -300,7 +298,7 @@ class RenderWidgetHostTest : public TestingBrowserProcessTest {
MessageLoopForUI message_loop_;
- scoped_ptr<TestingProfile> profile_;
+ scoped_ptr<TestBrowserContext> browser_context_;
RenderWidgetHostProcess* process_; // Deleted automatically by the widget.
scoped_ptr<MockRenderWidgetHost> host_;
scoped_ptr<TestView> view_;
diff --git a/content/common/notification_service_unittest.cc b/content/common/notification_service_unittest.cc
index a8751c8..a40e11c 100644
--- a/content/common/notification_service_unittest.cc
+++ b/content/common/notification_service_unittest.cc
@@ -2,7 +2,6 @@
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
-#include "chrome/test/base/testing_browser_process_test.h"
#include "content/common/notification_observer.h"
#include "content/common/notification_registrar.h"
#include "content/common/notification_service.h"
@@ -32,7 +31,7 @@ private:
} // namespace
-class NotificationServiceTest : public TestingBrowserProcessTest {
+class NotificationServiceTest : public testing::Test {
protected:
NotificationRegistrar registrar_;
};
diff --git a/content/content_tests.gypi b/content/content_tests.gypi
index e5ddb36..f1124aa 100644
--- a/content/content_tests.gypi
+++ b/content/content_tests.gypi
@@ -54,17 +54,21 @@
'type': 'executable',
'dependencies': [
'content_browser',
+ 'content_gpu',
'content_plugin',
'content_renderer',
'test_support_content',
'../base/base.gyp:test_support_base',
'../crypto/crypto.gyp:crypto',
+ '../gpu/gpu.gyp:gpu_unittest_utils',
+ '../ipc/ipc.gyp:test_support_ipc',
'../media/media.gyp:media_test_support',
'../net/net.gyp:net_test_support',
'../skia/skia.gyp:skia',
'../testing/gmock.gyp:gmock',
'../testing/gtest.gyp:gtest',
'../third_party/libjingle/libjingle.gyp:libjingle',
+ '../ui/gfx/gl/gl.gyp:gl',
'../ui/ui.gyp:ui',
],
'include_dirs': [
@@ -86,12 +90,21 @@
'browser/renderer_host/media/media_stream_dispatcher_host_unittest.cc',
'browser/renderer_host/media/video_capture_host_unittest.cc',
'browser/renderer_host/media/video_capture_manager_unittest.cc',
+ 'browser/renderer_host/resource_queue_unittest.cc',
+ 'browser/resolve_proxy_msg_helper_unittest.cc',
+ 'browser/speech/endpointer/endpointer_unittest.cc',
+ 'browser/speech/speech_recognition_request_unittest.cc',
+ 'browser/speech/speech_recognizer_unittest.cc',
'browser/ssl/ssl_host_state_unittest.cc',
'browser/trace_subscriber_stdio_unittest.cc',
+ 'common/gpu/gpu_feature_flags_unittest.cc',
+ 'common/gpu/gpu_info_unittest.cc',
+ 'common/notification_service_unittest.cc',
'common/process_watcher_unittest.cc',
'common/property_bag_unittest.cc',
'common/resource_dispatcher_unittest.cc',
'common/url_fetcher_unittest.cc',
+ 'gpu/gpu_info_collector_unittest.cc',
'renderer/active_notification_tracker_unittest.cc',
'renderer/media/audio_message_filter_unittest.cc',
'renderer/media/audio_renderer_impl_unittest.cc',