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 "base/command_line.h" | 5 #include "base/command_line.h" |
6 #include "base/files/file_path.h" | 6 #include "base/files/file_path.h" |
7 #include "base/memory/scoped_ptr.h" | 7 #include "base/memory/scoped_ptr.h" |
8 #include "base/process/kill.h" | 8 #include "base/process/kill.h" |
9 #include "base/strings/string_util.h" | 9 #include "base/strings/string_util.h" |
10 #include "chrome/common/chrome_result_codes.h" | 10 #include "chrome/common/chrome_result_codes.h" |
(...skipping 223 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
234 // Repair registry. | 234 // Repair registry. |
235 TEST_F(MiniInstallTest, RepairRegistryOnFullUser) { | 235 TEST_F(MiniInstallTest, RepairRegistryOnFullUser) { |
236 ASSERT_TRUE(installer_test::Install( | 236 ASSERT_TRUE(installer_test::Install( |
237 full_installer_, SwitchBuilder().AddChrome())); | 237 full_installer_, SwitchBuilder().AddChrome())); |
238 ASSERT_TRUE(installer_test::ValidateInstall(false, | 238 ASSERT_TRUE(installer_test::ValidateInstall(false, |
239 InstallationValidator::CHROME_SINGLE, provider_->GetCurrentBuild())); | 239 InstallationValidator::CHROME_SINGLE, provider_->GetCurrentBuild())); |
240 base::CleanupProcesses(installer::kChromeExe, base::TimeDelta(), | 240 base::CleanupProcesses(installer::kChromeExe, base::TimeDelta(), |
241 content::RESULT_CODE_HUNG, NULL); | 241 content::RESULT_CODE_HUNG, NULL); |
242 ASSERT_TRUE(installer_test::DeleteRegistryKey( | 242 ASSERT_TRUE(installer_test::DeleteRegistryKey( |
243 false, // system level | 243 false, // system level |
244 InstallationValidator::CHROME_SINGLE)); | 244 InstallationValidator::CHROME_SINGLE, 0)); // no WOW64 |
245 ASSERT_TRUE( | 245 ASSERT_TRUE( |
246 installer_test::Install(full_installer_, SwitchBuilder().AddChrome())); | 246 installer_test::Install(full_installer_, SwitchBuilder().AddChrome())); |
247 ASSERT_TRUE(installer_test::ValidateInstall(false, | 247 ASSERT_TRUE(installer_test::ValidateInstall(false, |
248 InstallationValidator::CHROME_SINGLE, provider_->GetCurrentBuild())); | 248 InstallationValidator::CHROME_SINGLE, provider_->GetCurrentBuild())); |
249 } | 249 } |
250 | 250 |
251 TEST_F(MiniInstallTest, RepairRegistryOnFullSys) { | 251 TEST_F(MiniInstallTest, RepairRegistryOnFullSys) { |
252 ASSERT_TRUE(installer_test::Install(full_installer_, | 252 ASSERT_TRUE(installer_test::Install(full_installer_, |
253 SwitchBuilder().AddChrome().AddSystemInstall())); | 253 SwitchBuilder().AddChrome().AddSystemInstall())); |
254 ASSERT_TRUE(installer_test::ValidateInstall(true, | 254 ASSERT_TRUE(installer_test::ValidateInstall(true, |
255 InstallationValidator::CHROME_SINGLE, provider_->GetCurrentBuild())); | 255 InstallationValidator::CHROME_SINGLE, provider_->GetCurrentBuild())); |
256 ASSERT_TRUE(installer_test::DeleteRegistryKey( | 256 ASSERT_TRUE(installer_test::DeleteRegistryKey( |
257 true, // system level | 257 true, // system level |
258 InstallationValidator::CHROME_SINGLE)); | 258 InstallationValidator::CHROME_SINGLE, 0)); // no WOW64 |
259 ASSERT_TRUE(installer_test::Install(full_installer_, | 259 ASSERT_TRUE(installer_test::Install(full_installer_, |
260 SwitchBuilder().AddChrome().AddSystemInstall())); | 260 SwitchBuilder().AddChrome().AddSystemInstall())); |
261 ASSERT_TRUE(installer_test::ValidateInstall(true, | 261 ASSERT_TRUE(installer_test::ValidateInstall(true, |
262 InstallationValidator::CHROME_SINGLE, provider_->GetCurrentBuild())); | 262 InstallationValidator::CHROME_SINGLE, provider_->GetCurrentBuild())); |
263 } | 263 } |
264 | 264 |
265 // Run full Chrome Frame install then uninstall it while IE browser is running. | 265 // Run full Chrome Frame install then uninstall it while IE browser is running. |
266 TEST_F(MiniInstallTest, FullInstallAndUnInstallChromeFrameWithIERunning) { | 266 TEST_F(MiniInstallTest, FullInstallAndUnInstallChromeFrameWithIERunning) { |
267 ASSERT_TRUE(installer_test::Install(full_installer_, | 267 ASSERT_TRUE(installer_test::Install(full_installer_, |
268 SwitchBuilder().AddChromeFrame().AddSystemInstall())); | 268 SwitchBuilder().AddChromeFrame().AddSystemInstall())); |
(...skipping 134 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
403 } | 403 } |
404 | 404 |
405 #endif | 405 #endif |
406 | 406 |
407 TEST(GenericInstallTest, MiniInstallTestValidWindowsVersion) { | 407 TEST(GenericInstallTest, MiniInstallTestValidWindowsVersion) { |
408 // We run the tests on all supported OSes. | 408 // We run the tests on all supported OSes. |
409 // Make sure the code agrees. | 409 // Make sure the code agrees. |
410 EXPECT_TRUE(InstallUtil::IsOSSupported()); | 410 EXPECT_TRUE(InstallUtil::IsOSSupported()); |
411 } | 411 } |
412 | 412 |
OLD | NEW |