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

Unified Diff: chrome/installer/util/master_preferences_unittest.cc

Issue 164537: Renames the function CreateTemporaryFilename to CreateTemporaryFile and track... (Closed) Base URL: http://src.chromium.org/svn/trunk/src/
Patch Set: CommandLine fix Created 11 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/installer/setup/uninstall.cc ('k') | chrome/installer/util/move_tree_work_item.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/installer/util/master_preferences_unittest.cc
===================================================================
--- chrome/installer/util/master_preferences_unittest.cc (revision 23574)
+++ chrome/installer/util/master_preferences_unittest.cc (working copy)
@@ -24,8 +24,8 @@
} // namespace
TEST(MasterPreferencesTest, ParseDistroParams) {
- std::wstring prefs_file;
- ASSERT_TRUE(file_util::CreateTemporaryFileName(&prefs_file));
+ FilePath prefs_file;
+ ASSERT_TRUE(file_util::CreateTemporaryFile(&prefs_file));
const char text[] =
"{ \n"
" \"distribution\": { \n"
@@ -54,8 +54,7 @@
EXPECT_TRUE(file_util::WriteFile(prefs_file, text, sizeof(text)));
scoped_ptr<DictionaryValue> prefs(
- installer_util::ParseDistributionPreferences(
- FilePath::FromWStringHack(prefs_file)));
+ installer_util::ParseDistributionPreferences(prefs_file));
EXPECT_TRUE(prefs.get() != NULL);
EXPECT_TRUE(installer_util::GetDistroBooleanPreference(prefs.get(),
installer_util::master_preferences::kDistroSkipFirstRunPref));
@@ -104,8 +103,8 @@
}
TEST(MasterPreferencesTest, ParseMissingDistroParams) {
- std::wstring prefs_file;
- ASSERT_TRUE(file_util::CreateTemporaryFileName(&prefs_file));
+ FilePath prefs_file;
+ ASSERT_TRUE(file_util::CreateTemporaryFile(&prefs_file));
const char text[] =
"{ \n"
" \"distribution\": { \n"
@@ -120,8 +119,7 @@
EXPECT_TRUE(file_util::WriteFile(prefs_file, text, sizeof(text)));
scoped_ptr<DictionaryValue> prefs(
- installer_util::ParseDistributionPreferences(
- FilePath::FromWStringHack(prefs_file)));
+ installer_util::ParseDistributionPreferences(prefs_file));
EXPECT_TRUE(prefs.get() != NULL);
EXPECT_TRUE(installer_util::GetDistroBooleanPreference(prefs.get(),
installer_util::master_preferences::kDistroSkipFirstRunPref));
@@ -159,8 +157,8 @@
}
TEST(MasterPreferencesTest, FirstRunTabs) {
- std::wstring prefs_file;
- ASSERT_TRUE(file_util::CreateTemporaryFileName(&prefs_file));
+ FilePath prefs_file;
+ ASSERT_TRUE(file_util::CreateTemporaryFile(&prefs_file));
const char text[] =
"{ \n"
" \"distribution\": { \n"
@@ -175,8 +173,7 @@
EXPECT_TRUE(file_util::WriteFile(prefs_file, text, sizeof(text)));
scoped_ptr<DictionaryValue> prefs(
- installer_util::ParseDistributionPreferences(
- FilePath::FromWStringHack(prefs_file)));
+ installer_util::ParseDistributionPreferences(prefs_file));
EXPECT_TRUE(prefs.get() != NULL);
typedef std::vector<std::wstring> TabsVector;
Property changes on: chrome\installer\util\master_preferences_unittest.cc
___________________________________________________________________
Added: svn:eol-style
+ LF
« no previous file with comments | « chrome/installer/setup/uninstall.cc ('k') | chrome/installer/util/move_tree_work_item.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698