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

Side by Side Diff: chrome/test/unit/chrome_test_suite.h

Issue 173418: Avoids the use of ToWStringHack in a few places.... (Closed) Base URL: http://src.chromium.org/svn/trunk/src/
Patch Set: '' Created 11 years, 4 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 | « chrome/test/selenium/selenium_test.cc ('k') | webkit/tools/test_shell/test_shell_win.cc » ('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 (c) 2006-2008 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2006-2008 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 #ifndef CHROME_TEST_UNIT_CHROME_TEST_SUITE_H_ 5 #ifndef CHROME_TEST_UNIT_CHROME_TEST_SUITE_H_
6 #define CHROME_TEST_UNIT_CHROME_TEST_SUITE_H_ 6 #define CHROME_TEST_UNIT_CHROME_TEST_SUITE_H_
7 7
8 #include "build/build_config.h" 8 #include "build/build_config.h"
9 9
10 #include <string> 10 #include <string>
(...skipping 75 matching lines...) Expand 10 before | Expand all | Expand 10 after
86 // uses it, in order to ensure consistency. 86 // uses it, in order to ensure consistency.
87 FilePath user_data_dir = FilePath::FromWStringHack( 87 FilePath user_data_dir = FilePath::FromWStringHack(
88 CommandLine::ForCurrentProcess()->GetSwitchValue( 88 CommandLine::ForCurrentProcess()->GetSwitchValue(
89 switches::kUserDataDir)); 89 switches::kUserDataDir));
90 if (user_data_dir.empty() && 90 if (user_data_dir.empty() &&
91 file_util::CreateNewTempDirectory(FILE_PATH_LITERAL("chrome_test_"), 91 file_util::CreateNewTempDirectory(FILE_PATH_LITERAL("chrome_test_"),
92 &user_data_dir)) { 92 &user_data_dir)) {
93 user_data_dir = user_data_dir.AppendASCII("test_user_data"); 93 user_data_dir = user_data_dir.AppendASCII("test_user_data");
94 } 94 }
95 if (!user_data_dir.empty()) 95 if (!user_data_dir.empty())
96 PathService::Override(chrome::DIR_USER_DATA, 96 PathService::Override(chrome::DIR_USER_DATA, user_data_dir);
97 user_data_dir.ToWStringHack());
98 97
99 #if defined(OS_MACOSX) 98 #if defined(OS_MACOSX)
100 FilePath path; 99 FilePath path;
101 PathService::Get(base::DIR_EXE, &path); 100 PathService::Get(base::DIR_EXE, &path);
102 path = path.AppendASCII(MAC_BROWSER_APP_NAME); 101 path = path.AppendASCII(MAC_BROWSER_APP_NAME);
103 mac_util::SetOverrideAppBundlePath(path); 102 mac_util::SetOverrideAppBundlePath(path);
104 #endif 103 #endif
105 104
106 // Force unittests to run using en-US so if we test against string 105 // Force unittests to run using en-US so if we test against string
107 // output, it'll pass regardless of the system language. 106 // output, it'll pass regardless of the system language.
(...skipping 32 matching lines...) Expand 10 before | Expand all | Expand 10 after
140 TestSuite::Shutdown(); 139 TestSuite::Shutdown();
141 } 140 }
142 141
143 StatsTable* stats_table_; 142 StatsTable* stats_table_;
144 ScopedOleInitializer ole_initializer_; 143 ScopedOleInitializer ole_initializer_;
145 scoped_refptr<WarningHostResolverProc> host_resolver_proc_; 144 scoped_refptr<WarningHostResolverProc> host_resolver_proc_;
146 net::ScopedDefaultHostResolverProc scoped_host_resolver_proc_; 145 net::ScopedDefaultHostResolverProc scoped_host_resolver_proc_;
147 }; 146 };
148 147
149 #endif // CHROME_TEST_UNIT_CHROME_TEST_SUITE_H_ 148 #endif // CHROME_TEST_UNIT_CHROME_TEST_SUITE_H_
OLDNEW
« no previous file with comments | « chrome/test/selenium/selenium_test.cc ('k') | webkit/tools/test_shell/test_shell_win.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698