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

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

Issue 372843005: Remove Profile from BaseSearchProvider::NavigationResult (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 6 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 side-by-side diff with in-line comments
Download patch
Index: chrome/browser/autocomplete/search_provider_unittest.cc
diff --git a/chrome/browser/autocomplete/search_provider_unittest.cc b/chrome/browser/autocomplete/search_provider_unittest.cc
index ac4e190924e380d9cd0508339a068091f5d33db0..46756db03f17c535a38733973948742ce5aa28dc 100644
--- a/chrome/browser/autocomplete/search_provider_unittest.cc
+++ b/chrome/browser/autocomplete/search_provider_unittest.cc
@@ -2359,7 +2359,7 @@ TEST_F(SearchProviderTest, NavigationInline) {
QueryForInput(ASCIIToUTF16(cases[i].input), false, false);
AutocompleteMatch match(
provider_->NavigationToMatch(SearchProvider::NavigationResult(
- *provider_.get(), &profile_, GURL(cases[i].url),
+ ChromeAutocompleteSchemeClassifier(&profile_), GURL(cases[i].url),
AutocompleteMatchType::NAVSUGGEST, base::string16(), std::string(),
false, 0, false, ASCIIToUTF16(cases[i].input), std::string())));
EXPECT_EQ(ASCIIToUTF16(cases[i].inline_autocompletion),
@@ -2372,7 +2372,7 @@ TEST_F(SearchProviderTest, NavigationInline) {
QueryForInput(ASCIIToUTF16(cases[i].input), true, false);
AutocompleteMatch match_prevent_inline(
provider_->NavigationToMatch(SearchProvider::NavigationResult(
- *provider_.get(), &profile_, GURL(cases[i].url),
+ ChromeAutocompleteSchemeClassifier(&profile_), GURL(cases[i].url),
AutocompleteMatchType::NAVSUGGEST, base::string16(), std::string(),
false, 0, false, ASCIIToUTF16(cases[i].input), std::string())));
EXPECT_EQ(ASCIIToUTF16(cases[i].inline_autocompletion),
@@ -2389,7 +2389,8 @@ TEST_F(SearchProviderTest, NavigationInlineSchemeSubstring) {
const base::string16 input(ASCIIToUTF16("ht"));
const base::string16 url(ASCIIToUTF16("http://a.com"));
const SearchProvider::NavigationResult result(
- *provider_.get(), &profile_, GURL(url), AutocompleteMatchType::NAVSUGGEST,
+ ChromeAutocompleteSchemeClassifier(&profile_), GURL(url),
+ AutocompleteMatchType::NAVSUGGEST,
base::string16(), std::string(), false, 0, false, input, std::string());
// Check the offset and strings when inline autocompletion is allowed.
@@ -2413,7 +2414,8 @@ TEST_F(SearchProviderTest, NavigationInlineDomainClassify) {
QueryForInput(ASCIIToUTF16("w"), false, false);
AutocompleteMatch match(
provider_->NavigationToMatch(SearchProvider::NavigationResult(
- *provider_.get(), &profile_, GURL("http://www.wow.com"),
+ ChromeAutocompleteSchemeClassifier(&profile_),
+ GURL("http://www.wow.com"),
AutocompleteMatchType::NAVSUGGEST, base::string16(), std::string(),
false, 0, false, ASCIIToUTF16("w"), std::string())));
EXPECT_EQ(ASCIIToUTF16("ow.com"), match.inline_autocompletion);
« no previous file with comments | « chrome/browser/autocomplete/base_search_provider.cc ('k') | chrome/browser/autocomplete/zero_suggest_provider.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698