| 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_version_info.h" | 8 #include "base/file_version_info.h" |
| 9 #include "base/files/scoped_temp_dir.h" |
| 9 #include "base/path_service.h" | 10 #include "base/path_service.h" |
| 10 #include "base/stringprintf.h" | 11 #include "base/stringprintf.h" |
| 11 #include "base/test/test_timeouts.h" | 12 #include "base/test/test_timeouts.h" |
| 12 #include "base/utf_string_conversions.h" | 13 #include "base/utf_string_conversions.h" |
| 13 #include "base/win/windows_version.h" | 14 #include "base/win/windows_version.h" |
| 14 #include "chrome/common/chrome_switches.h" | 15 #include "chrome/common/chrome_switches.h" |
| 15 #include "chrome/installer/util/product.h" | 16 #include "chrome/installer/util/product.h" |
| 16 #include "chrome/installer/util/install_util.h" | 17 #include "chrome/installer/util/install_util.h" |
| 17 #include "chrome/installer/util/helper.h" | 18 #include "chrome/installer/util/helper.h" |
| 18 #include "chrome_frame/html_utils.h" | 19 #include "chrome_frame/html_utils.h" |
| (...skipping 49 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 68 | 69 |
| 69 ::testing::Environment* const chrome_frame_env = | 70 ::testing::Environment* const chrome_frame_env = |
| 70 ::testing::AddGlobalTestEnvironment(new ChromeFrameTestEnvironment); | 71 ::testing::AddGlobalTestEnvironment(new ChromeFrameTestEnvironment); |
| 71 | 72 |
| 72 } // namespace | 73 } // namespace |
| 73 | 74 |
| 74 FilePath ChromeFrameTestWithWebServer::test_file_path_; | 75 FilePath ChromeFrameTestWithWebServer::test_file_path_; |
| 75 FilePath ChromeFrameTestWithWebServer::results_dir_; | 76 FilePath ChromeFrameTestWithWebServer::results_dir_; |
| 76 FilePath ChromeFrameTestWithWebServer::CFInstall_path_; | 77 FilePath ChromeFrameTestWithWebServer::CFInstall_path_; |
| 77 FilePath ChromeFrameTestWithWebServer::CFInstance_path_; | 78 FilePath ChromeFrameTestWithWebServer::CFInstance_path_; |
| 78 ScopedTempDir ChromeFrameTestWithWebServer::temp_dir_; | 79 base::ScopedTempDir ChromeFrameTestWithWebServer::temp_dir_; |
| 79 FilePath ChromeFrameTestWithWebServer::chrome_user_data_dir_; | 80 FilePath ChromeFrameTestWithWebServer::chrome_user_data_dir_; |
| 80 chrome_frame_test::TimedMsgLoop* ChromeFrameTestWithWebServer::loop_; | 81 chrome_frame_test::TimedMsgLoop* ChromeFrameTestWithWebServer::loop_; |
| 81 std::string ChromeFrameTestWithWebServer::local_address_; | 82 std::string ChromeFrameTestWithWebServer::local_address_; |
| 82 testing::StrictMock<MockWebServerListener>* | 83 testing::StrictMock<MockWebServerListener>* |
| 83 ChromeFrameTestWithWebServer::listener_mock_; | 84 ChromeFrameTestWithWebServer::listener_mock_; |
| 84 testing::StrictMock<MockWebServer>* ChromeFrameTestWithWebServer::server_mock_; | 85 testing::StrictMock<MockWebServer>* ChromeFrameTestWithWebServer::server_mock_; |
| 85 | 86 |
| 86 ChromeFrameTestWithWebServer::ChromeFrameTestWithWebServer() { | 87 ChromeFrameTestWithWebServer::ChromeFrameTestWithWebServer() { |
| 87 } | 88 } |
| 88 | 89 |
| (...skipping 975 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1064 server.web_server()->AddResponse(response); | 1065 server.web_server()->AddResponse(response); |
| 1065 | 1066 |
| 1066 std::wstring url(server.FormatHttpPath(L"form.html")); | 1067 std::wstring url(server.FormatHttpPath(L"form.html")); |
| 1067 | 1068 |
| 1068 ASSERT_TRUE(LaunchBrowser(IE, url.c_str())); | 1069 ASSERT_TRUE(LaunchBrowser(IE, url.c_str())); |
| 1069 loop().RunFor(kChromeFrameLongNavigationTimeout); | 1070 loop().RunFor(kChromeFrameLongNavigationTimeout); |
| 1070 | 1071 |
| 1071 EXPECT_EQ(1, response->get_request_count()); | 1072 EXPECT_EQ(1, response->get_request_count()); |
| 1072 EXPECT_EQ(1, response->post_request_count()); | 1073 EXPECT_EQ(1, response->post_request_count()); |
| 1073 } | 1074 } |
| OLD | NEW |