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

Unified Diff: content/browser/renderer_host/resource_dispatcher_host_browsertest.cc

Issue 10539134: TabContentsWrapper -> TabContents, part 57. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: last use Created 8 years, 6 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: content/browser/renderer_host/resource_dispatcher_host_browsertest.cc
diff --git a/content/browser/renderer_host/resource_dispatcher_host_browsertest.cc b/content/browser/renderer_host/resource_dispatcher_host_browsertest.cc
index 4bda0a530c767a936dfc4a28395aee1e2db99077..10490fa9bdb5c8b78360c00a3d247a928fcfacae 100644
--- a/content/browser/renderer_host/resource_dispatcher_host_browsertest.cc
+++ b/content/browser/renderer_host/resource_dispatcher_host_browsertest.cc
@@ -76,7 +76,7 @@ class ResourceDispatcherHostBrowserTest : public InProcessBrowserTest,
}
content::RenderViewHost* render_view_host() {
- return browser()->GetSelectedWebContents()->GetRenderViewHost();
+ return browser()->GetActiveWebContents()->GetRenderViewHost();
}
GURL GetMockURL(const std::string& file) {
@@ -88,7 +88,7 @@ class ResourceDispatcherHostBrowserTest : public InProcessBrowserTest,
int expected_navigations) {
string16 expected_title16(ASCIIToUTF16(expected_title));
ui_test_utils::TitleWatcher title_watcher(
- browser()->GetSelectedWebContents(), expected_title16);
+ browser()->GetActiveWebContents(), expected_title16);
ui_test_utils::NavigateToURLBlockUntilNavigationsComplete(
browser(), url, expected_navigations);
EXPECT_EQ(expected_title16, title_watcher.WaitAndGetTitle());
@@ -217,7 +217,7 @@ IN_PROC_BROWSER_TEST_F(ResourceDispatcherHostBrowserTest, SyncXMLHttpRequest) {
// Let's check the XMLHttpRequest ran successfully.
bool success = false;
EXPECT_TRUE(ui_test_utils::ExecuteJavaScriptAndExtractBool(
- browser()->GetSelectedWebContents()->GetRenderViewHost(),
+ browser()->GetActiveWebContents()->GetRenderViewHost(),
L"",
L"window.domAutomationController.send(DidSyncRequestSucceed());",
&success));
@@ -235,7 +235,7 @@ IN_PROC_BROWSER_TEST_F(ResourceDispatcherHostBrowserTest,
// Let's check the XMLHttpRequest ran successfully.
bool success = false;
EXPECT_TRUE(ui_test_utils::ExecuteJavaScriptAndExtractBool(
- browser()->GetSelectedWebContents()->GetRenderViewHost(),
+ browser()->GetActiveWebContents()->GetRenderViewHost(),
L"",
L"window.domAutomationController.send(DidSucceed());",
&success));
@@ -386,7 +386,7 @@ IN_PROC_BROWSER_TEST_F(ResourceDispatcherHostBrowserTest,
browser(), failed_url, 2);
EXPECT_NE(ASCIIToUTF16("set cookie on unload"),
- browser()->GetSelectedWebContents()->GetTitle());
+ browser()->GetActiveWebContents()->GetTitle());
// Check that the cookie was set, meaning that the onunload handler ran.
EXPECT_EQ("onunloadCookie=foo", GetCookies(url));
@@ -402,7 +402,7 @@ IN_PROC_BROWSER_TEST_F(ResourceDispatcherHostBrowserTest,
// off the navigation, and wait to see that the tab loads.
string16 expected_title16(ASCIIToUTF16("Title Of Awesomeness"));
ui_test_utils::TitleWatcher title_watcher(
- browser()->GetSelectedWebContents(), expected_title16);
+ browser()->GetActiveWebContents(), expected_title16);
bool success;
GURL test_url(test_server()->GetURL("files/title2.html"));
@@ -410,7 +410,7 @@ IN_PROC_BROWSER_TEST_F(ResourceDispatcherHostBrowserTest,
test_url.possibly_invalid_spec() + "';" +
"window.domAutomationController.send(true);";
EXPECT_TRUE(ui_test_utils::ExecuteJavaScriptAndExtractBool(
- browser()->GetSelectedWebContents()->GetRenderViewHost(),
+ browser()->GetActiveWebContents()->GetRenderViewHost(),
L"", ASCIIToWide(redirect_script), &success));
EXPECT_EQ(expected_title16, title_watcher.WaitAndGetTitle());
}
« no previous file with comments | « content/browser/renderer_host/render_view_host_manager_browsertest.cc ('k') | content/browser/session_history_browsertest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698