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

Unified Diff: chrome/browser/autocomplete/autocomplete_provider_unittest.cc

Issue 363893002: Revert of Reduces dependency from AutocompleteMatch to Profile. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 6 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 side-by-side diff with in-line comments
Download patch
Index: chrome/browser/autocomplete/autocomplete_provider_unittest.cc
diff --git a/chrome/browser/autocomplete/autocomplete_provider_unittest.cc b/chrome/browser/autocomplete/autocomplete_provider_unittest.cc
index fde091c6b9d49766d11f9ab8c098c9f9f7564e02..504b1b399933406ce80f84daef7e2d3fb171e347 100644
--- a/chrome/browser/autocomplete/autocomplete_provider_unittest.cc
+++ b/chrome/browser/autocomplete/autocomplete_provider_unittest.cc
@@ -143,9 +143,7 @@
new TemplateURLRef::SearchTermsArgs(search_terms_args));
if (!match_keyword_.empty()) {
match.keyword = match_keyword_;
- TemplateURLService* service =
- TemplateURLServiceFactory::GetForProfile(profile_);
- ASSERT_TRUE(match.GetTemplateURL(service, false) != NULL);
+ ASSERT_TRUE(match.GetTemplateURL(profile_, false) != NULL);
}
matches_.push_back(match);
@@ -270,8 +268,7 @@
providers.push_back(provider2);
// Reset the controller to contain our new providers.
- controller_.reset(new AutocompleteController(
- &profile_, TemplateURLServiceFactory::GetForProfile(&profile_), NULL, 0));
+ controller_.reset(new AutocompleteController(&profile_, NULL, 0));
// We're going to swap the providers vector, but the old vector should be
// empty so no elements need to be freed at this point.
EXPECT_TRUE(controller_->providers_.empty());
@@ -317,7 +314,7 @@
ASSERT_NE(0, keyword_t_url->id());
controller_.reset(new AutocompleteController(
- &profile_, TemplateURLServiceFactory::GetForProfile(&profile_), NULL,
+ &profile_, NULL,
AutocompleteProvider::TYPE_KEYWORD | AutocompleteProvider::TYPE_SEARCH));
}
@@ -346,8 +343,7 @@
ASSERT_NE(0, keyword_t_url->id());
controller_.reset(new AutocompleteController(
- &profile_, TemplateURLServiceFactory::GetForProfile(&profile_), NULL,
- AutocompleteProvider::TYPE_KEYWORD));
+ &profile_, NULL, AutocompleteProvider::TYPE_KEYWORD));
}
void AutocompleteProviderTest::RunTest() {
« no previous file with comments | « chrome/browser/autocomplete/autocomplete_match.cc ('k') | chrome/browser/autocomplete/autocomplete_result.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698