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

Unified Diff: chrome/browser/extensions/extension_install_ui_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_install_ui_browsertest.cc
diff --git a/chrome/browser/extensions/extension_install_ui_browsertest.cc b/chrome/browser/extensions/extension_install_ui_browsertest.cc
index 23ddbb73a366fdc54ae9533ea580bbe83372c8a9..1ac2196287bf3e55e597e2372883a7d7211586a1 100644
--- a/chrome/browser/extensions/extension_install_ui_browsertest.cc
+++ b/chrome/browser/extensions/extension_install_ui_browsertest.cc
@@ -6,6 +6,7 @@
#include "chrome/browser/extensions/extension_browsertest.h"
#include "chrome/browser/extensions/extension_service.h"
#include "chrome/browser/extensions/theme_installed_infobar_delegate.h"
+#include "chrome/browser/infobars/infobar_tab_helper.h"
#include "chrome/browser/profiles/profile.h"
#include "chrome/browser/ui/browser.h"
#include "chrome/browser/ui/tab_contents/tab_contents_wrapper.h"
@@ -20,12 +21,13 @@ class ExtensionInstallUIBrowserTest : public ExtensionBrowserTest {
void VerifyThemeInfoBarAndUndoInstall() {
TabContentsWrapper* tab = browser()->GetSelectedTabContentsWrapper();
ASSERT_TRUE(tab);
- ASSERT_EQ(1U, tab->infobar_count());
- ConfirmInfoBarDelegate* delegate =
- tab->GetInfoBarDelegateAt(0)->AsConfirmInfoBarDelegate();
+ InfoBarTabHelper* infobar_helper = tab->infobar_tab_helper();
+ ASSERT_EQ(1U, infobar_helper->infobar_count());
+ ConfirmInfoBarDelegate* delegate = infobar_helper->
+ GetInfoBarDelegateAt(0)->AsConfirmInfoBarDelegate();
ASSERT_TRUE(delegate);
delegate->Cancel();
- ASSERT_EQ(0U, tab->infobar_count());
+ ASSERT_EQ(0U, infobar_helper->infobar_count());
}
const Extension* GetTheme() const {
« no previous file with comments | « chrome/browser/extensions/extension_install_ui.cc ('k') | chrome/browser/extensions/extension_management_browsertest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698