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

Side by Side Diff: content/public/test/test_launcher.cc

Issue 1172183002: Move StartsWith[ASCII] to base namespace. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@string_util3
Patch Set: merger Created 5 years, 6 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 | « content/public/test/browser_test_utils.cc ('k') | content/renderer/savable_resources.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 "content/public/test/test_launcher.h" 5 #include "content/public/test/test_launcher.h"
6 6
7 #include <map> 7 #include <map>
8 #include <string> 8 #include <string>
9 #include <vector> 9 #include <vector>
10 10
(...skipping 164 matching lines...) Expand 10 before | Expand all | Expand 10 after
175 std::vector<base::SplitTestName>* output) { 175 std::vector<base::SplitTestName>* output) {
176 *output = base::GetCompiledInTests(); 176 *output = base::GetCompiledInTests();
177 return true; 177 return true;
178 } 178 }
179 179
180 bool WrapperTestLauncherDelegate::ShouldRunTest( 180 bool WrapperTestLauncherDelegate::ShouldRunTest(
181 const std::string& test_case_name, 181 const std::string& test_case_name,
182 const std::string& test_name) { 182 const std::string& test_name) {
183 all_test_names_.insert(test_case_name + "." + test_name); 183 all_test_names_.insert(test_case_name + "." + test_name);
184 184
185 if (StartsWithASCII(test_name, kManualTestPrefix, true) && 185 if (base::StartsWithASCII(test_name, kManualTestPrefix, true) &&
186 !base::CommandLine::ForCurrentProcess()->HasSwitch(kRunManualTestsFlag)) { 186 !base::CommandLine::ForCurrentProcess()->HasSwitch(kRunManualTestsFlag)) {
187 return false; 187 return false;
188 } 188 }
189 189
190 if (StartsWithASCII(test_name, kPreTestPrefix, true)) { 190 if (base::StartsWithASCII(test_name, kPreTestPrefix, true)) {
191 // We will actually run PRE_ tests, but to ensure they run on the same shard 191 // We will actually run PRE_ tests, but to ensure they run on the same shard
192 // as dependent tests, handle all these details internally. 192 // as dependent tests, handle all these details internally.
193 return false; 193 return false;
194 } 194 }
195 195
196 return true; 196 return true;
197 } 197 }
198 198
199 std::string GetPreTestName(const std::string& full_name) { 199 std::string GetPreTestName(const std::string& full_name) {
200 size_t dot_pos = full_name.find('.'); 200 size_t dot_pos = full_name.find('.');
(...skipping 305 matching lines...) Expand 10 before | Expand all | Expand 10 after
506 506
507 TestLauncherDelegate* GetCurrentTestLauncherDelegate() { 507 TestLauncherDelegate* GetCurrentTestLauncherDelegate() {
508 return g_launcher_delegate; 508 return g_launcher_delegate;
509 } 509 }
510 510
511 ContentMainParams* GetContentMainParams() { 511 ContentMainParams* GetContentMainParams() {
512 return g_params; 512 return g_params;
513 } 513 }
514 514
515 } // namespace content 515 } // namespace content
OLDNEW
« no previous file with comments | « content/public/test/browser_test_utils.cc ('k') | content/renderer/savable_resources.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698