| Index: chrome/browser/ui/browser_navigator_browsertest.cc
|
| ===================================================================
|
| --- chrome/browser/ui/browser_navigator_browsertest.cc (revision 146674)
|
| +++ chrome/browser/ui/browser_navigator_browsertest.cc (working copy)
|
| @@ -696,62 +696,6 @@
|
| EXPECT_EQ(2, browser()->tab_count());
|
| }
|
|
|
| -// This test verifies that constructing params with a NULL browser has
|
| -// the same result as navigating to a new foreground tab in the (only)
|
| -// active browser. Tests are the same as for Disposition_NewForegroundTab.
|
| -IN_PROC_BROWSER_TEST_F(BrowserNavigatorTest, NullBrowser_NewForegroundTab) {
|
| - WebContents* old_contents = chrome::GetActiveWebContents(browser());
|
| - // Navigate with a NULL browser.
|
| - chrome::NavigateParams p(MakeNavigateParams(NULL));
|
| - p.disposition = NEW_FOREGROUND_TAB;
|
| - p.profile = browser()->profile();
|
| - chrome::Navigate(&p);
|
| -
|
| - // Navigate() should have found browser() and create a new tab.
|
| - EXPECT_EQ(browser(), p.browser);
|
| - EXPECT_NE(old_contents, chrome::GetActiveWebContents(browser()));
|
| - EXPECT_EQ(chrome::GetActiveTabContents(browser()), p.target_contents);
|
| - EXPECT_EQ(2, browser()->tab_count());
|
| -}
|
| -
|
| -// This test verifies that constructing params with a NULL browser and
|
| -// a specific profile matches the specified profile.
|
| -IN_PROC_BROWSER_TEST_F(BrowserNavigatorTest, NullBrowser_MatchProfile) {
|
| - // Create a new browser with using the incognito profile.
|
| - Browser* incognito =
|
| - Browser::Create(browser()->profile()->GetOffTheRecordProfile());
|
| -
|
| - // Navigate with a NULL browser and the incognito profile.
|
| - chrome::NavigateParams p(MakeNavigateParams(NULL));
|
| - p.disposition = NEW_FOREGROUND_TAB;
|
| - p.profile = incognito->profile();
|
| - chrome::Navigate(&p);
|
| -
|
| - // Navigate() should have found incognito, not browser().
|
| - EXPECT_EQ(incognito, p.browser);
|
| - EXPECT_EQ(chrome::GetActiveTabContents(incognito), p.target_contents);
|
| - EXPECT_EQ(1, incognito->tab_count());
|
| -}
|
| -
|
| -// This test verifies that constructing params with a NULL browser and
|
| -// disposition = NEW_WINDOW always opens exactly one new window.
|
| -IN_PROC_BROWSER_TEST_F(BrowserNavigatorTest, NullBrowser_NewWindow) {
|
| - chrome::NavigateParams p(MakeNavigateParams(NULL));
|
| - p.disposition = NEW_WINDOW;
|
| - p.profile = browser()->profile();
|
| - chrome::Navigate(&p);
|
| -
|
| - // Navigate() should have created a new browser.
|
| - EXPECT_NE(browser(), p.browser);
|
| - EXPECT_TRUE( p.browser->is_type_tabbed());
|
| -
|
| - // We should now have two windows, the browser() provided by the framework and
|
| - // the new normal window.
|
| - EXPECT_EQ(2u, BrowserList::size());
|
| - EXPECT_EQ(1, browser()->tab_count());
|
| - EXPECT_EQ(1, p.browser->tab_count());
|
| -}
|
| -
|
| // This test verifies that constructing params with disposition = SINGLETON_TAB
|
| // and IGNORE_AND_NAVIGATE opens a new tab navigated to the specified URL if
|
| // no previous tab with that URL (minus the path) exists.
|
|
|