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

Unified Diff: chrome/common/extensions/extension_unittest.cc

Issue 10914244: Remove support for page_action.icons, and the legacy code surrounding it. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: constants removed Created 8 years, 3 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/common/extensions/extension_unittest.cc
diff --git a/chrome/common/extensions/extension_unittest.cc b/chrome/common/extensions/extension_unittest.cc
index 72d04c3fb562d16d2373ad3f1fbdb950e89933bd..5f5c3296b1aecab2b0b23dac62159622aeb13a9a 100644
--- a/chrome/common/extensions/extension_unittest.cc
+++ b/chrome/common/extensions/extension_unittest.cc
@@ -222,7 +222,6 @@ TEST(ExtensionTest, LoadPageActionHelper) {
const std::string id("MyExtensionActionId");
const std::string name("MyExtensionActionName");
std::string img1("image1.png");
- std::string img2("image2.png");
action = LoadAction("page_action.json");
ASSERT_TRUE(NULL != action.get());
@@ -230,9 +229,7 @@ TEST(ExtensionTest, LoadPageActionHelper) {
// No title, so fall back to name.
ASSERT_EQ(name, action->GetTitle(1));
- ASSERT_EQ(2u, action->icon_paths()->size());
- ASSERT_EQ(img1, (*action->icon_paths())[0]);
- ASSERT_EQ(img2, (*action->icon_paths())[1]);
+ ASSERT_EQ(img1, action->default_icon_path());
// Same test with explicitly set type.
action = LoadAction("page_action_type.json");
@@ -259,7 +256,7 @@ TEST(ExtensionTest, LoadPageActionHelper) {
action = LoadAction("page_action_new_format.json");
ASSERT_TRUE(action.get());
ASSERT_EQ(kTitle, action->GetTitle(1));
- ASSERT_EQ(0u, action->icon_paths()->size());
+ ASSERT_FALSE(action->default_icon_path().empty());
// Invalid title should give an error even with a valid name.
LoadActionAndExpectError("page_action_invalid_title.json",

Powered by Google App Engine
This is Rietveld 408576698