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

Side by Side Diff: base/test/test_suite.cc

Issue 1233453011: Revert of Remove some legacy versions of StartsWith and EndsWith. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 5 years, 5 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
« no previous file with comments | « base/strings/string_util_unittest.cc ('k') | chrome/app/delay_load_hook_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) 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 "base/test/test_suite.h" 5 #include "base/test/test_suite.h"
6 6
7 #include "base/at_exit.h" 7 #include "base/at_exit.h"
8 #include "base/base_paths.h" 8 #include "base/base_paths.h"
9 #include "base/base_switches.h" 9 #include "base/base_switches.h"
10 #include "base/bind.h" 10 #include "base/bind.h"
(...skipping 320 matching lines...) Expand 10 before | Expand all | Expand 10 after
331 // Some tests (such as those involving word break iterator) will behave 331 // Some tests (such as those involving word break iterator) will behave
332 // differently and fail if we use *POSIX locale. Setting it to en_US here 332 // differently and fail if we use *POSIX locale. Setting it to en_US here
333 // does not affect tests that explicitly overrides the locale for testing. 333 // does not affect tests that explicitly overrides the locale for testing.
334 // This can be an issue on all platforms other than Windows. 334 // This can be an issue on all platforms other than Windows.
335 // TODO(jshin): Should we set the locale via an OS X locale API here? 335 // TODO(jshin): Should we set the locale via an OS X locale API here?
336 #if !defined(OS_WIN) 336 #if !defined(OS_WIN)
337 #if defined(OS_IOS) 337 #if defined(OS_IOS)
338 i18n::SetICUDefaultLocale("en_US"); 338 i18n::SetICUDefaultLocale("en_US");
339 #else 339 #else
340 std::string default_locale(uloc_getDefault()); 340 std::string default_locale(uloc_getDefault());
341 if (EndsWith(default_locale, "POSIX", CompareCase::INSENSITIVE_ASCII)) 341 if (EndsWith(default_locale, "POSIX", false))
342 i18n::SetICUDefaultLocale("en_US"); 342 i18n::SetICUDefaultLocale("en_US");
343 #endif 343 #endif
344 #endif 344 #endif
345 345
346 CatchMaybeTests(); 346 CatchMaybeTests();
347 ResetCommandLine(); 347 ResetCommandLine();
348 AddTestLauncherResultPrinter(); 348 AddTestLauncherResultPrinter();
349 349
350 TestTimeouts::Initialize(); 350 TestTimeouts::Initialize();
351 351
352 trace_to_file_.BeginTracingFromCommandLineOptions(); 352 trace_to_file_.BeginTracingFromCommandLineOptions();
353 } 353 }
354 354
355 void TestSuite::Shutdown() { 355 void TestSuite::Shutdown() {
356 } 356 }
357 357
358 } // namespace base 358 } // namespace base
OLDNEW
« no previous file with comments | « base/strings/string_util_unittest.cc ('k') | chrome/app/delay_load_hook_win.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698