| Index: chrome/browser/extensions/page_action_apitest.cc
|
| diff --git a/chrome/browser/extensions/page_action_apitest.cc b/chrome/browser/extensions/page_action_apitest.cc
|
| index 207ecccb91b053977ff76650c7a13ca840aa56f2..4a97d7985bde21a703382b1576359dea60828ae4 100644
|
| --- a/chrome/browser/extensions/page_action_apitest.cc
|
| +++ b/chrome/browser/extensions/page_action_apitest.cc
|
| @@ -12,7 +12,7 @@
|
| #include "chrome/browser/tab_contents/tab_contents.h"
|
| #include "chrome/browser/views/browser_actions_container.h"
|
| #include "chrome/browser/views/toolbar_view.h"
|
| -#include "chrome/common/extensions/extension_action.h"
|
| +#include "chrome/common/extensions/extension_action2.h"
|
| #include "chrome/test/ui_test_utils.h"
|
|
|
| IN_PROC_BROWSER_TEST_F(ExtensionApiTest, PageAction) {
|
| @@ -33,11 +33,11 @@ IN_PROC_BROWSER_TEST_F(ExtensionApiTest, PageAction) {
|
| }
|
|
|
| // Test that we received the changes.
|
| - const ExtensionActionState* action_state =
|
| - browser()->GetSelectedTabContents()->GetPageActionState(
|
| - extension->page_action());
|
| - ASSERT_TRUE(action_state);
|
| - EXPECT_EQ("Modified", action_state->title());
|
| + int tab_id =
|
| + browser()->GetSelectedTabContents()->controller().session_id().id();
|
| + ExtensionAction2* action = extension->page_action();
|
| + ASSERT_TRUE(action);
|
| + EXPECT_EQ("Modified", action->GetTitle(tab_id));
|
|
|
| {
|
| // Simulate the page action being clicked.
|
| @@ -57,7 +57,6 @@ IN_PROC_BROWSER_TEST_F(ExtensionApiTest, PageAction) {
|
| }
|
|
|
| // Test that we received the changes.
|
| - action_state = browser()->GetSelectedTabContents()->GetPageActionState(
|
| - extension->page_action());
|
| - EXPECT_TRUE(action_state->icon());
|
| + tab_id = browser()->GetSelectedTabContents()->controller().session_id().id();
|
| + EXPECT_FALSE(action->GetIcon(tab_id).isNull());
|
| }
|
|
|