summaryrefslogtreecommitdiffstats
path: root/chrome/installer/util
diff options
context:
space:
mode:
authorhuanr@chromium.org <huanr@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2010-03-19 18:58:37 +0000
committerhuanr@chromium.org <huanr@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2010-03-19 18:58:37 +0000
commite47ce49d31a0c712b0e64ed73bb3a74364fd51f6 (patch)
treeca646cb17851aa110deb53e8130931712dc406d8 /chrome/installer/util
parentdc2834f3867f0536a851b37adcc556e1bc35ccd8 (diff)
downloadchromium_src-e47ce49d31a0c712b0e64ed73bb3a74364fd51f6.zip
chromium_src-e47ce49d31a0c712b0e64ed73bb3a74364fd51f6.tar.gz
chromium_src-e47ce49d31a0c712b0e64ed73bb3a74364fd51f6.tar.bz2
Removing AddDefaultBookmark related code as we are taking
bookmark import approach. BUG=32728 TEST=existing test passes Review URL: http://codereview.chromium.org/1122002 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@42130 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'chrome/installer/util')
-rw-r--r--chrome/installer/util/master_preferences.cc4
-rw-r--r--chrome/installer/util/master_preferences.h16
-rw-r--r--chrome/installer/util/master_preferences_unittest.cc24
3 files changed, 0 insertions, 44 deletions
diff --git a/chrome/installer/util/master_preferences.cc b/chrome/installer/util/master_preferences.cc
index 0ac4e63..3cebf4b 100644
--- a/chrome/installer/util/master_preferences.cc
+++ b/chrome/installer/util/master_preferences.cc
@@ -129,10 +129,6 @@ std::vector<GURL> GetFirstRunTabs(const DictionaryValue* prefs) {
return GetNamedList(L"first_run_tabs", prefs);
}
-std::vector<GURL> GetDefaultBookmarks(const DictionaryValue* prefs) {
- return GetNamedList(L"default_bookmarks", prefs);
-}
-
bool SetDistroBooleanPreference(DictionaryValue* prefs,
const std::wstring& name,
bool value) {
diff --git a/chrome/installer/util/master_preferences.h b/chrome/installer/util/master_preferences.h
index 178587f..a6da339 100644
--- a/chrome/installer/util/master_preferences.h
+++ b/chrome/installer/util/master_preferences.h
@@ -147,22 +147,6 @@ DictionaryValue* ParseDistributionPreferences(
// preferences file does not contain such list the vector is empty.
std::vector<GURL> GetFirstRunTabs(const DictionaryValue* prefs);
-// As part of the master preferences an optional section indicates the
-// pre-installed bookmarks. An example is the following:
-//
-// {
-// "default_bookmarks": [
-// "http://google.com/b1",
-// "https://google.com/b2"
-// ]
-// }
-//
-// Note that the entries need to be urls.
-//
-// This function retuns the list as a vector of GURLs. If the master
-// preferences file does not contain such list the vector is empty.
-std::vector<GURL> GetDefaultBookmarks(const DictionaryValue* prefs);
-
// Sets the value of given boolean preference |name| in "distribution"
// dictionary inside |prefs| dictionary.
bool SetDistroBooleanPreference(DictionaryValue* prefs,
diff --git a/chrome/installer/util/master_preferences_unittest.cc b/chrome/installer/util/master_preferences_unittest.cc
index 17ea387..3b7550a 100644
--- a/chrome/installer/util/master_preferences_unittest.cc
+++ b/chrome/installer/util/master_preferences_unittest.cc
@@ -209,30 +209,6 @@ TEST_F(MasterPreferencesTest, FirstRunTabs) {
EXPECT_EQ(GURL("new_tab_page"), tabs[2]);
}
-TEST_F(MasterPreferencesTest, FirstRunBookMarks) {
- const char text[] =
- "{ \n"
- " \"distribution\": { \n"
- " \"something here\": true\n"
- " },\n"
- " \"default_bookmarks\": [\n"
- " \"http://google.com/b1\",\n"
- " \"https://google.com/b2\"\n"
- " ]\n"
- "} \n";
-
- EXPECT_TRUE(file_util::WriteFile(prefs_file(), text, sizeof(text)));
- scoped_ptr<DictionaryValue> prefs(
- installer_util::ParseDistributionPreferences(prefs_file()));
- EXPECT_TRUE(prefs.get() != NULL);
-
- typedef std::vector<GURL> BookmarksVector;
- BookmarksVector bookmarks = installer_util::GetDefaultBookmarks(prefs.get());
- ASSERT_EQ(2, bookmarks.size());
- EXPECT_EQ(GURL("http://google.com/b1"), bookmarks[0]);
- EXPECT_EQ(GURL("https://google.com/b2"), bookmarks[1]);
-}
-
// In this test instead of using our synthetic json file, we use an
// actual test case from the extensions unittest. The hope here is that if
// they change something in the manifest this test will break, but in