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

Side by Side Diff: ui/app_list/test/app_list_test_suite.cc

Issue 10963040: app_list: Fix app_list_unittests crash. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 8 years, 2 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 | « ui/app_list/apps_grid_view.cc ('k') | no next file » | 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 "ui/app_list/test/app_list_test_suite.h" 5 #include "ui/app_list/test/app_list_test_suite.h"
6 6
7 #include "ui/base/ui_base_paths.h" 7 #include "ui/base/ui_base_paths.h"
8 #include "ui/base/resource/resource_bundle.h" 8 #include "ui/base/resource/resource_bundle.h"
9 #include "ui/compositor/compositor_setup.h"
10 #include "ui/compositor/test/compositor_test_support.h"
9 11
10 namespace app_list { 12 namespace app_list {
11 namespace test { 13 namespace test {
12 14
13 AppListTestSuite::AppListTestSuite(int argc, char** argv) 15 AppListTestSuite::AppListTestSuite(int argc, char** argv)
14 : base::TestSuite(argc, argv) { 16 : base::TestSuite(argc, argv) {
15 } 17 }
16 18
17 void AppListTestSuite::Initialize() { 19 void AppListTestSuite::Initialize() {
18 base::TestSuite::Initialize(); 20 base::TestSuite::Initialize();
19 21
20 ui::RegisterPathProvider(); 22 ui::RegisterPathProvider();
21 23
22 // Force unittests to run using en-US so if we test against string 24 // Force unittests to run using en-US so if we test against string
23 // output, it'll pass regardless of the system language. 25 // output, it'll pass regardless of the system language.
24 ui::ResourceBundle::InitSharedInstanceWithLocale("en-US", NULL); 26 ui::ResourceBundle::InitSharedInstanceWithLocale("en-US", NULL);
27
28 ui::CompositorTestSupport::Initialize();
29 ui::SetupTestCompositor();
25 } 30 }
26 31
27 void AppListTestSuite::Shutdown() { 32 void AppListTestSuite::Shutdown() {
33 ui::CompositorTestSupport::Terminate();
28 ui::ResourceBundle::CleanupSharedInstance(); 34 ui::ResourceBundle::CleanupSharedInstance();
29 35
30 base::TestSuite::Shutdown(); 36 base::TestSuite::Shutdown();
31 } 37 }
32 38
33 } // namespace test 39 } // namespace test
34 } // namespace app_list 40 } // namespace app_list
OLDNEW
« no previous file with comments | « ui/app_list/apps_grid_view.cc ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698