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

Unified Diff: ui/views/corewm/desktop_capture_controller_unittest.cc

Issue 190663012: Run ContentMain in a browser_test's browser process. This removes duplication of code in the browse… (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src/
Patch Set: try to fix android by restoring old path just for it Created 6 years, 9 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « content/test/content_test_suite.cc ('k') | ui/views/test/ui_controls_factory_desktop_aurax11.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: ui/views/corewm/desktop_capture_controller_unittest.cc
===================================================================
--- ui/views/corewm/desktop_capture_controller_unittest.cc (revision 257432)
+++ ui/views/corewm/desktop_capture_controller_unittest.cc (working copy)
@@ -5,11 +5,15 @@
#include "ui/wm/core/capture_controller.h"
#include "base/logging.h"
+#include "base/path_service.h"
#include "ui/aura/env.h"
#include "ui/aura/test/event_generator.h"
#include "ui/aura/test/test_window_delegate.h"
#include "ui/aura/window_event_dispatcher.h"
+#include "ui/base/resource/resource_bundle.h"
+#include "ui/base/ui_base_paths.h"
#include "ui/events/event.h"
+#include "ui/gl/gl_surface.h"
#include "ui/views/test/views_test_base.h"
#include "ui/views/view.h"
#include "ui/views/widget/desktop_aura/desktop_native_widget_aura.h"
@@ -22,8 +26,23 @@
namespace views {
-typedef ViewsTestBase DesktopCaptureControllerTest;
+class DesktopCaptureControllerTest : public ViewsTestBase {
+ public:
+ DesktopCaptureControllerTest() {}
+ virtual ~DesktopCaptureControllerTest() {}
+ virtual void SetUp() OVERRIDE {
+ gfx::GLSurface::InitializeOneOffForTests();
+ base::FilePath pak_dir;
+ PathService::Get(base::DIR_MODULE, &pak_dir);
+ base::FilePath pak_file;
+ pak_file = pak_dir.Append(FILE_PATH_LITERAL("ui_test.pak"));
+ ui::ResourceBundle::InitSharedInstanceWithPakPath(pak_file);
+
+ ViewsTestBase::SetUp();
+ }
+};
+
// This class provides functionality to verify whether the View instance
// received the gesture event.
class DesktopViewInputTest : public View {
« no previous file with comments | « content/test/content_test_suite.cc ('k') | ui/views/test/ui_controls_factory_desktop_aurax11.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698