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

Side by Side Diff: chrome/browser/autocomplete/search_provider_unittest.cc

Issue 113403006: Update some uses of char16 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 2012 The Chromium Authors. All rights reserved. 1 // Copyright 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/autocomplete/search_provider.h" 5 #include "chrome/browser/autocomplete/search_provider.h"
6 6
7 #include <string> 7 #include <string>
8 8
9 #include "base/command_line.h" 9 #include "base/command_line.h"
10 #include "base/metrics/field_trial.h" 10 #include "base/metrics/field_trial.h"
(...skipping 548 matching lines...) Expand 10 before | Expand all | Expand 10 after
559 559
560 // The SearchProvider is done. Make sure it has a result for the history 560 // The SearchProvider is done. Make sure it has a result for the history
561 // term keyword. 561 // term keyword.
562 AutocompleteMatch match; 562 AutocompleteMatch match;
563 EXPECT_TRUE(FindMatchWithDestination(keyword_url_, &match)); 563 EXPECT_TRUE(FindMatchWithDestination(keyword_url_, &match));
564 564
565 // The match should have an associated keyword. 565 // The match should have an associated keyword.
566 EXPECT_FALSE(match.keyword.empty()); 566 EXPECT_FALSE(match.keyword.empty());
567 567
568 // The fill into edit should contain the keyword. 568 // The fill into edit should contain the keyword.
569 EXPECT_EQ(keyword_t_url_->keyword() + char16(' ') + keyword_term_, 569 EXPECT_EQ(keyword_t_url_->keyword() + base::char16(' ') + keyword_term_,
570 match.fill_into_edit); 570 match.fill_into_edit);
571 } 571 }
572 572
573 TEST_F(SearchProviderTest, DontSendPrivateDataToSuggest) { 573 TEST_F(SearchProviderTest, DontSendPrivateDataToSuggest) {
574 // None of the following input strings should be sent to the suggest server, 574 // None of the following input strings should be sent to the suggest server,
575 // because they may contain private data. 575 // because they may contain private data.
576 const char* inputs[] = { 576 const char* inputs[] = {
577 "username:password", 577 "username:password",
578 "http://username:password", 578 "http://username:password",
579 "https://username:password", 579 "https://username:password",
(...skipping 3450 matching lines...) Expand 10 before | Expand all | Expand 10 after
4030 EXPECT_FALSE(provider_->deletion_handlers_.empty()); 4030 EXPECT_FALSE(provider_->deletion_handlers_.empty());
4031 // Set up a default fetcher with provided results. 4031 // Set up a default fetcher with provided results.
4032 fetcher = test_factory_.GetFetcherByID( 4032 fetcher = test_factory_.GetFetcherByID(
4033 SearchProvider::kDeletionURLFetcherID); 4033 SearchProvider::kDeletionURLFetcherID);
4034 ASSERT_TRUE(fetcher); 4034 ASSERT_TRUE(fetcher);
4035 fetcher->set_response_code(500); 4035 fetcher->set_response_code(500);
4036 fetcher->delegate()->OnURLFetchComplete(fetcher); 4036 fetcher->delegate()->OnURLFetchComplete(fetcher);
4037 EXPECT_TRUE(provider_->deletion_handlers_.empty()); 4037 EXPECT_TRUE(provider_->deletion_handlers_.empty());
4038 EXPECT_FALSE(provider_->is_success()); 4038 EXPECT_FALSE(provider_->is_success());
4039 } 4039 }
OLDNEW
« no previous file with comments | « chrome/browser/autocomplete/search_provider.cc ('k') | chrome/browser/autocomplete/shortcuts_provider.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698