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

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

Issue 11091058: Reland r161256: Fix the crash that was happening on the buildbot (but not trybots, for a strange re… (Closed) Base URL: svn://chrome-svn/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 | « content/test/DEPS ('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 "content/test/content_test_suite.h" 5 #include "content/test/content_test_suite.h"
6 6
7 #include "base/logging.h" 7 #include "base/logging.h"
8 #include "content/public/test/test_content_client_initializer.h" 8 #include "content/public/test/test_content_client_initializer.h"
9 #include "content/test/test_content_client.h" 9 #include "content/test/test_content_client.h"
10 #include "testing/gtest/include/gtest/gtest.h" 10 #include "testing/gtest/include/gtest/gtest.h"
11 #include "ui/base/resource/resource_bundle.h"
11 12
12 #if defined(USE_AURA) 13 #if defined(USE_AURA)
13 #include "ui/aura/test/test_aura_initializer.h" 14 #include "ui/aura/test/test_aura_initializer.h"
14 #endif 15 #endif
15 16
16 #if defined(OS_MACOSX) 17 #if defined(OS_MACOSX)
17 #include "base/mac/scoped_nsautorelease_pool.h" 18 #include "base/mac/scoped_nsautorelease_pool.h"
18 #endif 19 #endif
19 20
20 namespace { 21 namespace {
(...skipping 32 matching lines...) Expand 10 before | Expand all | Expand 10 after
53 ContentTestSuite::~ContentTestSuite() { 54 ContentTestSuite::~ContentTestSuite() {
54 } 55 }
55 56
56 void ContentTestSuite::Initialize() { 57 void ContentTestSuite::Initialize() {
57 #if defined(OS_MACOSX) 58 #if defined(OS_MACOSX)
58 base::mac::ScopedNSAutoreleasePool autorelease_pool; 59 base::mac::ScopedNSAutoreleasePool autorelease_pool;
59 #endif 60 #endif
60 61
61 ContentTestSuiteBase::Initialize(); 62 ContentTestSuiteBase::Initialize();
62 63
64 // Force unittests to run using en-US so if we test against string
65 // output, it'll pass regardless of the system language.
66 ResourceBundle::InitSharedInstanceWithLocale("en-US", NULL);
67
63 testing::TestEventListeners& listeners = 68 testing::TestEventListeners& listeners =
64 testing::UnitTest::GetInstance()->listeners(); 69 testing::UnitTest::GetInstance()->listeners();
65 listeners.Append(new TestInitializationListener); 70 listeners.Append(new TestInitializationListener);
66 } 71 }
67 72
68 ContentClient* ContentTestSuite::CreateClientForInitialization() { 73 ContentClient* ContentTestSuite::CreateClientForInitialization() {
69 return new TestContentClient(); 74 return new TestContentClient();
70 } 75 }
71 76
72 } // namespace content 77 } // namespace content
OLDNEW
« no previous file with comments | « content/test/DEPS ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698