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

Side by Side Diff: chrome/browser/search/instant_unittest_base.cc

Issue 73613002: InstantExtended: remove old flags, add new flag for query extraction. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Fix typo Created 7 years, 1 month 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
« no previous file with comments | « chrome/browser/policy/policy_browsertest.cc ('k') | chrome/browser/search/search.h » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright 2013 The Chromium Authors. All rights reserved. 1 // Copyright 2013 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/search/instant_unittest_base.h" 5 #include "chrome/browser/search/instant_unittest_base.h"
6 #include <string> 6 #include <string>
7 7
8 #include "base/basictypes.h" 8 #include "base/basictypes.h"
9 #include "chrome/browser/chrome_notification_types.h" 9 #include "chrome/browser/chrome_notification_types.h"
10 #include "chrome/browser/google/google_url_tracker.h" 10 #include "chrome/browser/google/google_url_tracker.h"
(...skipping 26 matching lines...) Expand all
37 SetUpHelper(); 37 SetUpHelper();
38 } 38 }
39 39
40 void InstantUnitTestBase::SetUpWithoutCacheableNTP() { 40 void InstantUnitTestBase::SetUpWithoutCacheableNTP() {
41 ASSERT_TRUE(base::FieldTrialList::CreateFieldTrial( 41 ASSERT_TRUE(base::FieldTrialList::CreateFieldTrial(
42 "InstantExtended", "Group1 use_cacheable_ntp:0")); 42 "InstantExtended", "Group1 use_cacheable_ntp:0"));
43 SetUpHelper(); 43 SetUpHelper();
44 } 44 }
45 45
46 void InstantUnitTestBase::SetUpHelper() { 46 void InstantUnitTestBase::SetUpHelper() {
47 chrome::EnableInstantExtendedAPIForTesting(); 47 chrome::EnableQueryExtractionForTesting();
48 BrowserWithTestWindowTest::SetUp(); 48 BrowserWithTestWindowTest::SetUp();
49 49
50 TemplateURLServiceFactory::GetInstance()->SetTestingFactoryAndUse( 50 TemplateURLServiceFactory::GetInstance()->SetTestingFactoryAndUse(
51 profile(), &TemplateURLServiceFactory::BuildInstanceFor); 51 profile(), &TemplateURLServiceFactory::BuildInstanceFor);
52 template_url_service_ = TemplateURLServiceFactory::GetForProfile(profile()); 52 template_url_service_ = TemplateURLServiceFactory::GetForProfile(profile());
53 ui_test_utils::WaitForTemplateURLServiceToLoad(template_url_service_); 53 ui_test_utils::WaitForTemplateURLServiceToLoad(template_url_service_);
54 54
55 UIThreadSearchTermsData::SetGoogleBaseURL("https://www.google.com/"); 55 UIThreadSearchTermsData::SetGoogleBaseURL("https://www.google.com/");
56 TestingPrefServiceSyncable* pref_service = profile()->GetTestingPrefService(); 56 TestingPrefServiceSyncable* pref_service = profile()->GetTestingPrefService();
57 pref_service->SetUserPref(prefs::kLastPromptedGoogleURL, 57 pref_service->SetUserPref(prefs::kLastPromptedGoogleURL,
(...skipping 38 matching lines...) Expand 10 before | Expand all | Expand 10 after
96 content::Source<Profile>(profile()->GetOriginalProfile()), 96 content::Source<Profile>(profile()->GetOriginalProfile()),
97 content::Details<GoogleURLTracker::UpdatedDetails>(&details)); 97 content::Details<GoogleURLTracker::UpdatedDetails>(&details));
98 } 98 }
99 99
100 100
101 bool InstantUnitTestBase::IsInstantServiceObserver( 101 bool InstantUnitTestBase::IsInstantServiceObserver(
102 InstantServiceObserver* observer) { 102 InstantServiceObserver* observer) {
103 return instant_service_->observers_.HasObserver(observer); 103 return instant_service_->observers_.HasObserver(observer);
104 } 104 }
105 105
OLDNEW
« no previous file with comments | « chrome/browser/policy/policy_browsertest.cc ('k') | chrome/browser/search/search.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698