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

Unified Diff: chrome/browser/search/search_unittest.cc

Issue 22945004: InstantExtended: Add new_tab_url to TemplateURL. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 7 years, 4 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/search/search_unittest.cc
diff --git a/chrome/browser/search/search_unittest.cc b/chrome/browser/search/search_unittest.cc
index b2ba58f67ac1c46d3d4612cd062011adce3a21d7..1efa44a93720fdba360c48d2caa2da9e9111440a 100644
--- a/chrome/browser/search/search_unittest.cc
+++ b/chrome/browser/search/search_unittest.cc
@@ -245,6 +245,7 @@ class SearchTest : public BrowserWithTestWindowTest {
data.SetURL("http://foo.com/url?bar={searchTerms}");
data.instant_url = "http://foo.com/instant?"
"{google:omniboxStartMarginParameter}foo=foo#foo=foo&strk";
+ data.new_tab_url = "http://foo.com/newtab?strk";
Anuj 2013/08/13 22:54:33 Should this change for all tests testing NTP? (We
Jered 2013/08/14 15:41:49 Not right now (emailed response).
data.alternate_urls.push_back("http://foo.com/alt#quux={searchTerms}");
data.search_terms_replacement_key = "strk";
@@ -666,14 +667,14 @@ TEST_F(SearchTest, ShouldShowInstantNTP_Default) {
TEST_F(SearchTest, ShouldShowInstantNTP_DisabledViaFinch) {
EnableInstantExtendedAPIForTesting();
ASSERT_TRUE(base::FieldTrialList::CreateFieldTrial("InstantExtended",
- "Group1 show_ntp:0"));
+ "Group1 show_ntp:0"));
EXPECT_FALSE(ShouldShowInstantNTP());
}
-TEST_F(SearchTest, ShouldShowInstantNTP_DisabledByInstantNewTabURLSwitch) {
+TEST_F(SearchTest, ShouldShowInstantNTP_DisabledByUseCacheableNTPFinchFlag) {
EnableInstantExtendedAPIForTesting();
- CommandLine::ForCurrentProcess()->AppendSwitchASCII(
- switches::kInstantNewTabURL, "http://example.com/newtab");
+ ASSERT_TRUE(base::FieldTrialList::CreateFieldTrial("InstantExtended",
+ "Group1 use_cacheable_ntp:1"));
EXPECT_FALSE(ShouldShowInstantNTP());
}

Powered by Google App Engine
This is Rietveld 408576698