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

Unified Diff: Source/web/tests/ListenerLeakTest.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/LinkHighlightTest.cpp ('k') | Source/web/tests/PageSerializerTest.cpp » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: Source/web/tests/ListenerLeakTest.cpp
diff --git a/Source/web/tests/ListenerLeakTest.cpp b/Source/web/tests/ListenerLeakTest.cpp
index 3bd098dbf662d65fc744822fbf1db2b3d469f0b4..655f3813ef8937d3e5277d7e326309b261974394 100644
--- a/Source/web/tests/ListenerLeakTest.cpp
+++ b/Source/web/tests/ListenerLeakTest.cpp
@@ -87,26 +87,22 @@ int GetNumObjects(const char* constructor)
class ListenerLeakTest : public testing::Test {
public:
- ListenerLeakTest() : m_webView(0) { }
-
void RunTest(const std::string& filename)
{
std::string baseURL("http://www.example.com/");
std::string fileName(filename);
bool executeScript = true;
URLTestHelpers::registerMockedURLFromBaseURL(WebString::fromUTF8(baseURL.c_str()), WebString::fromUTF8(fileName.c_str()));
- m_webView = FrameTestHelpers::createWebViewAndLoad(baseURL + fileName, executeScript);
+ webViewHelper.initializeAndLoad(baseURL + fileName, executeScript);
}
virtual void TearDown() OVERRIDE
{
- if (m_webView)
- m_webView->close();
Platform::current()->unitTestSupport()->unregisterAllMockedURLs();
}
protected:
- WebView* m_webView;
+ FrameTestHelpers::WebViewHelper webViewHelper;
};
« no previous file with comments | « Source/web/tests/LinkHighlightTest.cpp ('k') | Source/web/tests/PageSerializerTest.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698