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

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

Issue 16295003: Update chrome/ to use scoped_refptr<T>::get() rather than implicit "operator T*" (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Rebased Created 7 years, 7 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 b1db4b14769e4bfa82a5e04b1a4f1a06c768e448..7900271e34313c000603be59a08861075bdbcf7c 100644
--- a/chrome/browser/autocomplete/search_provider_unittest.cc
+++ b/chrome/browser/autocomplete/search_provider_unittest.cc
@@ -1929,7 +1929,7 @@ TEST_F(SearchProviderTest, NavigationInline) {
for (size_t i = 0; i < ARRAYSIZE_UNSAFE(cases); i++) {
QueryForInput(ASCIIToUTF16(cases[i].input), false, false);
SearchProvider::NavigationResult result(
- *provider_, GURL(cases[i].url), string16(), false, 0);
+ *provider_.get(), GURL(cases[i].url), string16(), false, 0);
AutocompleteMatch match(provider_->NavigationToMatch(result));
EXPECT_EQ(cases[i].inline_offset, match.inline_autocomplete_offset);
EXPECT_EQ(ASCIIToUTF16(cases[i].fill_into_edit), match.fill_into_edit);
@@ -1941,7 +1941,7 @@ TEST_F(SearchProviderTest, NavigationInlineSchemeSubstring) {
const string16 input(ASCIIToUTF16("ht"));
const string16 url(ASCIIToUTF16("http://a.com"));
const SearchProvider::NavigationResult result(
- *provider_, GURL(url), string16(), false, 0);
+ *provider_.get(), GURL(url), string16(), false, 0);
// Check the offset and strings when inline autocompletion is allowed.
QueryForInput(input, false, false);
@@ -1963,7 +1963,7 @@ TEST_F(SearchProviderTest, NavigationInlineDomainClassify) {
QueryForInput(ASCIIToUTF16("w"), false, false);
const GURL url("http://www.wow.com");
const SearchProvider::NavigationResult result(
- *provider_, url, string16(), false, 0);
+ *provider_.get(), url, string16(), false, 0);
AutocompleteMatch match(provider_->NavigationToMatch(result));
EXPECT_EQ(5U, match.inline_autocomplete_offset);
EXPECT_EQ(ASCIIToUTF16("www.wow.com"), match.fill_into_edit);
@@ -2124,9 +2124,11 @@ TEST_F(SearchProviderTest, RemoveStaleResultsTest) {
break;
if (cases[i].results[j].is_navigation_result) {
provider_->default_results_.navigation_results.push_back(
- SearchProvider::NavigationResult(
- *provider_, GURL(suggestion), string16(),
- false, cases[i].results[j].relevance));
+ SearchProvider::NavigationResult(*provider_.get(),
+ GURL(suggestion),
+ string16(),
+ false,
+ cases[i].results[j].relevance));
} else {
provider_->default_results_.suggest_results.push_back(
SearchProvider::SuggestResult(ASCIIToUTF16(suggestion), false,
« no previous file with comments | « chrome/browser/autocomplete/bookmark_provider_unittest.cc ('k') | chrome/browser/autocomplete/shortcuts_provider.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698