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

Unified Diff: chrome/browser/profile_resetter/profile_resetter_unittest.cc

Issue 465393002: Add show_home_button value to reset feedback reports (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 6 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
« no previous file with comments | « chrome/app/generated_resources.grd ('k') | chrome/browser/profile_resetter/resettable_settings_snapshot.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/browser/profile_resetter/profile_resetter_unittest.cc
diff --git a/chrome/browser/profile_resetter/profile_resetter_unittest.cc b/chrome/browser/profile_resetter/profile_resetter_unittest.cc
index 9db4dd6406424c0fda22620d19dc3c74ce40260a..e2e46ca36051b3f1d7854f38a3cce65505d5f72f 100644
--- a/chrome/browser/profile_resetter/profile_resetter_unittest.cc
+++ b/chrome/browser/profile_resetter/profile_resetter_unittest.cc
@@ -902,6 +902,7 @@ TEST_F(ProfileResetterTest, CheckSnapshots) {
empty_snap.startup_type());
EXPECT_TRUE(empty_snap.homepage().empty());
EXPECT_TRUE(empty_snap.homepage_is_ntp());
+ EXPECT_FALSE(empty_snap.show_home_button());
EXPECT_NE(std::string::npos, empty_snap.dse_url().find("{google:baseURL}"));
EXPECT_EQ(ResettableSettingsSnapshot::ExtensionList(),
empty_snap.enabled_extensions());
@@ -926,6 +927,7 @@ TEST_F(ProfileResetterTest, CheckSnapshots) {
EXPECT_EQ(SessionStartupPref::URLS, nonorganic_snap.startup_type());
EXPECT_EQ("http://www.foo.com", nonorganic_snap.homepage());
EXPECT_FALSE(nonorganic_snap.homepage_is_ntp());
+ EXPECT_TRUE(nonorganic_snap.show_home_button());
EXPECT_EQ("http://www.foo.com/s?q={searchTerms}", nonorganic_snap.dse_url());
EXPECT_EQ(ResettableSettingsSnapshot::ExtensionList(
1, std::make_pair(ext_id, "example")),
@@ -982,6 +984,7 @@ TEST_F(ProfileResetterTest, FeedbackSerializationTest) {
int startup_type = 0;
std::string homepage;
bool homepage_is_ntp = true;
+ bool show_home_button = true;
std::string default_search_engine;
base::ListValue* extensions = NULL;
base::ListValue* shortcuts = NULL;
@@ -994,6 +997,8 @@ TEST_F(ProfileResetterTest, FeedbackSerializationTest) {
dict->GetString("homepage", &homepage));
EXPECT_EQ(!!(field_mask & ResettableSettingsSnapshot::HOMEPAGE),
dict->GetBoolean("homepage_is_ntp", &homepage_is_ntp));
+ EXPECT_EQ(!!(field_mask & ResettableSettingsSnapshot::HOMEPAGE),
+ dict->GetBoolean("show_home_button", &show_home_button));
EXPECT_EQ(!!(field_mask & ResettableSettingsSnapshot::DSE_URL),
dict->GetString("default_search_engine", &default_search_engine));
EXPECT_EQ(!!(field_mask & ResettableSettingsSnapshot::EXTENSIONS),
« no previous file with comments | « chrome/app/generated_resources.grd ('k') | chrome/browser/profile_resetter/resettable_settings_snapshot.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698