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

Unified Diff: chrome/browser/search_engines/template_url_service_sync_unittest.cc

Issue 2816383002: Remove non-const version of GetDefaultSearchProvider() and make all callers call the const version (Closed)
Patch Set: Fix unit test (the model was already loaded) Created 3 years, 8 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 side-by-side diff with in-line comments
Download patch
Index: chrome/browser/search_engines/template_url_service_sync_unittest.cc
diff --git a/chrome/browser/search_engines/template_url_service_sync_unittest.cc b/chrome/browser/search_engines/template_url_service_sync_unittest.cc
index 93d5dbe397c4577e4a7c24dc873d22408b32acdd..cfa969130017cbf483c499c7d3128a80204d5d1e 100644
--- a/chrome/browser/search_engines/template_url_service_sync_unittest.cc
+++ b/chrome/browser/search_engines/template_url_service_sync_unittest.cc
@@ -2423,11 +2423,11 @@ TEST_F(TemplateURLServiceSyncTest, MergeConflictingPrepopulatedEngine) {
syncer::SEARCH_ENGINES, list, PassProcessor(),
CreateAndPassSyncErrorFactory());
- result_turl = model()->GetDefaultSearchProvider();
- EXPECT_TRUE(result_turl);
- EXPECT_EQ(ASCIIToUTF16("new_kw"), result_turl->keyword());
- EXPECT_EQ(ASCIIToUTF16("my name"), result_turl->short_name());
- EXPECT_EQ(default_turl->url(), result_turl->url());
+ const TemplateURL* final_turl = model()->GetDefaultSearchProvider();
+ EXPECT_TRUE(final_turl);
+ EXPECT_EQ(ASCIIToUTF16("new_kw"), final_turl->keyword());
+ EXPECT_EQ(ASCIIToUTF16("my name"), final_turl->short_name());
+ EXPECT_EQ(default_turl->url(), final_turl->url());
}
TEST_F(TemplateURLServiceSyncTest, MergeNonEditedPrepopulatedEngine) {

Powered by Google App Engine
This is Rietveld 408576698