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

Unified Diff: Source/web/tests/CustomEventTest.cpp

Issue 23506013: Make the embedder responsible for creating the WebFrame (Closed) Base URL: https://chromium.googlesource.com/chromium/blink.git@master
Patch Set: Fix lifetime on frame detach Created 7 years, 3 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 | « Source/web/tests/ChromeClientImplTest.cpp ('k') | Source/web/tests/FrameLoaderClientImplTest.cpp » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: Source/web/tests/CustomEventTest.cpp
diff --git a/Source/web/tests/CustomEventTest.cpp b/Source/web/tests/CustomEventTest.cpp
index 99310058de74b5ca8ab753ecab40621e0a6a9573..f6da968fc1bb591f4d0f6934243a45a96a57c0e6 100644
--- a/Source/web/tests/CustomEventTest.cpp
+++ b/Source/web/tests/CustomEventTest.cpp
@@ -100,8 +100,8 @@ TEST(CustomEventTest, InitWithSerializedScriptValue)
const std::string path = "visible_iframe.html";
URLTestHelpers::registerMockedURLFromBaseURL(WebString::fromUTF8(baseURL.c_str()), WebString::fromUTF8(path.c_str()));
- WebView* webView = FrameTestHelpers::createWebViewAndLoad(baseURL + path);
- WebFrameImpl* frame = toWebFrameImpl(webView->mainFrame());
+ FrameTestHelpers::WebViewHelper webViewHelper;
+ WebFrameImpl* frame = toWebFrameImpl(webViewHelper.initializeAndLoad(baseURL + path)->mainFrame());
WebDOMEvent event = frame->frame()->document()->createEvent("CustomEvent", IGNORE_EXCEPTION);
WebDOMCustomEvent customEvent = event.to<WebDOMCustomEvent>();
@@ -113,7 +113,6 @@ TEST(CustomEventTest, InitWithSerializedScriptValue)
frame->frame()->document()->dispatchEvent(event);
Platform::current()->unitTestSupport()->unregisterAllMockedURLs();
- webView->close();
}
}
« no previous file with comments | « Source/web/tests/ChromeClientImplTest.cpp ('k') | Source/web/tests/FrameLoaderClientImplTest.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698