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

Unified Diff: content/browser/web_contents/web_contents_impl_browsertest.cc

Issue 196283013: Make to call WebContentsImpl::RenderViewCreated() when we create child window. (Closed) Base URL: https://src.chromium.org/chrome/trunk/src/
Patch Set: remove "ax_event_notification_details.h" in web_contents_impl.h Created 6 years, 7 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
« no previous file with comments | « content/browser/web_contents/web_contents_impl.cc ('k') | content/public/test/content_browser_test_utils.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: content/browser/web_contents/web_contents_impl_browsertest.cc
===================================================================
--- content/browser/web_contents/web_contents_impl_browsertest.cc (revision 270988)
+++ content/browser/web_contents/web_contents_impl_browsertest.cc (working copy)
@@ -437,5 +437,24 @@
EXPECT_EQ(3, delegate->loadingStateToDifferentDocumentCount());
}
+IN_PROC_BROWSER_TEST_F(WebContentsImplBrowserTest,
+ RenderViewCreatedForChildWindow) {
+ ASSERT_TRUE(embedded_test_server()->InitializeAndWaitUntilReady());
+
+ NavigateToURL(shell(),
+ embedded_test_server()->GetURL("/title1.html"));
+
+ WebContentsAddedObserver new_web_contents_observer;
+ ASSERT_TRUE(ExecuteScript(shell()->web_contents(),
+ "var a = document.createElement('a');"
+ "a.href='./title2.html';"
+ "a.target = '_blank';"
+ "document.body.appendChild(a);"
+ "a.click();"));
+ WebContents* new_web_contents = new_web_contents_observer.GetWebContents();
+ WaitForLoadStop(new_web_contents);
+ EXPECT_TRUE(new_web_contents_observer.RenderViewCreatedCalled());
+}
+
} // namespace content
« no previous file with comments | « content/browser/web_contents/web_contents_impl.cc ('k') | content/public/test/content_browser_test_utils.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698