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

Unified Diff: chrome/browser/extensions/extension_management_browsertest.cc

Issue 7810002: Move infobar handling to a tab helper. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: fixes Created 9 years, 4 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/browser/extensions/extension_management_browsertest.cc
diff --git a/chrome/browser/extensions/extension_management_browsertest.cc b/chrome/browser/extensions/extension_management_browsertest.cc
index cd018a421906235a293642ffd71d1d8c7cdb347b..dd5357b6010f501907fa6bb33d799916c87e2b23 100644
--- a/chrome/browser/extensions/extension_management_browsertest.cc
+++ b/chrome/browser/extensions/extension_management_browsertest.cc
@@ -10,6 +10,7 @@
#include "chrome/browser/extensions/extension_service.h"
#include "chrome/browser/extensions/extension_test_message_listener.h"
#include "chrome/browser/extensions/extension_updater.h"
+#include "chrome/browser/infobars/infobar_tab_helper.h"
#include "chrome/browser/prefs/pref_service.h"
#include "chrome/browser/prefs/scoped_user_pref_update.h"
#include "chrome/browser/profiles/profile.h"
@@ -177,14 +178,15 @@ IN_PROC_BROWSER_TEST_F(ExtensionManagementTest, UpdatePermissionsAndUninstall) {
// Make sure the "disable extension" infobar is present.
ASSERT_EQ(0, browser()->active_index());
- TabContentsWrapper* wrapper = browser()->GetTabContentsWrapperAt(0);
- ASSERT_EQ(1U, wrapper->infobar_count());
+ InfoBarTabHelper* infobar_helper = browser()->GetTabContentsWrapperAt(0)->
+ infobar_tab_helper();
+ ASSERT_EQ(1U, infobar_helper->infobar_count());
// Uninstall, and check that the infobar went away.
ExtensionService* service = browser()->profile()->GetExtensionService();
std::string id = service->disabled_extensions()->at(0)->id();
UninstallExtension(id);
- ASSERT_EQ(0U, wrapper->infobar_count());
+ ASSERT_EQ(0U, infobar_helper->infobar_count());
// Now select a new tab, and switch back to the first tab which had the
// infobar. We should not crash.
« no previous file with comments | « chrome/browser/extensions/extension_install_ui_browsertest.cc ('k') | chrome/browser/external_tab_container_win.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698