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

Side by Side Diff: trunk/src/ui/keyboard/test/run_all_unittests.cc

Issue 149953003: Revert 247793 "Ensure GL initialization only happens once, and p..." (Closed) Base URL: svn://svn.chromium.org/chrome/
Patch Set: Created 6 years, 10 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 | « trunk/src/ui/keyboard/DEPS ('k') | trunk/src/ui/views/examples/DEPS » ('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 2014 The Chromium Authors. All rights reserved. 1 // Copyright 2014 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 "base/basictypes.h" 5 #include "base/basictypes.h"
6 #include "base/bind.h" 6 #include "base/bind.h"
7 #include "base/compiler_specific.h" 7 #include "base/compiler_specific.h"
8 #include "base/path_service.h" 8 #include "base/path_service.h"
9 #include "base/test/launcher/unit_test_launcher.h" 9 #include "base/test/launcher/unit_test_launcher.h"
10 #include "base/test/test_suite.h" 10 #include "base/test/test_suite.h"
11 #include "ui/base/resource/resource_bundle.h" 11 #include "ui/base/resource/resource_bundle.h"
12 #include "ui/base/ui_base_paths.h" 12 #include "ui/base/ui_base_paths.h"
13 #include "ui/gl/gl_surface.h"
14 13
15 namespace { 14 namespace {
16 15
17 class KeyboardTestSuite : public base::TestSuite { 16 class KeyboardTestSuite : public base::TestSuite {
18 public: 17 public:
19 KeyboardTestSuite(int argc, char** argv) : base::TestSuite(argc, argv) {} 18 KeyboardTestSuite(int argc, char** argv) : base::TestSuite(argc, argv) {}
20 19
21 protected: 20 protected:
22 virtual void Initialize() OVERRIDE { 21 virtual void Initialize() OVERRIDE {
23 base::TestSuite::Initialize(); 22 base::TestSuite::Initialize();
24 gfx::GLSurface::InitializeOneOffForTests();
25 ui::RegisterPathProvider(); 23 ui::RegisterPathProvider();
26 24
27 base::FilePath pak_dir; 25 base::FilePath pak_dir;
28 PathService::Get(base::DIR_MODULE, &pak_dir); 26 PathService::Get(base::DIR_MODULE, &pak_dir);
29 27
30 base::FilePath pak_file; 28 base::FilePath pak_file;
31 pak_file = pak_dir.Append(FILE_PATH_LITERAL("ui_test.pak")); 29 pak_file = pak_dir.Append(FILE_PATH_LITERAL("ui_test.pak"));
32 30
33 ui::ResourceBundle::InitSharedInstanceWithPakPath(pak_file); 31 ui::ResourceBundle::InitSharedInstanceWithPakPath(pak_file);
34 } 32 }
(...skipping 10 matching lines...) Expand all
45 } // namespace 43 } // namespace
46 44
47 int main(int argc, char** argv) { 45 int main(int argc, char** argv) {
48 KeyboardTestSuite test_suite(argc, argv); 46 KeyboardTestSuite test_suite(argc, argv);
49 47
50 return base::LaunchUnitTests( 48 return base::LaunchUnitTests(
51 argc, 49 argc,
52 argv, 50 argv,
53 base::Bind(&KeyboardTestSuite::Run, base::Unretained(&test_suite))); 51 base::Bind(&KeyboardTestSuite::Run, base::Unretained(&test_suite)));
54 } 52 }
OLDNEW
« no previous file with comments | « trunk/src/ui/keyboard/DEPS ('k') | trunk/src/ui/views/examples/DEPS » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698