OLD | NEW |
1 // Copyright (c) 2011 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2011 The Chromium Authors. All rights reserved. |
2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
4 #include <string> | 4 #include <string> |
5 | 5 |
6 #include "base/file_util.h" | 6 #include "base/file_util.h" |
7 #include "base/memory/scoped_temp_dir.h" | 7 #include "base/scoped_temp_dir.h" |
| 8 #include "chrome/browser/download/save_package.h" |
8 #include "chrome/browser/net/url_request_mock_http_job.h" | 9 #include "chrome/browser/net/url_request_mock_http_job.h" |
9 #include "chrome/browser/download/save_package.h" | |
10 #include "chrome/common/pref_names.h" | 10 #include "chrome/common/pref_names.h" |
11 #include "chrome/test/automation/browser_proxy.h" | 11 #include "chrome/test/automation/browser_proxy.h" |
12 #include "chrome/test/automation/tab_proxy.h" | 12 #include "chrome/test/automation/tab_proxy.h" |
13 #include "chrome/test/ui/ui_test.h" | 13 #include "chrome/test/ui/ui_test.h" |
14 #include "chrome/test/ui_test_utils.h" | 14 #include "chrome/test/ui_test_utils.h" |
15 | 15 |
16 static const FilePath::CharType* kTestDir = FILE_PATH_LITERAL("encoding_tests"); | 16 static const FilePath::CharType* kTestDir = FILE_PATH_LITERAL("encoding_tests"); |
17 | 17 |
18 class BrowserEncodingTest : public UITest { | 18 class BrowserEncodingTest : public UITest { |
19 protected: | 19 protected: |
(...skipping 273 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
293 expected_result_file_name = expected_result_file_name.AppendASCII( | 293 expected_result_file_name = expected_result_file_name.AppendASCII( |
294 kExpectedResultDir); | 294 kExpectedResultDir); |
295 expected_result_file_name = expected_result_file_name.AppendASCII( | 295 expected_result_file_name = expected_result_file_name.AppendASCII( |
296 kTestDatas[i].expected_result); | 296 kTestDatas[i].expected_result); |
297 EXPECT_TRUE(tab->SavePage(full_saved_file_name, temp_sub_resource_dir_, | 297 EXPECT_TRUE(tab->SavePage(full_saved_file_name, temp_sub_resource_dir_, |
298 SavePackage::SAVE_AS_COMPLETE_HTML)); | 298 SavePackage::SAVE_AS_COMPLETE_HTML)); |
299 EXPECT_TRUE(WaitForDownloadShelfVisible(browser.get())); | 299 EXPECT_TRUE(WaitForDownloadShelfVisible(browser.get())); |
300 CheckFile(full_saved_file_name, expected_result_file_name, true); | 300 CheckFile(full_saved_file_name, expected_result_file_name, true); |
301 } | 301 } |
302 } | 302 } |
OLD | NEW |