Chromium Code Reviews| 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 6866325763caca7db0c1943fcc0b14482fb51a9d..7ba82ff8b4ff66edaef328e0e47b56d81e9dc83f 100644 |
| --- a/chrome/browser/extensions/extension_install_ui_browsertest.cc |
| +++ b/chrome/browser/extensions/extension_install_ui_browsertest.cc |
| @@ -60,3 +60,29 @@ IN_PROC_BROWSER_TEST_F(ExtensionInstallUIBrowserTest, |
| VerifyThemeInfoBarAndUndoInstall(); |
| ASSERT_EQ(NULL, browser()->profile()->GetTheme()); |
| } |
| + |
| +IN_PROC_BROWSER_TEST_F(ExtensionInstallUIBrowserTest, |
| + AppInstallConfirmation) { |
| + int num_tabs = browser()->tab_count(); |
| + |
| + FilePath app_path = test_data_dir_.AppendASCII("app.crx"); |
| + ASSERT_TRUE(InstallExtensionWithUIAutoConfirm(app_path, 1, |
| + browser()->profile())); |
| + EXPECT_EQ(num_tabs + 1, browser()->tab_count()); |
|
Aaron Boodman
2010/12/14 23:21:44
Is it also possible to test that the new tab is th
Tessa MacDuff
2010/12/15 00:38:55
Done.
|
| +} |
| + |
| +IN_PROC_BROWSER_TEST_F(ExtensionInstallUIBrowserTest, |
| + AppInstallConfirmation_Incognito) { |
| + Profile* incognito_profile = browser()->profile()->GetOffTheRecordProfile(); |
| + Browser* incognito_browser = Browser::GetOrCreateTabbedBrowser( |
| + incognito_profile); |
| + |
| + int num_incognito_tabs = incognito_browser->tab_count(); |
| + int num_normal_tabs = browser()->tab_count(); |
| + |
| + FilePath app_path = test_data_dir_.AppendASCII("app.crx"); |
| + ASSERT_TRUE(InstallExtensionWithUIAutoConfirm(app_path, 1, |
| + incognito_profile)); |
| + EXPECT_EQ(num_incognito_tabs, incognito_browser->tab_count()); |
| + EXPECT_EQ(num_normal_tabs + 1, browser()->tab_count()); |
| +} |