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

Unified Diff: base/file_util_unittest.cc

Issue 173181: Remove uses of deprecated version of FileUtil::ResolveShortcut.... (Closed) Base URL: http://src.chromium.org/svn/trunk/src/
Patch Set: rewritten comment 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 | « base/file_util.h ('k') | base/file_util_win.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: base/file_util_unittest.cc
===================================================================
--- base/file_util_unittest.cc (revision 24065)
+++ base/file_util_unittest.cc (working copy)
@@ -712,16 +712,15 @@
shell->Release();
bool is_solved;
- std::wstring link_file_str = link_file.value();
- is_solved = file_util::ResolveShortcut(&link_file_str);
+ is_solved = file_util::ResolveShortcut(&link_file);
EXPECT_TRUE(is_solved);
std::wstring contents;
- contents = ReadTextFile(FilePath(link_file_str));
+ contents = ReadTextFile(link_file);
EXPECT_EQ(L"This is the target.", contents);
// Cleaning
DeleteFile(target_file.value().c_str());
- DeleteFile(link_file_str.c_str());
+ DeleteFile(link_file.value().c_str());
CoUninitialize();
}
@@ -736,9 +735,9 @@
EXPECT_TRUE(file_util::CreateShortcutLink(target_file.value().c_str(),
link_file.value().c_str(),
NULL, NULL, NULL, NULL, 0));
- std::wstring resolved_name = link_file.value();
+ FilePath resolved_name = link_file;
EXPECT_TRUE(file_util::ResolveShortcut(&resolved_name));
- std::wstring read_contents = ReadTextFile(FilePath(resolved_name));
+ std::wstring read_contents = ReadTextFile(resolved_name);
EXPECT_EQ(file_contents, read_contents);
DeleteFile(target_file.value().c_str());
« no previous file with comments | « base/file_util.h ('k') | base/file_util_win.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698