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

Unified Diff: chrome/browser/printing/printing_layout_uitest.cc

Issue 9585001: Cleanup: Remove deprecated version of file_util::AppendToPath(). (Closed) Base URL: svn://chrome-svn/chrome/trunk/src/
Patch Set: Created 8 years, 9 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/test/test_file_util_win.cc ('k') | chrome/test/mini_installer_test/installer_test_util.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/browser/printing/printing_layout_uitest.cc
===================================================================
--- chrome/browser/printing/printing_layout_uitest.cc (revision 125906)
+++ chrome/browser/printing/printing_layout_uitest.cc (working copy)
@@ -59,18 +59,14 @@
return 100.;
}
- std::wstring verification_file(test_data_directory_.value());
- file_util::AppendToPath(&verification_file, L"printing");
- file_util::AppendToPath(&verification_file, verification_name);
- FilePath emf(verification_file + L".emf");
- FilePath png(verification_file + L".png");
+ FilePath base_path(test_data_directory_.AppendASCII("printing"));
+ FilePath emf(base_path.Append(verification_name + L".emf"));
+ FilePath png(base_path.Append(verification_name + L".png"));
+ FilePath cleartype(base_path.Append(verification_name + L"_cleartype.png"));
// Looks for Cleartype override.
- if (file_util::PathExists(
- FilePath::FromWStringHack(verification_file + L"_cleartype.png")) &&
- IsClearTypeEnabled()) {
- png = FilePath(verification_file + L"_cleartype.png");
- }
+ if (file_util::PathExists(cleartype) && IsClearTypeEnabled())
+ png = cleartype;
if (GenerateFiles()) {
// Copy the .emf and generate an .png.
@@ -91,8 +87,8 @@
" result size:" << test_content.size().ToString();
if (diff_emf) {
// Backup the result emf file.
- file_util::CopyFile(test_result, FilePath(
- verification_file + L"_failed.emf"));
+ FilePath failed(base_path.Append(verification_name + L"_failed.emf"));
+ file_util::CopyFile(test_result, failed);
}
// This verification is only to know that the EMF rendering stays
@@ -103,7 +99,9 @@
" result size:" << test_content.size().ToString();
if (diff_png) {
// Backup the rendered emf file to detect the rendering difference.
- emf_content.SaveToPng(FilePath(verification_file + L"_rendering.png"));
+ FilePath rendering(
+ base_path.Append(verification_name + L"_rendering.png"));
+ emf_content.SaveToPng(rendering);
}
return std::max(diff_png, diff_emf);
}
« no previous file with comments | « base/test/test_file_util_win.cc ('k') | chrome/test/mini_installer_test/installer_test_util.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698