Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(9194)

Unified Diff: chrome/installer/util/install_util_unittest.cc

Issue 282363003: Add WOW64 support to the installer registry work items (Closed) Base URL: https://chromium.googlesource.com/chromium/src
Patch Set: add wow64 logic to installer_util. mini_installer tests. Created 6 years, 7 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: chrome/installer/util/install_util_unittest.cc
diff --git a/chrome/installer/util/install_util_unittest.cc b/chrome/installer/util/install_util_unittest.cc
index f1234b8c10e7f72a2a875a2c98ae71cd5600b195..b18c5b76071d6a3bca0c17d16c9c0c675300c1fd 100644
--- a/chrome/installer/util/install_util_unittest.cc
+++ b/chrome/installer/util/install_util_unittest.cc
@@ -13,6 +13,7 @@
#include "chrome/installer/util/google_update_constants.h"
#include "chrome/installer/util/install_util.h"
#include "chrome/installer/util/product_unittest.h"
+#include "chrome/installer/util/work_item.h"
#include "testing/gmock/include/gmock/gmock.h"
using base::win::RegKey;
@@ -195,7 +196,8 @@ TEST_F(InstallUtilTest, DeleteRegistryKeyIf) {
EXPECT_EQ(InstallUtil::NOT_FOUND,
InstallUtil::DeleteRegistryKeyIf(root, parent_key_path,
child_key_path, value_name,
- pred));
+ pred,
+ WorkItem::kWow64Default));
EXPECT_FALSE(RegKey(root, parent_key_path.c_str(),
KEY_QUERY_VALUE).Valid());
}
@@ -209,7 +211,8 @@ TEST_F(InstallUtilTest, DeleteRegistryKeyIf) {
EXPECT_EQ(InstallUtil::NOT_FOUND,
InstallUtil::DeleteRegistryKeyIf(root, parent_key_path,
child_key_path, value_name,
- pred));
+ pred,
+ WorkItem::kWow64Default));
EXPECT_TRUE(RegKey(root, parent_key_path.c_str(),
KEY_QUERY_VALUE).Valid());
}
@@ -223,7 +226,8 @@ TEST_F(InstallUtilTest, DeleteRegistryKeyIf) {
EXPECT_EQ(InstallUtil::NOT_FOUND,
InstallUtil::DeleteRegistryKeyIf(root, parent_key_path,
child_key_path, value_name,
- pred));
+ pred,
+ WorkItem::kWow64Default));
EXPECT_TRUE(RegKey(root, parent_key_path.c_str(),
KEY_QUERY_VALUE).Valid());
}
@@ -239,7 +243,8 @@ TEST_F(InstallUtilTest, DeleteRegistryKeyIf) {
EXPECT_EQ(InstallUtil::NOT_FOUND,
InstallUtil::DeleteRegistryKeyIf(root, parent_key_path,
child_key_path, value_name,
- pred));
+ pred,
+ WorkItem::kWow64Default));
EXPECT_TRUE(RegKey(root, parent_key_path.c_str(),
KEY_QUERY_VALUE).Valid());
}
@@ -255,7 +260,8 @@ TEST_F(InstallUtilTest, DeleteRegistryKeyIf) {
EXPECT_EQ(InstallUtil::DELETED,
InstallUtil::DeleteRegistryKeyIf(root, parent_key_path,
child_key_path, value_name,
- pred));
+ pred,
+ WorkItem::kWow64Default));
EXPECT_FALSE(RegKey(root, parent_key_path.c_str(),
KEY_QUERY_VALUE).Valid());
}
@@ -271,7 +277,8 @@ TEST_F(InstallUtilTest, DeleteRegistryKeyIf) {
EXPECT_EQ(InstallUtil::DELETED,
InstallUtil::DeleteRegistryKeyIf(root, parent_key_path,
child_key_path, NULL,
- pred));
+ pred,
+ WorkItem::kWow64Default));
EXPECT_FALSE(RegKey(root, parent_key_path.c_str(),
KEY_QUERY_VALUE).Valid());
}
@@ -295,7 +302,8 @@ TEST_F(InstallUtilTest, DeleteRegistryValueIf) {
ASSERT_FALSE(RegKey(root, key_path.c_str(), KEY_QUERY_VALUE).Valid());
EXPECT_EQ(InstallUtil::NOT_FOUND,
InstallUtil::DeleteRegistryValueIf(root, key_path.c_str(),
- value_name, pred));
+ value_name, pred,
+ WorkItem::kWow64Default));
EXPECT_FALSE(RegKey(root, key_path.c_str(), KEY_QUERY_VALUE).Valid());
}
@@ -307,7 +315,8 @@ TEST_F(InstallUtilTest, DeleteRegistryValueIf) {
ASSERT_TRUE(RegKey(root, key_path.c_str(), KEY_SET_VALUE).Valid());
EXPECT_EQ(InstallUtil::NOT_FOUND,
InstallUtil::DeleteRegistryValueIf(root, key_path.c_str(),
- value_name, pred));
+ value_name, pred,
+ WorkItem::kWow64Default));
EXPECT_TRUE(RegKey(root, key_path.c_str(), KEY_QUERY_VALUE).Valid());
}
@@ -321,7 +330,8 @@ TEST_F(InstallUtilTest, DeleteRegistryValueIf) {
KEY_SET_VALUE).WriteValue(value_name, L"foosball!"));
EXPECT_EQ(InstallUtil::NOT_FOUND,
InstallUtil::DeleteRegistryValueIf(root, key_path.c_str(),
- value_name, pred));
+ value_name, pred,
+ WorkItem::kWow64Default));
EXPECT_TRUE(RegKey(root, key_path.c_str(), KEY_QUERY_VALUE).Valid());
EXPECT_TRUE(RegKey(root, key_path.c_str(),
KEY_QUERY_VALUE).HasValue(value_name));
@@ -337,7 +347,8 @@ TEST_F(InstallUtilTest, DeleteRegistryValueIf) {
KEY_SET_VALUE).WriteValue(value_name, value));
EXPECT_EQ(InstallUtil::DELETED,
InstallUtil::DeleteRegistryValueIf(root, key_path.c_str(),
- value_name, pred));
+ value_name, pred,
+ WorkItem::kWow64Default));
EXPECT_TRUE(RegKey(root, key_path.c_str(), KEY_QUERY_VALUE).Valid());
EXPECT_FALSE(RegKey(root, key_path.c_str(),
KEY_QUERY_VALUE).HasValue(value_name));
@@ -357,7 +368,8 @@ TEST_F(InstallUtilTest, DeleteRegistryValueIf) {
KEY_SET_VALUE).WriteValue(L"", value));
EXPECT_EQ(InstallUtil::DELETED,
InstallUtil::DeleteRegistryValueIf(root, key_path.c_str(), L"",
- pred));
+ pred,
+ WorkItem::kWow64Default));
EXPECT_TRUE(RegKey(root, key_path.c_str(), KEY_QUERY_VALUE).Valid());
EXPECT_FALSE(RegKey(root, key_path.c_str(),
KEY_QUERY_VALUE).HasValue(L""));
@@ -377,7 +389,8 @@ TEST_F(InstallUtilTest, DeleteRegistryValueIf) {
KEY_SET_VALUE).WriteValue(L"", value));
EXPECT_EQ(InstallUtil::DELETED,
InstallUtil::DeleteRegistryValueIf(root, key_path.c_str(),
- NULL, pred));
+ NULL, pred,
+ WorkItem::kWow64Default));
EXPECT_TRUE(RegKey(root, key_path.c_str(), KEY_QUERY_VALUE).Valid());
EXPECT_FALSE(RegKey(root, key_path.c_str(),
KEY_QUERY_VALUE).HasValue(L""));

Powered by Google App Engine
This is Rietveld 408576698