| 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);
|
| }
|
|
|