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

Side by Side Diff: chrome/browser/sync/test/integration/search_engines_helper.cc

Issue 120983002: Update some uses of UTF conversions in chrome/browser to use the base:: namespace. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 6 years, 12 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
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 "chrome/browser/sync/test/integration/search_engines_helper.h" 5 #include "chrome/browser/sync/test/integration/search_engines_helper.h"
6 6
7 #include <vector> 7 #include <vector>
8 8
9 #include "base/strings/string_util.h" 9 #include "base/strings/string_util.h"
10 #include "base/strings/stringprintf.h" 10 #include "base/strings/stringprintf.h"
(...skipping 90 matching lines...) Expand 10 before | Expand all | Expand 10 after
101 LOG(INFO) << "A had default with URL: " << default_a->url() 101 LOG(INFO) << "A had default with URL: " << default_a->url()
102 << " and keyword: " << default_a->keyword(); 102 << " and keyword: " << default_a->keyword();
103 } 103 }
104 104
105 return true; 105 return true;
106 } 106 }
107 107
108 // Convenience helper for consistently generating the same keyword for a given 108 // Convenience helper for consistently generating the same keyword for a given
109 // seed. 109 // seed.
110 base::string16 CreateKeyword(int seed) { 110 base::string16 CreateKeyword(int seed) {
111 return ASCIIToUTF16(base::StringPrintf("test%d", seed)); 111 return base::ASCIIToUTF16(base::StringPrintf("test%d", seed));
112 } 112 }
113 113
114 } // namespace 114 } // namespace
115 115
116 namespace search_engines_helper { 116 namespace search_engines_helper {
117 117
118 TemplateURLService* GetServiceForBrowserContext(int profile_index) { 118 TemplateURLService* GetServiceForBrowserContext(int profile_index) {
119 return TemplateURLServiceFactory::GetForProfile( 119 return TemplateURLServiceFactory::GetForProfile(
120 test()->GetProfile(profile_index)); 120 test()->GetProfile(profile_index));
121 } 121 }
(...skipping 136 matching lines...) Expand 10 before | Expand all | Expand 10 after
258 service->SetDefaultSearchProvider(turl); 258 service->SetDefaultSearchProvider(turl);
259 if (test()->use_verifier()) { 259 if (test()->use_verifier()) {
260 TemplateURL* verifier_turl = 260 TemplateURL* verifier_turl =
261 GetVerifierService()->GetTemplateURLForKeyword(CreateKeyword(seed)); 261 GetVerifierService()->GetTemplateURLForKeyword(CreateKeyword(seed));
262 ASSERT_TRUE(verifier_turl); 262 ASSERT_TRUE(verifier_turl);
263 GetVerifierService()->SetDefaultSearchProvider(verifier_turl); 263 GetVerifierService()->SetDefaultSearchProvider(verifier_turl);
264 } 264 }
265 } 265 }
266 266
267 } // namespace search_engines_helper 267 } // namespace search_engines_helper
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698