summaryrefslogtreecommitdiffstats
path: root/chrome/test
diff options
context:
space:
mode:
Diffstat (limited to 'chrome/test')
-rw-r--r--chrome/test/mini_installer_test/chrome_mini_installer.cc15
-rw-r--r--chrome/test/mini_installer_test/chrome_mini_installer.h3
-rw-r--r--chrome/test/mini_installer_test/test.cc4
3 files changed, 19 insertions, 3 deletions
diff --git a/chrome/test/mini_installer_test/chrome_mini_installer.cc b/chrome/test/mini_installer_test/chrome_mini_installer.cc
index 7f1f71e..93bdf3d 100644
--- a/chrome/test/mini_installer_test/chrome_mini_installer.cc
+++ b/chrome/test/mini_installer_test/chrome_mini_installer.cc
@@ -218,7 +218,7 @@ void ChromeMiniInstaller::UnInstall() {
WaitUntilProcessStopsRunning(
mini_installer_constants::kChromeSetupExecutable);
printf("\n\nUninstall Checks:\n\n");
- ASSERT_FALSE(CheckRegistryKey(dist->GetVersionKey()));
+ ASSERT_FALSE(CheckRegistryKeyOnUninstall(dist->GetVersionKey()));
DeleteAppFolder();
FindChromeShortcut();
CloseProcesses(mini_installer_constants::kIEExecutable);
@@ -318,6 +318,19 @@ bool ChromeMiniInstaller::CheckRegistryKey(const std::wstring& key_path) {
return true;
}
+// Checks for Chrome registry keys on uninstall.
+bool ChromeMiniInstaller::CheckRegistryKeyOnUninstall(
+ const std::wstring& key_path) {
+ RegKey key;
+ int timer = 0;
+ while ((key.Open(GetRootRegistryKey(), key_path.c_str(), KEY_ALL_ACCESS)) &&
+ (timer < 20000)) {
+ PlatformThread::Sleep(200);
+ timer = timer + 200;
+ }
+ return CheckRegistryKey(key_path);
+}
+
// Deletes App folder after uninstall.
void ChromeMiniInstaller::DeleteAppFolder() {
std::wstring path = GetChromeInstallDirectoryLocation();
diff --git a/chrome/test/mini_installer_test/chrome_mini_installer.h b/chrome/test/mini_installer_test/chrome_mini_installer.h
index 0167ba1..f8578bd 100644
--- a/chrome/test/mini_installer_test/chrome_mini_installer.h
+++ b/chrome/test/mini_installer_test/chrome_mini_installer.h
@@ -95,6 +95,9 @@ class ChromeMiniInstaller {
// Checks for registry key.
bool CheckRegistryKey(const std::wstring& key_path);
+ // Checks for registry key on uninstall.
+ bool CheckRegistryKeyOnUninstall(const std::wstring& key_path);
+
// Deletes App folder after uninstall.
void DeleteAppFolder();
diff --git a/chrome/test/mini_installer_test/test.cc b/chrome/test/mini_installer_test/test.cc
index 1ddb44b..d3a9745 100644
--- a/chrome/test/mini_installer_test/test.cc
+++ b/chrome/test/mini_installer_test/test.cc
@@ -38,7 +38,7 @@ TEST_F(MiniInstallTest, FullInstallerTest) {
}
// Will enable this test after bug#9593 gets fixed.
-TEST_F(MiniInstallTest, DISABLED_DifferentialInstallerTest) {
+TEST_F(MiniInstallTest, DifferentialInstallerTest) {
ChromeMiniInstaller installer(mini_installer_constants::kUserInstall);
installer.InstallDifferentialInstaller();
}
@@ -48,7 +48,7 @@ TEST_F(MiniInstallTest, DISABLED_StandaloneInstallerTest) {
installer.InstallStandaloneIntaller();
}
-TEST_F(MiniInstallTest, MiniInstallerOverChromeMetaInstallerTest) {
+TEST_F(MiniInstallTest, DISABLED_MiniInstallerOverChromeMetaInstallerTest) {
ChromeMiniInstaller installer(mini_installer_constants::kUserInstall);
installer.OverInstall();
}