OLD | NEW |
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2012 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 | 4 |
5 #include "chrome_frame/test/test_with_web_server.h" | 5 #include "chrome_frame/test/test_with_web_server.h" |
6 | 6 |
7 #include "base/base_paths.h" | 7 #include "base/base_paths.h" |
8 #include "base/file_util.h" | 8 #include "base/file_util.h" |
9 #include "base/file_version_info.h" | 9 #include "base/file_version_info.h" |
10 #include "base/files/memory_mapped_file.h" | 10 #include "base/files/memory_mapped_file.h" |
(...skipping 288 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
299 FileVersionInfo::CreateFileVersionInfo(plugin_path); | 299 FileVersionInfo::CreateFileVersionInfo(plugin_path); |
300 | 300 |
301 std::wstring version; | 301 std::wstring version; |
302 if (version_info) | 302 if (version_info) |
303 version = version_info->product_version(); | 303 version = version_info->product_version(); |
304 | 304 |
305 // If we can't find the Chrome Frame DLL in the src tree, we turn to | 305 // If we can't find the Chrome Frame DLL in the src tree, we turn to |
306 // the directory where chrome is installed. | 306 // the directory where chrome is installed. |
307 if (!version_info) { | 307 if (!version_info) { |
308 BrowserDistribution* dist = BrowserDistribution::GetDistribution(); | 308 BrowserDistribution* dist = BrowserDistribution::GetDistribution(); |
309 Version ver_system; | 309 base::Version ver_system; |
310 InstallUtil::GetChromeVersion(dist, true, &ver_system); | 310 InstallUtil::GetChromeVersion(dist, true, &ver_system); |
311 Version ver_user; | 311 base::Version ver_user; |
312 InstallUtil::GetChromeVersion(dist, false, &ver_system); | 312 InstallUtil::GetChromeVersion(dist, false, &ver_system); |
313 ASSERT_TRUE(ver_system.IsValid() || ver_user.IsValid()); | 313 ASSERT_TRUE(ver_system.IsValid() || ver_user.IsValid()); |
314 | 314 |
315 bool system_install = ver_system.IsValid(); | 315 bool system_install = ver_system.IsValid(); |
316 base::FilePath cf_dll_path(installer::GetChromeInstallPath(system_install, d
ist)); | 316 base::FilePath cf_dll_path(installer::GetChromeInstallPath(system_install, d
ist)); |
317 cf_dll_path = cf_dll_path.Append(UTF8ToWide( | 317 cf_dll_path = cf_dll_path.Append(UTF8ToWide( |
318 ver_system.IsValid() ? ver_system.GetString() : ver_user.GetString())); | 318 ver_system.IsValid() ? ver_system.GetString() : ver_user.GetString())); |
319 cf_dll_path = cf_dll_path.Append(kChromeFrameDllName); | 319 cf_dll_path = cf_dll_path.Append(kChromeFrameDllName); |
320 version_info = FileVersionInfo::CreateFileVersionInfo(cf_dll_path); | 320 version_info = FileVersionInfo::CreateFileVersionInfo(cf_dll_path); |
321 if (version_info) | 321 if (version_info) |
(...skipping 769 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1091 // This test loads a large page and ensures that the full page contents are | 1091 // This test loads a large page and ensures that the full page contents are |
1092 // actually loaded via a self-validating HTML page. This is done due to a bug | 1092 // actually loaded via a self-validating HTML page. This is done due to a bug |
1093 // whereby the middle of the response stream would sometimes be truncated when | 1093 // whereby the middle of the response stream would sometimes be truncated when |
1094 // loading a CF document. See http://crbug.com/178421 for details. | 1094 // loading a CF document. See http://crbug.com/178421 for details. |
1095 TEST_F(ChromeFrameTestWithWebServer, FullTabModeIE_LargePageLoad) { | 1095 TEST_F(ChromeFrameTestWithWebServer, FullTabModeIE_LargePageLoad) { |
1096 const wchar_t kLargePageLoadPage[] = | 1096 const wchar_t kLargePageLoadPage[] = |
1097 L"chrome_frame_large_page.html"; | 1097 L"chrome_frame_large_page.html"; |
1098 | 1098 |
1099 SimpleBrowserTest(IE, kLargePageLoadPage); | 1099 SimpleBrowserTest(IE, kLargePageLoadPage); |
1100 } | 1100 } |
OLD | NEW |